# Using a RasPi (or similar) with CircuitPython on Bristlemouth

**URL:** https://bristlemouth.discourse.group/t/using-a-raspi-or-similar-with-circuitpython-on-bristlemouth/379
**Category:** Application Dev
**Created:** [July 16, 2024, 5:13pm UTC](https://bristlemouth.discourse.group/t/using-a-raspi-or-similar-with-circuitpython-on-bristlemouth/379 "2024-07-16T17:13:35Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![zack\_j](https://yyz1.discourse-cdn.com/flex029/user_avatar/bristlemouth.discourse.group/zack_j/32/13_2.png) [@zack\_j](https://bristlemouth.discourse.group/u/zack_j)
#### Post date: [July 16, 2024, 5:13pm UTC](https://bristlemouth.discourse.group/t/using-a-raspi-or-similar-with-circuitpython-on-bristlemouth/379/1 "2024-07-16T17:13:35Z")

</div>

@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:

> **[Adafruit Feather RP2040](https://www.adafruit.com/product/4884)**
>
> A new chip means a new Feather, and the Raspberry Pi RP2040 is no exception. When we saw this chip we thought "this chip is going to be awesome when we give it the Feather ...

Read [getting started guide](https://bristlemouth.notion.site/Bristlemouth-Serial-Client-for-CircuitPython-569f25f984874a1485595b7a177669a7) and let us know if you have as much fun as we did with this integration!

---

<div class="post-metadata">

### Author: ![NickRaymomd](https://yyz1.discourse-cdn.com/flex029/user_avatar/bristlemouth.discourse.group/nickraymomd/32/140_2.png) [@NickRaymomd](https://bristlemouth.discourse.group/u/NickRaymomd)
#### Post date: [July 23, 2024, 7:55pm UTC](https://bristlemouth.discourse.group/t/using-a-raspi-or-similar-with-circuitpython-on-bristlemouth/379/2 "2024-07-23T19:55:07Z")

</div>

@zack_j + @zachary this is so cool! And looks like this might be compatible with [Adafruits Blinka](https://learn.adafruit.com/circuitpython-on-raspberrypi-linux/installing-circuitpython-on-raspberry-pi) 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”?

---

<div class="post-metadata">

### Author: ![zachary](https://yyz1.discourse-cdn.com/flex029/user_avatar/bristlemouth.discourse.group/zachary/32/31_2.png) [@zachary](https://bristlemouth.discourse.group/u/zachary)
#### Post date: [July 24, 2024, 12:06am UTC](https://bristlemouth.discourse.group/t/using-a-raspi-or-similar-with-circuitpython-on-bristlemouth/379/3 "2024-07-24T00:06:28Z")

</div>

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!
