Simple 3D-printed NRF remote - Arduino controlled

I tried to integrate the remote control module to a PCB, but the first boot OLED will be chaotic, it needs to disconnect many times to normal display. Can you help me?

2 Likes

@solodros Try to desolde the cap

@Howardzinn You need to have the RX and TX connected, otherwise, you will not be getting any data. However the remote should connect to the receiver right away if you have soldered everything correctly, and uploaded the newest firmware.

@Deakbannok No my work is a little more organized :stuck_out_tongue:

@solodros Did you remember to add pull-up resistors on the I2C line?

2 Likes

@solidgeek itā€™s good point! I will try to measure the signals when connected RX TX. Thanks alot

BTW the remote is many times desolder :smile: it will looks better i promise!

This is the driving circuit of OLED. I doubt it is power supply. I plan to replace IC with IC of 5V1A and 3V3-800MA.

My friend also made it, but he did not have these problems. I tried your advice.

1 Like

Hey guys, I finally got around to building a remote but Iā€™m having trouble with it freezing at start up. I have played around with commenting out lines to narrow down the source. Currently I am able to get it to boot by changing line 471 in the transmitToReceiver function from: if ( radio.write( &remPackage, sizeof(remPackage) ) ) to: if ( true ) I canā€™t figure out how to solve this so any help would be great!

1 Like

You dont want to chnange that line 471. that is what TX writing to RX. freezing up like no starting screen?

Right, I was just trying to isolate what was causing the crash and it looks like any write command will do it. I can get the starting screen to load but it will lock up before the program draws the running screen on both yours and SolidGeekā€™s software. I can also get into settings just fine but changing certain values will cause it to crash as well.

I also have tried different versions of the RF24 library without success.

@solidgeek Hey man, are you using the newest VESC firmware from VESC tool? Which is, I suppose 3.xx ? I think I read that you are using a vesc 6, do you know if I can use RollingGeckoā€™s library with the newest 3.xx firmware and a 4.12 vesc ?

I am planning to use Geckoā€™s ArduBoardController in a simplified version, mainly just because your code looks really hard to understand for a non prgrammer like me. I will use no screen and only a single potentiometer, so I think GEckoā€™s code wil be easier to adapt, or do you htink otherwise?

On the other hand I think @lox897 had a simmilar idea to use ArduBoardController codes but he ran into issues. https://www.electric-skateboard.builders/t/ultimate-vesc-controller-with-oled/21922/152

Ok, so basically do you think a monkey like me could edit your code to run with a pot without much hassle :slight_smile: ?

Edit: I also was considering to use @wafflejock 's code, but it seems to not use UART, but PWM instead? So, I am unsure if it can be used with a vesc at allā€¦

Cheers

Just to clarify mine does work with a vesc but the code runs on an Arduino pro mini that relays the radio signals on both sides and reads the potentiometer on the control side and writes out to a pin (pretty sure I used d5) to send signal to the vesc just like any other receiver (on the receiver side). I used the 8MHz 3.3V to avoid low voltage issues with either the controller lipo or VESC BEC, the 8Mhz variant will work down to about 3.5V

1 Like

@wafflejock was about to ask if anyone had tried using the smaller ā€œarduino pro miniā€ which is smaller in size compared to ā€œnanoā€, even a step further I have 5 ā€œarduino pro mini 3vā€ which has a solid 3v for nrf24 moduleā€¦ since everyone only buys in bulk around here was gonna do a run of 5 remotes. My Nano build worked just fine, just wanted to experiment a bit, Iā€™ve also sat on this pro mini 3v build for monthsā€¦ Cases are made of; -PETG -ABS -PLA -Hemp PLA

4 Likes

use a basic master branch. see if your problem still existing.

I dont see a problem adjusting your code to go with an Arduino nano for my purposes. So one question remains, in the vesc/bldc tool you set up the control through the PPM ? because I am either blind or vesc tool does not have a PWM control tab. Did not check the older bldc tool though.

I should probably just shut up and try doing something already :slight_smile: . I would still primarily try to adapt old Geckoā€™s code and see what happens.

Hi Everyone

After installed newest library, I still have the problem with real time data delay on the OLED display. Is there something wrong I made it? Can you help to share how to solve it? thanks

The link on below are the library that I used, and the ESC I used is VESC4. After installed the library, I roll the throttle to max and min, the value shows on OLED are delay every time.

Thanks

Yeah it says ppm in the vesc interface but seems to work fine with pwm signal, I check it with one of those cheap jbtek oscilloscopes and looks like varying pulse width to me but after calibration works as intended. Side note too just had my remote start drifting on values it was sending recently and seems to have been from a loose connection to the potentiometer in the remote so just something to look out for (behavior being you see data coming into the receiver but it doesnā€™t line up with the trigger position). Ideally would want it to pull the pin down to gnd so at worst it sends a brake signal instead of ever floating high and sending a full throttle signal. Anyhow just saying make sure whatever code or setup you go with you test the hell out or everything with regard to pulling individual wires and seeing the behavior in case any connections between the nrf and Arduino or the Arduino and potentiometer or between Arduino and esc come loose, make sure your fail-safes work appropriately.


Also just to add I made some small adjustments to my code for carrying two data points and used basically the same hardware to replace a radio for my RC car with steering control and a regular hobby esc and it also works fine using the servo library for handling sending out the pulses.

1 Like

Finally, it worked properly

5 Likes

Still the same on the master branch

Iā€™ve got a question. Since I still donā€™t get the VESC readings sent to my Remote I have no clue anymore. Do I need the ā€œoldā€ BLDC Tool or can I also use the ā€œnewā€ VESC Tool?

Iā€™m running a VESC 4.12 with Firmware 3.38. Edit: Oh yeah, and I have tried the master and developer branch.

I would be really pleased if someone could help me. I guess it is a pretty dumb failure I did here but I donā€™t see it :smiley:

1 Like

I have same problems too :smiley:

Try to load some simply program to try the comm like:

#include <SPI.h> #include <nRF24L01.h> #include <RF24.h> RF24 radio(9, 10); const byte address[6] = ā€œ00001ā€; void setup() { radio.begin(); radio.openWritingPipe(address); radio.setPALevel(RF24_PA_MIN); radio.stopListening(); } void loop() { const char text = ā€œHello eBoardā€; radio.write(&text, sizeof(text)); delay(1000); }

for transmitter (remote) and:

#include <SPI.h> #include <nRF24L01.h> #include <RF24.h> RF24 radio(9, 10); const byte address[6] = ā€œ00001ā€; void setup() { Serial.begin(9600); radio.begin(); radio.openReadingPipe(0, address); radio.setPALevel(RF24_PA_MIN); radio.startListening(); } void loop() { if (radio.available()) { char text[32] = ā€œā€; radio.read(&text, sizeof(text)); Serial.println(text); } }

to reciever

but honestly I have problems too and can not come to them (try different modules etc.)

Edit: Now im buying these modules Page Not Found - Aliexpress.com with ceramic antenna and maybe it will work propertly