Skip to content
Discussion options

You must be logged in to vote

There are two separate paths here: the terminal/CLI is still ASCII input, even when you type hex values; the firmware parses those tokens and performs the I2C transaction. For a more byte-oriented I2C transaction from the CLI, use the bracket sequence syntax:

mode i2c
config
[0x3C 0x00 r:4] # write register 0x00, then read 4 bytes
[0x3C 0x01 0xFF] # write bytes to address 0x3C

For an actual adapter-style workflow, switch the device into the BPIO2 GPIO/SPI/I2C USB adapter, then reconnect with the BPIO2 web tool instead of the terminal:

mode usb
adapter
# choose: BPIO2 GPIO/SPI/I2C

In BPIO2 I2C, use 7-bit address + “Write bytes” + “Read length”; for register reads, put the register addres…

Replies: 3 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@lightwoheat
Comment options

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by lightwoheat
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
4 participants