3.2.15.I2C READ
Is used to command the module to read 1 byte via I
2
C line.
Byte Count
Command
Parameter
Host Command
2
0x24
0x00 (nack)
0x01 (ack)
Module Response
2
0x24
1 byte data
1
0xEE
-
Parameter of host is given value of 0 to respond the I
2
C reception with not
acknowledge and value of 1 to respond I
2
C reception with acknowledge.
If packet is recognized and correct, module will respond with data reading
result.
If the packet is false/not recognized, module will respond with NACK (0xEE).
Example:
PC
: 0x58 0x02 0x24 0x00 0x82
USB Smart I/O
: 0x58 0x02 0x24 0x90 0xF2
means that the computer requests 1 data that is found on I
2
C line and will be
responded with not acknowledge. Module replies that the data reading result
via I
2
C has a value of 144 (0x90).
3.2.16.I2C STOP
Is used to command the module to send stop condition to I
2
C line.
Byte Count
Command
Parameter
Host Command
1
0x25
-
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 0x25 0x82
USB Smart I/O
: 0x58 0x01 0xAA 0xFD
3.2.17.I2C SEND PACKET
Is used to command the module to sends 1 data packet via I
2
C line.
Byte Count
Command
Parameter
Host Command
2 – 36
0x26
1 – 35 byte
Module Response
1
0xAA
-
0xEE
Parameter with maximum amount of 35 bytes includes I
2
C device address.
Transmission will be performed consecutively.
Module will send start condition, parameters on command, and stop condition.
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 0x05 0x26 0xD0 0x01 0x02 0x03 0xA7
USB Smart I/O
: 0x58 0x01 0xAA 0xFD
14