-Communication example
-----------------------
-
-This is a short and incomplete introduction on how to talk to an ELM327.
-
-
-The ELM327 has two modes:
-
-- Command mode
-- Reception mode
-
-In command mode, it expects one command per line, terminated by CR.
-By default, the prompt is a "``>``", after which a command can be
-entered::
-
- >ATE1
- OK
- >
-
-The init script in the driver switches off several configuration options
-that are only meaningful in the original OBD scenario the chip is meant
-for, and are actually a hindrance for elmcan.
-
-
-When a command is not recognized, such as by an older version of the
-ELM327, a question mark is printed as a response instead of OK::
-
- >ATUNKNOWN
- ?
- >
-
-At present, elmcan does not evaluate this response and silently assumes
-that all commands are recognized. It is structured such that it will
-degrade gracefully when a command is unknown. See the sections above on
-known limitations for details.
-
-
-When a CAN frame is to be sent, the target address is configured, after
-which the frame is sent as a command that consists of the data's hex
-dump::
-
- >ATSH123
- OK
- >DEADBEEF12345678
- OK
- >
-
-The above interaction sends the frame "``DE AD BE EF 12 34 56 78``" with
-the 11 bit CAN ID ``0x123``.
-For this to function, the controller must be configured for 11 bit CAN
-ID sending mode (using "``AT PB``", see code or datasheet).
-
-
-Once a frame has been sent and wait-for-reply mode is on (``ATR1``,
-configured on ``listen-only=off``), or when the reply timeout expires and
-the driver sets the controller into monitoring mode (``ATMA``), the ELM327
-will send one line for each received CAN frame, consisting of CAN ID,
-DLC, and data::
-
- 123 8 DEADBEEF12345678
-
-For 29 bit CAN frames, the address format is slightly different, which
-elmcan uses to tell the two apart::
-
- 12 34 56 78 8 DEADBEEF12345678
-
-The ELM327 will receive both 11 and 29 bit frames - the current CAN
-config (``ATPB``) does not matter.
-
-
-If the ELM327's internal UART sending buffer runs full, it will abort
-the monitoring mode, print "BUFFER FULL" and drop back into command
-mode. Note that in this case, unlike with other error messages, the
-error message may appear on the same line as the last (usually
-incomplete) data frame::
-
- 12 34 56 78 8 DEADBEEF123 BUFFER FULL
-
-
-