ChipFind - документация

Электронный компонент: ELM630P

Скачать:  PDF   ZIP
ELM630
Elm Electronics Circuits for the Hobbyist
< http://www.elmelectronics.com/ >
LIN Monitor
LIN or `Local Interconnect Network' is a low cost
and relatively simple networking system that is used
predominantly in the automotive world. Recently, it
has been gaining in popularity, with proposals to use
it in major appliances as well. For more information,
visit the LIN web site (http://www.lin-subbus.de/).
The ELM630 is a monitoring device designed
for troubleshooting LIN bus systems. It is capable of
continually monitoring a LIN network, translating the
LIN messages to standard ASCII characters, and re-
transmitting them to an RS232 system (personal
computer or PDA) for display and possibly analysis.
The baud rate measurements, data formatting,
synchronizing, and checksum calculations are all
done for you by the ELM630.
The LIN specification has recently been updated
to revision 2.0, incorporating several improvements.
The ELM630 has been updated to be compatible
with this new specification, as well as the previous
ones.
Low power CMOS design
Crystal-controlled for accuracy
Standard ASCII character output
Special power-on monitor mode
Autobaud from 1200bps to 19200bps
High speed (57600 baud) RS232 interface
Works with LIN1.x and LIN2.0
LIN logic probes
Diagnostic PC interfaces
Instruction triggered (breakpoint) devices
Educational or training devices
Description
Applications
Block Diagram
1 of 12
Features
ELM630DSB
Connection Diagram
PDIP and SOIC
(top view)
V
DD
V
SS
LIN
LFmode
XT1
XT2
Monitor
b0
Rxmode
b1
1
2
3
14
13
12
11
4
5
6
10
9
8
7
RS232Tx
MTime
b2
RS232Rx
Baud
Rate*
*
see Table 1 on Page 3
2
3
XT1
XT2
5
Timing
Formatting
and
Control
LIN
Interface
LIN
11
13
Monitor
4
MTime
12
RS232Tx
RS232Rx
Rxmode
7
3.58MHz
RS232
Interface
LFmode
10
9
8
b2 b1 b0
6
ELM630
Elm Electronics Circuits for the Hobbyist
< http://www.elmelectronics.com/ >
Pin Descriptions
2 of 12
All rights reserved. Copyright 2003, 2004 Elm Electronics.
Every effort is made to verify the accuracy of information provided in this document, but no representation or warranty can be
given and no liability assumed by Elm Electronics with respect to the accuracy and/or use of any products or information
described in this document. Elm Electronics will not be responsible for any patent infringements arising from the use of these
products or information, and does not authorize or warrant the use of any Elm Electronics product in life support devices and/or
systems. Elm Electronics reserves the right to make changes to the device(s) described in this document in order to improve
reliability, function, or design.
V
DD
(pin 1)
This pin is the positive supply pin, and should
always be the most positive point in the circuit.
Internal circuitry connected to this pin is used to
provide power-on reset of the microprocessor, so an
external reset signal is not required. Refer to the
Electrical Characteristics section for further
information.
XT1 (pin 2) and XT2 (pin 3)
A 3.579545MHz NTSC television colourburst crystal
is connected between these two pins. Crystal
loading capacitors (typically 27pF) will also be
connected from each of these pins to the circuit
common (Vss).
Rxmode (pin 4)
This input is used to control the inverting of the
signal at the RS232Rx input (pin 5), allowing some
flexibility as to how the RS232 is connected to it.
Many experimenters will prefer to use only a single
resistor between the RS232 interface and pin 5 to
minimize costs. In that case, pin 4 need only be tied
to common (V
SS
), and the internal logic will invert
the polarity of the signal for you.
Other users may prefer to use one of the standard
(inverting) interface circuits such as the MAX232
series, or the SN75189/MC1489 type of IC. In these
cases, the internal inversion is not required, and
should be disabled by connecting the Rxmode input
to a high level (V
DD
). The interface IC can then be
directly connected to the RS232Rx input (pin 5).
RS232Rx (pin 5)
A computer's RS232 transmit signal is connected to
this pin, either through a resistor or through an
interface IC, as discussed under Rxmode (pin 4). If
a resistor is used, care should be taken in selecting
its size in order to limit currents into the protecting
diodes, while minimizing degradation of the input
signal (due to the interaction between the resistor
and stray circuit capacitance). A value of 47K
is
typically chosen for this resistor.
LFmode (pin 6)
This input is used to select the default linefeed mode
after a power-up or system reset. If it is at a low
level, then the RS232 output from the ELM630 will
be terminated by a carriage return character only,
and no linefeed character. If it is at a high level, then
all messages sent by the ELM630 will end with both
a carriage return and a linefeed character. This
behaviour can also be modified by issuing an AT L0
or AT L1 command (see the AT Commands section
for more information).
RS232Tx (pin 7)
This is the RS232 transmit, or data output, pin.
While at rest (no data is being sent), this pin will
output a high level (V
DD
), which is compatible with
most interface ICs. It has sufficient current drive to
allow interfacing using only a transistor if desired.
See the Example Applications section for more
details.
Baud Rate (pins 8, 9, and 10)
These pins are used to set the baud rate that is to
be used when monitoring the LIN system. This is
only the initial rate used after a power-up or reset,
and does not affect rates that are subsequently set
using the AT SB command. The following chart
shows the possible input values and the resulting
baud rate:
ELM630DSB
Elm Electronics Circuits for the Hobbyist
< http://www.elmelectronics.com/ >
ELM630
3 of 12
ELM630DSB
Ordering Information
These integrated circuits are available in either the 300 mil plastic DIP format, or in the 150 mil SOIC surface mount
type of package. To order, add the appropriate suffix to the part number:
300 mil Plastic DIP...................................ELM630P
150 mil SOIC........................................ ELM630SM
Pin Descriptions (continued)
Note that the SB column in this table refers to the
value that would be used with an AT SB command
to set the baud rate.
Monitor (pin 11)
This input is used to effectively force an AT MA
command upon power-up, without any RS232 input
being required. If this pin is found to be at a high
level during a power-up (or reset), the ELM630 will
display the ID string, but instead of issuing a prompt
character it will immediately execute an AT MA
command, reporting on all LIN bus activity.
MTime (pin 12)
This input sets the default measurement time period
for monitoring the input in order to determine the LIN
baud rate. If low, a time of 0.5 seconds will be used,
and if high, 10 seconds is used. This is only the
power-up time period it can be changed at any
time using the AT SM command, which is discussed
later. Note that this time period is only used when in
the automatic baud rate mode. If a specific baud
rate has been selected, or if a previous rate
measurement successfully determined a baud rate,
there is no need to make more baud measurements,
and this setting will not be relevant.
LIN (pin 13)
This is the active high LIN signal input. The signal
from the LIN bus is inverted and buffered, then
presented to this pin. Note that this input is limited to
voltages from V
SS
to V
DD
, so it can not be directly
connected to the LIN bus. (See the Example
Applications section for a typical interface circuit.)
V
SS
(pin 14)
Circuit common is connected to this pin. This is the
most negative point in the circuit.
b2
b1
b0
SB
Baud Rate
L
L
L
0
auto
L
L
H
1
1200
L
H
L
2
2400
L
H
H
3
4800
H
L
L
4
9600
H
L
H
5
19200
H
H
L
6
auto
H
H
H
7
auto
Table 1. Baud Rate Settings
Electrical Characteristics
Absolute Maximum Ratings
Storage Temperature....................... -65C to +150C
Ambient Temperature with
Power Applied....................................-40C to +85C
Voltage on V
DD
with respect to V
SS
............ 0 to +7.0V
Voltage on any other pin with
respect to V
SS
........................... -0.6V to (V
DD
+ 0.6V)
Note:
Stresses beyond those listed here will likely damage
the device. These values are given as a design
guideline only. The ability to operate to these levels
is neither inferred nor recommended.
Notes:
1. This integrated circuit is produced with a Microchip Technology Inc.'s PIC16C505 as the core embedded
microcontroller. For further device specifications, and possibly clarification of those given, please refer to the
appropriate Microchip documentation (available at http://www.microchip.com/).
2. This spec must be met in order to ensure that a correct power on reset occurs. It is quite easily achieved
using most common types of supplies, but may be violated if one uses a slowly varying supply voltage, as
may be obtained through direct connection to solar cells, or some charge pump circuits.
3. This specification represents the current flowing through the internal protection diodes when the voltage
connected to the RS232Rx input (through a current limiting resistance) is greater than V
DD
or less than V
SS
.
Currents quoted are the maximum that should be allowed to flow continuously.
4. Nominal data transfer rate when the recommended 3.58 MHz crystal is used as the frequency reference.
Data is transferred to and from the ELM630 with 8 data bits, no parity, and 1 stop bit (8 N 1).
4 of 12
ELM630
ELM630DSB
Elm Electronics Circuits for the Hobbyist
< http://www.elmelectronics.com/ >
All values are for operation at 25C and a 5V supply, unless otherwise noted. For further information, refer to note 1 below.
Characteristic
Minimum
Typical
Maximum
Conditions
Units
Supply voltage, V
DD
4.5
5.0
5.5
V
V
DD
rate of rise
0.05
V/ms
Average supply current, I
DD
0.8
1.4
mA
Input low voltage
V
SS
0.15 x V
DD
V
Input high voltage
V
DD
V
0.85 x V
DD
Output low voltage
0.6
V
Output high voltage
V
V
DD
- 0.7
Current (sink) = 8.7mA
Current (source) = 5.4mA
see note 2
RS232Rx pin input current
mA
see note 3
-0.5
RS232 baud rate
baud
see note 4
57600
+0.5
5 of 12
ELM630
ELM630DSB
Elm Electronics Circuits for the Hobbyist
< http://www.elmelectronics.com/ >
AT Commands
The ELM630 is controlled with short commands
that all begin with the two characters `AT' (which is
short for ATtention). These two characters serve no
purpose other than to add validity to the characters
that follow. Modem manufacturers have used this
same technique for years, and it has become
customary to refer to commands that begin with these
characters as `AT Commands'.
The ELM630 accepts several different AT
commands, but only one at a time (it cannot process
multiple commands on one line, as modems can).
Each command is executed only upon the receipt of a
terminating carriage return character. Several
commands do not have a visible response (AT D for
example), so completion of such commands will be
Communicating with the ELM630
The ELM630 relies on a standard RS232 serial
connection to communicate with the user. The data
rate is not adjustable, and is set at 57600 baud, with 8
data bits, no parity bit, 1 stop bit, and no handshaking
(often referred to as 57600 8N1). All responses from
the IC are terminated with a single carriage return
character and, optionally, a linefeed character. Make
sure your software is configured properly for this
connection and for the linefeed mode that you have
chosen. No special software is required to `talk' to the
IC a standard terminal program is all that is needed.
Once it has been properly connected and
powered, the ELM630 will send the message:
ELM630 v2.0
>
In addition to identifying the version of this IC,
receiving this string is a good way to confirm that the
computer connections and terminal software settings
are correct. The `>' character displayed above is the
ELM630's prompt character, which shows that the
device is in its idle state, ready to receive characters
on the RS232 port.
All messages that are sent to the ELM630 must
begin with the character `A' followed by the character
`T', and must be terminated with a carriage return
character. No action is taken commands are not
checked for errors, nor are they acted upon until this
terminating carriage return is received. The one
exception is when a command is interrupted for some
reason, and no carriage return appears. In this case,
an internal timer will automatically abort the incomplete
message after about 15 seconds, and the ELM630 will
print a single question mark to show that the input was
not understood (and was not acted upon).
Messages that are not understood by the ELM630
(syntax errors) will always be signalled by this same
single question mark (`?'). When this occurs, it is
usually due to a spelling mistake, so you often only
need to repeat the input, typing more carefully.
Occasionally, errors occur if the ELM630 is busy
processing LIN messages when an RS232 command
message begins. In these cases, the first character of
the RS232 command message will always be missed
by the IC, so the remaining characters will appear to
be incorrect. One should always interrupt the
monitoring process with a single character (it doesn't
matter which one, as it will be ignored), then wait for
the prompt character (`>') to appear before sending
any more. This ensures that the ELM630 is ready to
receive commands.
For convenience, the ELM630 has been designed
to ignore spaces and control characters in the input, so
if you prefer to add spaces or tabs, etc. to improve
readability, then go ahead. Also, the ELM630 is not
case-sensitive, so `ATZ' is equivalent to `atz', and to
`AtZ', which may be helpful in some situations.
acknowledged by the printing of the characters `OK'.
Monitoring of the LIN bus can generally begin
without requiring the use of any AT commands, as the
factory default settings are appropriate for most
situations. Occasionally, however, the user may wish
to customize settings, such as turning the character
echo off, and in these cases AT commands must be
used.
To perform the desired AT command, simply send
the characters AT followed by the appropriate
characters from the following list. For example, to turn
character echoing off, simply send AT E0 followed by
a return character. To turn it back on, send AT E1.
The following is a summary of the commands that
are recognized by the current version of the ELM630.