Using a RasPi (or similar) with CircuitPython on Bristlemouth

@zachary and I have been working on a short-term guide to get started right away with the RasPi + Circuit Python.

We’ve been using the Adafruit Feather RP2040:

Read getting started guide and let us know if you have as much fun as we did with this integration!

1 Like

@zack_j + @zachary this is so cool! And looks like this might be compatible with Adafruits Blinka library so this could run on the larger Raspberry Pi boards in addition to the RP2040.

Does this circuit python implementation include something like a “spotter_rx” method so that the Pi can receive messages from the Spotter. That way the Pi could take actions based on commands form the Spotter hardware, like “turn on an LED” or “activate motor”?

1 Like

Great question! Not yet!

When we or anyone else gets to it, it should look something like this.

  • In bm_serial.py, we need to add a subscribe function that builds a subscription packet and sends it over uart.
  • The serial_bridge dev kit app would need to handle that subscription packet and make the analogous bm_sub call there.
  • When the dev kit app receives a published message to which it has subscribed, it needs to pass that over bm_serial to the RPi.

Usage on the RPi would then look like this:

  • Call bm.subscribe which takes as arguments a topic string and a callback function
  • Write the callback function to handle the messages that arrive.

Not on my short list, but PRs are welcome!

1 Like