UM-0086-A2
CANgate User’s Manual
Page 14
hex data
– enter a string of hexadecimal digits, eg.
12ff09270045db08
. To make long strings easier to read, one
or more underscores (or any other non-hex, non-whitespace character) can optionally be inserted between bytes, eg:
12ff0927_0045db08
. The hexadecimal prefix
0x
can also be included if desired.
string
– enter an ASCII string inside quotation marks, eg.
"big top"
,
"\007Alert "
,
"\r\n"
Control characters
may be inserted into strings using a backslash followed by three decimal digits representing the ASCII
code, eg.
\013
will insert a carriage return. To insert an actual backslash character, use
\\
. As a shortcut, carriage return,
newline (CR-LF) and tab characters may be inserted using
\r
,
\n
and
\t
respectively.
Note:
If
DeTransfer
is used to send commands to CANgate then each backslash must be entered as
\\
in the DeTransfer
Send window. So if you want the string to contain an actual backslash character you would need to enter
\\\\
in
DeTransfer.
Commands must be terminated by a carriage return or a semi-colon (
;
) character.
Comments
may be included using an apostrophe (
'
) character. All characters after the apostrophe up until the end of the
line will be ignored.
Run Mode and Program Mode
CANgate has two operational modes.
Run Mode
is the normal mode of operation. Following power-up, CANgate always starts in Run Mode.
In Run Mode, all configured memory slots will receive and/or transmit their programmed CAN or GPS messages, and return
data to the host system as required.
Whilst in Run Mode, any of the commands described in the Command Reference
(P16)
may be entered. However, only
Memory Slot #0's configuration may be changed. Commands that attempt to modify any of the other memory slots will be
ignored – the only way to update these slots is to switch to Program Mode.
Program Mode
is entered by sending the
BEGIN
command. This command will erase all existing memory slots and prepare
CANgate for receiving new definitions.
In Program Mode, the CAN and GPS ports are not active. The only commands that are accepted in this mode are the slot
definition commands –
RECV
,
RECVE
,
SEND
,
SENDE
,
RECVJ
,
RQST
,
RQSTJ
and
GPS
.
These commands are prefixed by the number of the memory slot to define, eg:
12 RECV 1 0x712 1 2
will define memory slot #12.
When all required memory slots have been defined, the
END
command will save all memory slot details (except Slot #0) to
non-volatile flash memory and return to Run Mode.