Skip to content

Add example for slave mode operation with the Pi Pico #145

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

Skipper7718
Copy link
Contributor

@Skipper7718 Skipper7718 commented Jul 20, 2021

The code was tested with the Jetson Nano B01 as master.

Code for testing:

#curcuitpython on the jetson nano
#default i2c bus
import board
from time import sleep

i2c = board.I2C()

#toggle led on the pico
i2c.writeto(0x31, bytes([0x10]))

sleep(1)

#request to read echo
i2c.writeto(0x31, bytes([0x20]))
sleep(0.5)
buffer = bytearray(2)
i2c.readfrom_into(0x31, buffer)
print(buffer)

@Skipper7718 Skipper7718 changed the title Added example for slave mode operation with the Pi Pico Add example for slave mode operation with the Pi Pico Jul 20, 2021
@Skipper7718 Skipper7718 marked this pull request as ready for review July 20, 2021 22:33
@davidedelvento
Copy link

@voidlight7718 not sure if you saw my mention of your code in #192 -- if you are still interested in this after so much time, you might want to chime in there.

@kilograham kilograham added this to the 2.2.0 milestone Feb 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants