GET_GPIOS

Role

Read the current status of the device’s GPIO pins.

Remark

Not all devices have GPIO pins. In this case, the response is empty.

Pay attention that the GPIO pins are likely to be multiplexed with the 4-LED ramp (see SET_LEDS).

Access condition

Free.

Command

Field Value
CLA 58 (CONTROL)
INS 15

Response

Bytes Content
0-N Current status of all GPIO pins (one byte per GPIO pin, empty if none)

Values

Every byte takes one of the following values:

Value Explanation
00 Pin is configured as input and input level is LOW
01 Pin is configured as input and input level is HIGH
80 Pin is configured as output and output level is set to LOW
81 Pin is configured as output and output level is set to HIGH
8F Pin is configured as a LED output

Not any other value can be provided in the response.