Example: Read The Current Gpio Configuration - We PROTEUS-III User Manual

Hide thumbs Also See for PROTEUS-III:
Table of Contents

Advertisement

WIRELESS CONNECTIVITY & SENSORS
User manual Proteus-III
0x02: GPIO has pull up resistor
• if Function is output, Length is 0x03:
0x00: GPIO is output LOW
0x01: GPIO is output HIGH
• if Function is PWM, Length is 0x05 (see chapter 11.1 ):
Byte 0 and 1: LSB first uint16 PWM period in ms (1 - 500 ms)
Byte 2: Ratio (0x00=0%,. . . , 0xFE=100%)
7.7.2.1. Example: Read the current GPIO configuration
Read the current configuration:
Response:
Start signal
Command | 0x40
0x02
The GPIOs with GPIO_ID 0x01 and 0x02 are output high. The remaining GPIOs with GPIO_ID
0x03,0x04,0x05 and 0x06 are not configured.
Order code 2611011024000
Version 1.8 , July 2022
Start signal
Command
0x02
0x2B
Length
0x6B
0x15 0x00
Length
CS
0x00 0x00
0x29
Status
Blocks
0x03 0x01 0x02 0x01
0x03 0x02 0x02 0x01
0x02 0x03 0x00
0x00
0x02 0x04 0x00
0x02 0x05 0x00
0x02 0x06 0x00
www.we-online.com/wcs
CS
0x7B
99

Advertisement

Table of Contents
loading

This manual is also suitable for:

Proteus-iii-spi26110110240102611011024000

Table of Contents