Closed lesharodin closed 7 months ago
What board(s) are you using again? Is it just the standard DevKitC?
What board(s) are you using again? Is it just the standard DevKitC?
Just a standart NodeMCU ESP32 boards, I dont think the problem is with boards because if flashes well and it worked well on previous versions.
What board(s) are you using again? Is it just the standard DevKitC?
Just a standart NodeMCU ESP32 boards, I dont think the problem is with boards because if flashes well and it worked well on previous versions.
The plugin has been primarily been developed on a Windows PC, so initially I don't think the code base is the issue right now. You've mentioned having issues with other beta versions in the past, especially on Windows, so I wonder it if could be a driver issue.
Drivers for the typical USB to serial converter chips that are used on the ESP32s can be found here
Another thing to try is to add a logging line here
It could be closing the port because it wasn't receiving the right message from the esp32
Another thing to try is to add a logging line here
It could be closing the port because it wasn't receiving the right message from the esp32
Loaded plugin module VRxC_ELRS v1.0.0-beta.3 Attempting to find backpack Attempting to find backpack on COM7 Could not find connected backpack. Ending connector thread.
Added logger to line https://github.com/i-am-grub/VRxC_ELRS/blob/8fc3968589f4375de5fd89bfb5bc57ebcab23aa5/elrsBackpack.py#L170 and it doesnt apper in log
What board(s) are you using again? Is it just the standard DevKitC?
Just a standart NodeMCU ESP32 boards, I dont think the problem is with boards because if flashes well and it worked well on previous versions.
The plugin has been primarily been developed on a Windows PC, so initially I don't think the code base is the issue right now. You've mentioned having issues with other beta versions in the past, especially on Windows, so I wonder it if could be a driver issue.
Drivers for the typical USB to serial converter chips that are used on the ESP32s can be found here
I dont think its a driver issue, I cant flash esp any time no problem. I can run pkendall64 test message code no problem too. (https://github.com/ExpressLRS/Backpack/pull/96) I allready tried to uninstall/install recomended drivers.
Does adding logger.info(response)
before what's currently in line 154 give you anything?
Does adding
logger.info(response)
before what's currently in line 154 give you anything?
Yes
Loaded plugin module VRxC_ELRS v1.0.0-beta.3 Attempting to find backpack Attempting to find backpack on COM7 [0, 248, 120, 120, 120, 120, 0, 128] Could not find connected backpack. Ending connector thread.
Does adding
logger.info(response)
before what's currently in line 154 give you anything?Yes
Loaded plugin module VRxC_ELRS v1.0.0-beta.3 Attempting to find backpack Attempting to find backpack on COM7 [0, 248, 120, 120, 120, 120, 0, 128] Could not find connected backpack. Ending connector thread.
So it looks like its an issue with the backpack. the proper response should be [36, 88, 62, 0, 128, 3, 6, 0]
Does adding
logger.info(response)
before what's currently in line 154 give you anything?Yes Loaded plugin module VRxC_ELRS v1.0.0-beta.3 Attempting to find backpack Attempting to find backpack on COM7 [0, 248, 120, 120, 120, 120, 0, 128] Could not find connected backpack. Ending connector thread.
So it looks like its an issue with the backpack. the proper response should be [36, 88, 62, 0, 128, 3, 6, 0]
This is from another ESP module
Loaded plugin module VRxC_ELRS v1.0.0-beta.3 Attempting to find backpack Attempting to find backpack on COM1 [36, 88, 62, 0, 16, 0, 6, 0] Could not find connected backpack. Ending connector thread.
If you change msptypes.MSP_ELRS_BACKPACK_SET_MODE
to msptypes.MSP_ELRS_GET_BACKPACK_VERSION
here, that should get the second ESP module to work with the old backpack firmware.
I thought that the firmware in the beta 2 was suppose to support that, but it looks like I forgot about the config changes I made for the elrs pull request. I'll just those update, thanks for the help!
If you change
msptypes.MSP_ELRS_BACKPACK_SET_MODE
tomsptypes.MSP_ELRS_GET_BACKPACK_VERSION
here, that should get the second ESP module to work with the old backpack firmware.I thought that the firmware in the beta 2 was suppose to support that, but it looks like I forgot about the config changes I made for the elrs pull request. I'll just those update, thanks for the help!
Yes, it works now:
v1.0.0-beta.3 Attempting to find backpack Attempting to find backpack on COM1 [36, 88, 62, 0, 16, 0, 6, 0] Connected to backpack on COM1 Backpack version: master
Maybe you need to leave that extra loggers in code just for future user debugging :)
yup you are right, they are going to be pushed up to master
fairly soon. If you wanted to test with the updated firmware, I did switch out the esp32 firmware that was included with the beta.3
release
yup you are right, they are going to be pushed up to
master
fairly soon. If you wanted to test with the updated firmware, I did switch out the esp32 firmware that was included with thebeta.3
release
Flashed with https://github.com/i-am-grub/VRxC_ELRS/releases/download/v1.0.0-beta.3/firmware-esp32.zip And return https://github.com/i-am-grub/VRxC_ELRS/blob/8fc3968589f4375de5fd89bfb5bc57ebcab23aa5/elrsBackpack.py#L160
Loaded plugin module VRxC_ELRS v1.0.0-beta.3 Attempting to find backpack Attempting to find backpack on COM1 [120, 128, 0, 120, 128, 120, 0, 120] Could not find connected backpack. Ending connector thread.
Hmm now its connected.. Didnt change anything
Loaded plugin module VRxC_ELRS v1.0.0-beta.3 Attempting to find backpack Attempting to find backpack on COM7 [36, 88, 62, 0, 128, 3, 6, 0] Connected to backpack on COM7 Backpack version: master
Another ESP too (reflashed)
v1.0.0-beta.3 Attempting to find backpack Attempting to find backpack on COM6 [36, 88, 62, 0, 128, 3, 6, 0] Connected to backpack on COM6 Backpack version: master
Every time the esp is rebooted, it will send out a bunch of messages over serial during it's startup process. If Windows tries to communicate too early, it receives a bunch of junk back as a response as shown in one of your earlier messages.
I can test esp8286 too, shoud I build it from you PR https://github.com/ExpressLRS/Backpack/pull/114 ?
yes please. I don't have any firmware currently compiled for the 8266 yet
yes please. I don't have any firmware currently compiled for the 8266 yet
Esp8266 works too Loaded plugin module VRxC_ELRS v1.0.0-beta.3 Attempting to find backpack Attempting to find backpack on COM6 [36, 88, 62, 0, 128, 3, 6, 0] Connected to backpack on COM6 Backpack version: master
didnt actually test osd messages yet, will test later, but it was working with diferent code before
Just had some new devkits show up, and they gave me the same issue where they wouldn't connect to Windows. it looks like adding in this sleep fixes it for some reason.
Windows + esp32 (fresh fw) + beta3 plugin Start log: v1.0.0-beta.3 Attempting to find backpack Attempting to find backpack on COM6 - It detects port correctly Could not find connected backpack. Ending connector thread.
I added extra logger to see if it detect a port
Tried to replug esp several times, didt help
For some reason it didnt fall back to
logger.warning('Failed to write to open serial device. Attempting to connect to new device...')
Only straight to closing port