For commands that do not ask for data, the module will respond with ACK
(0xAA) or NACK (0xEE).
Start Byte
0x01
0xAA / 0xEE
LRC
Available commands and parameters can be seen on section
3.2
.
Default settings on purchase:
–
ANALOG INPUT functions as analog input (no internal pull-up resistor).
–
DIGITAL I/O and GPIO functions as digital input (no internal pull-up
resistor, Counters are inactive).
–
Baud rate UART 9600 bps.
–
Bit rate I
2
C 50 kHz.
3.2.
COMMAND SET
3.2.1. PING
Is used to check whether the communication line to the module still exists.
Byte Count
Command
Parameter
Host Command
1
0xFF
-
Module Response
1
0xAA
-
0xEE
If packet is recognized and correct, module will respond with ACK (0xAA).
If the packet is false/not recognized, module will respond with NACK (0xEE).
Example:
PC
: 0x58 0x01 0xFF 0xA8
USB Smart I/O
: 0x58 0x01 0xAA 0xFD
3.2.2. RESET
Is used to perform soft-reset on the module.
Byte Count
Command
Parameter
Host Command
1
0x01
-
Module Response
1
0xAA
-
0xEE
If packet is recognized and correct, module will respond with ACK (0xAA).
Module will perform soft-reset with the following effects:
–
Module's USB function will be turned off so it will be disconnected from the
computer.
–
Module will repeat the process from the start, including USB connection
initialization and EEPROM reading to get each I/O function setting data.
–
DAC output is unchanged.
If the packet is false/not recognized, module will respond with NACK (0xEE).
Example:
PC
: 0x58 0x01 0x01 0xA6
USB Smart I/O
: 0x58 0x01 0xAA 0xFD
8