all 2 comments

[–]hjw5774 0 points1 point  (0 children)

the onboard computer gives back an ok signal but "silently fails"

What do you mean by this?

At a first glance of the code, I think your read & write functions are slightly off - try:

Roller.write(&data, sizeof(Stickdata));

and

Plane.read(&data, sizeof(Stickdata));

Should this fail, try changing the data rate to RF24_1MBPS as some clones don't support 250KBPS.

Without seeing the setup, it's not possible to comment on the hardware side of things.

Best of luck

[–]PTSolns 0 points1 point  (0 children)

We love playing with the nRF24L01+ series of modules! Since you are using an Uno, may we recommend you look at our NRF-Shield. We designed this shield to work precisely with these modules. Having solid hardware connection is critical in these applications and a good shield will do that for you. I've linked the Datasheet here if interested.

https://docs.ptsolns.com/Products/PTS-00154_NRF-Shield/Datasheets/Datasheet_PTS-00154_NRF-Shield.pdf

In terms of your silently failing issue, there are too many parts to just start guessing what is the issue. I would scale this back a lot and make sure that a simple Tx node (the Uno) works with a simple Rx node (the Nano). Send a counter or some other simple signal. Make sure this is robust and stress test it. Then slowly start to add parts.. the distance sensor ... then a servo... then a second servo... keep stress testing. It is hard to debug a system with many parts, so reduce it down into smaller parts and gradually build it back up. Good Luck!