Closed centripetal3 closed 3 years ago
I don't think that it a concurrency problem it seems that the USB signal is too weak I would suggest to change the USB cable, check that all the connections are well made, and if it doesn't solve the problem check with another PC, if the problem persist, I would lower the baudrate to see if it helps.
hi @centripetal3 did you tried my suggestions?
Yes, and it did not help.
@centripetal3 have you tried with the same PC and cable using something like QuinLED-Dig-Uno?
It's worth a try. I'll see if I can find a QuinLED-Dig-Uno with an ESP32 board and reproduce the problem.
Has anybody else been successful using an ESP32? If so, did it require any special configuration?
@centripetal3 hey yes, Luciferin runs great on ESP8266/ESP32 devices, there are tons of users using Luciferin on ESP32. 😃
I think that we discovered the cause.
Pixel Pro uses MCP2221T chip that is capable of 115200 baudrate with a whopping 16% error. I think that CH340C chip will be a lot better for the purpose since Luciferin needs around 500K baud rate to run great. :)
feel free to reopen the issue or to continue commenting in this issue if you find something else interesting.
Thanks for your interest in the project and if you like it don't forget to cast a star here on GitHub 👍
Firefly Luciferin version
2.0.1
Glow Worm Luciferin version
5.0.1
Firmware type
LIGHT
What is the stream method?
USB
Fiefly Luciferin config file
No response
Relevant log output
How to reproduce
Hi guys,
I'm trying to run GlowWorm on an ESP32 CPU connected via USB. The PCB is Dr.Zzs PixelPro and the ESP32 module is the WROOM-32E. I haven't had any success getting FireFly to talk to GlowWorm yet, and am trying to figure out how/where to begin troubleshooting. The first thing I notice is that FireFly frequently has jumbled values in the "Devices" table. I think this points to an underlying issue in the GlowWorm serial output, and indeed, if I open a serial monitor when I plug in the ESP32, I receive the stream as shown in "Relevant log output". You can see that "MAC:34:AB:95:4B:7A:08" is jumbled up with "baudrate:3" and "effect:0".
I'm looking at the GlowWorm code to try to find out why the output gets jumbled. It looks like it only happens when the serial output is being handled by a task. You can see that the output produced during
setup()
is fine, but the output produced duringtcpTask()
has the problem. I'm not sure if this means it is a race condition, or a buffer overflow from a separate thread, or something else entirely.How can I narrow this down further?
Thanks!