Pololu Robotics & Electronics
Menu
My account Comments or questions? About Pololu Contact Ordering information Distributors

Pololu Forum

Balboa NRF24l01 connection?

I would like to add an NRF24L01 transceiver to my Balboa robot. However, the transceiver communicates via SPI and it looks as though Balboa is using SPI for motor control. Am I correct that therefore I cannot connect the transceiver to the ISP pins without interfering with Balboa’s motor functions? (If so, is there an alternative way to connect it?)

If this is unworkable, there is a shield available that allows the transceiver to connect via I2C.

My interest is using the NRF24L01 is that I have a Freenove Remote that transmits using this unit and know how to set up the same device to receive those signals. This would make it possible to use the remote to control Balboa.

Bruce A.

Hello, Bruce.

We don’t expect it to be practical to use the Balboa’s hardware SPI interface while maintaining precise control of its motors (including while balancing). You might try using software SPI and using pins other than the two used for motor control (15 and 16). In case you have not already seen it: you can find a list of available Balboa I/O pins at the bottom of the table in the “Pin assignments” section of the Balboa’s user’s guide, which you can find under the Resources tab of its product page.

-Jon

Hi Jon,

Thanks for confirming my understanding that the hardware SPI is unavailable for use by other devices, and for your suggestion to try a software SPI solution. I was not aware of the latter possibility!

-Bruce A.

1 Like

I was able to use the Radiohead Software SPI together with the Radiohead nrf24l01 driver and Reliable Datagram Manager with the Nrf24l01 transceiver on the Balboa. I used pins 5 and 12 for CE and CS. Then I used pins A2, A3, A4 for MISO, MOSI, and SCK.

For the Joystick transmitter, I used the Joystick code and hardware from the Dronebot Workshop robot car project.

I don’t have it all working yet but it seems like I’m going in the right direction.

On another note, why does the Balboa use SPI pins for what seem like non hardware SPI functions which forces us to use software SPI?

Tony

Hi, Tony.

Since there aren’t that many pins on an ATmega32U4 and we used most of them on the Balboa 32U4, we tried to pick the most useful pins to leave free. We mostly prioritized leaving analog and PWM pins available since they can be useful for sensors. Of course, not all users of the Balboa will have the same priorities, so the pin assignments might not be as convenient in projects like yours.

I hope you’re able to get software SPI to function without too much trouble, and we’d be interested to see what you are doing with your Balboa once you get it all working.

Kevin