Firmware-811 Command-012

From I-CubeX Wiki
Jump to: navigation, search

DUMP RES (12, 0Ch)

The DUMP RES command can be used to retrieve the sampling resolution of a port when it is configured as an analog input. The command can be used in both host and stand-alone modes of operation. Upon completion of the DUMP RES command the WiDig sends out the same message as the RES command. The DUMP RES command's response does not apply to ports that are configured for digital I2C sensors and should be ignored.

The [BODY] of the RES command consists of a single 7-bit byte with the following format :

0000xyyy: x = 1; apply the command to all ports (yyy is ignored), ie. send 8 messages with the status for each port
yyy = [0..7]; port number, where the first port number = 0, and the last (8th) input number = 7

Example:

In order to retrieve the resolution of port 2, configured as analog input, the following message is sent:

240, 125, 0 {DEV}, 12 {DUMP RES}, 2, 247 (F0h, 7Dh, 00h, 0Ch, 02h, F7h)