thankthemaker / rESCue

rESCue - add more safety and control to your VESC based vehicle
GNU General Public License v3.0
104 stars 27 forks source link

Can not get BLE-Uart bridge to work #57

Closed aka13-404 closed 1 year ago

aka13-404 commented 1 year ago

Great coneption! Sadly, seemingly my incompetence does not permit me to get the BLE bridge working. I flash the esp successfully, I am connected to the uart on the VESC (I had an nrf working properly there), I am soldered to GPIO 16 &17, I have APP set to UARD on my single ubox. I can successfully connect to the flashed ESP, but get "make sure port belongs to vesc". What could I be doing wrong? I have just to be sure swapped the tx-rx cables a couple of times to no success. image

thankthemaker commented 1 year ago

How did you build the rEScue firmware? It's preconfigured to use CANBUS, to switch to UART you have to build it with CANBUS-only disabled in config.h

Also make sure to connect the ESP and the VESC to the same GND, UART needs a common GND.

aka13-404 commented 1 year ago

I have to admit, this is the very first time I build anything for embed myself. Kudos for such a quick reply. I never bothered to check any configs, since the readme did not mention them.

What would I configure, if the only thing I need is the uart-ble bridge?

image Tried commenting out canbus only, and it does not get built for me.

aka13-404 commented 1 year ago

image Well, this has worked perfectly. I connect and read VESC as expected. I tried to comment out all the LED stuff (for now it is unlikely, that I will run LEDs), but it errored out. Guess, there is no "no led mode" :D Thank you again, you saved my evening.

thankthemaker commented 1 year ago

Sorry, I mismatched CANBUS_Enabled and CANBUS_only. Why did you need to comment out LED stuff?

aka13-404 commented 1 year ago

Well, as mentioned, right now and for the foreseeable future I only care about the ble-uart bridge. All else looks pretty sweet, but right now I don't use it, so I thought that perhaps it's modular and I should disable it for now.

svenkvade commented 1 year ago

If I were to only use this as a replacement for the bluetooth modules as a BLE-UART bridge, would this run on an ESP8266 as well? Or better to just get a 32 regardless? Thanks

topoll113 commented 1 year ago

@thankthemaker same as author Im not able to make UART work with VESC tool . I out commented " #define CANBUS ENABLED " in config.h and also changed " default_envs = wemos_d1_mini32 " to " default_envs = nodemcu-32s " in platformio.ini in order to match my board. rESCue app reading VESC values . I hooked ESP32 with VESC 75100. I tried 6.0, 5.02 and 5.01 firmware but no luck with any of them... Any idea ? Edit: rESCue not working with VESC Tool 6.0 but It does with 3.01. Any chance that this could be fixed ?

thankthemaker commented 1 year ago

If I were to only use this as a replacement for the bluetooth modules as a BLE-UART bridge, would this run on an ESP8266 as well? Or better to just get a 32 regardless? Thanks

It's possible but it would need some adjustments as some parts are specific to the ESP32. The project started with support for both ESP8266 and ESP32, but it was hard to maintain and so I decided to skip the ESP8266 support.

thankthemaker commented 1 year ago

@thankthemaker same as author Im not able to make UART work with VESC tool . I out commented " #define CANBUS ENABLED " in config.h and also changed " default_envs = wemos_d1_mini32 " to " default_envs = nodemcu-32s " in platformio.ini in order to match my board. rESCue app reading VESC values . I hooked ESP32 with VESC 75100. I tried 6.0, 5.02 and 5.01 firmware but no luck with any of them... Any idea ? Edit: rESCue not working with VESC Tool 6.0 but It does with 3.01. Any chance that this could be fixed ?

It should work, have yuo checked the PINs? The ESP32 has 3 UART ports, which one did you use? It's also important to use a common GND for ESP32 and VESC.

topoll113 commented 1 year ago

@thankthemaker same as author Im not able to make UART work with VESC tool . I out commented " #define CANBUS ENABLED " in config.h and also changed " default_envs = wemos_d1_mini32 " to " default_envs = nodemcu-32s " in platformio.ini in order to match my board. rESCue app reading VESC values . I hooked ESP32 with VESC 75100. I tried 6.0, 5.02 and 5.01 firmware but no luck with any of them... Any idea ? Edit: rESCue not working with VESC Tool 6.0 but It does with 3.01. Any chance that this could be fixed ?

It should work, have yuo checked the PINs? The ESP32 has 3 UART ports, which one did you use? It's also important to use a common GND for ESP32 and VESC.

Wiring is okay. I connected UART to pin 16 & 17. I’m getting reading in rESCue app and I’m able to connect with VESC Tool ver. 3.01. When I’m trying connect with VESC Tool ver. 6 I’m getting message: “ Could not read firmware version. Make sure that selected port really belongs to VESC”.