ESP32-Serial-Bridge icon indicating copy to clipboard operation
ESP32-Serial-Bridge copied to clipboard

Is there a way to make it work @1MBps ?

Open florian-guillemard opened this issue 4 years ago • 5 comments

Hi, I spend a lot of time to make it work at more than the baudrate of 230400 bps. I need to use it at > 1 000 000 bps but whatever I do, it doesn't :( Any idea ? Did you make it ? Thanks for your help!

florian-guillemard avatar Jan 07 '20 19:01 florian-guillemard

No, nerver needed more than 115kBd and this version is not intended to be faster that 230kBd. I'm afraid it cant be faster in polling mode. You can try using serial Rx/Tx interrupts together with DMA filled FIFOs for a higher baudrate. But I doubt you can do with with the arduino IDE https://docs.espressif.com/projects/esp-idf/en/latest/api-reference/peripherals/uart.html#uart-api-using-interrupts

https://www.espressif.com/sites/default/files/documentation/esp32_technical_reference_manual_en.pdf#page=342 https://www.espressif.com/sites/default/files/documentation/esp32_technical_reference_manual_en.pdf#page=116

AlphaLima avatar Jan 07 '20 19:01 AlphaLima

Thanks for your reactivity! I'm using the Arduino framework but I work on Platformio.. not sure this is changing something :/ Apparently, my problem is not on the serial but on the TCP! I tried to get (without interrupt) data on Serial(1,3) and put it on Serial(16,17) @ 1Mbps and I'm having NO problems at all..

florian-guillemard avatar Jan 08 '20 07:01 florian-guillemard

OK, the data rate depend on the WiFi Link quality, given that you tried different distances and locations. The TCP protocol has a lot of data correction overhead, maybe you switch to UDP and increase the packet sizes for a better payload/overhead ratio.

AlphaLima avatar Jan 08 '20 07:01 AlphaLima

Seems that I have just problems from serial to TCP.. not serial to serial and neither TCP to serial :/ The packet size is around 500 and I kept a buffer of 1024.. For my test, i'm using telnet under Macosx, I'm not sure if there is a better solution to test the ESP, if you have something else, I will be glad! Thanks for your help ;)

florian-guillemard avatar Jan 08 '20 10:01 florian-guillemard

It appears that TCPClient.write(buf2, i2) is taking too long. But why is that ?!

florian-guillemard avatar Jan 08 '20 10:01 florian-guillemard