-
• #2
Maybe you need to do your Serial2.setup() inside the onInit() function?
The reset() function seems to not fully initialize the ESP32. But if you use ESP32.reboot() it seems to be very clean, just like a hardware poweron.
If I do just
reset(true);
Serial3.setup(115200);
save();
ESP32.reboot();
THEN try to use Serial3, it isn't really setup. But if I do:reset(true);
function onInit() {Serial3.setup(115200);}
save();
ESP32.reboot();Then I can use Serial3, as in Serial3.write('foo!\r\n');
BUT
reset(); or reset(true); end up with those same
E (13760) uart: uart_read_bytes(906): uart driver error
messages in all cases. reset() on ESP32 isn't reliable, it seems.
ESP32.reboot(); is reliable.SO:
#1) Put your Serial2.setup() inside onInit()
#2) Avoid reset() on ESP32 unless you want to do reset(true) to clear out the saved program.-Dave
-
• #3
Ok the root of the problem with the
E (203529) uart: uart_read_bytes(857): uart driver error
messages is in targets/esp32/jshardwareUart.c line 38 or so in function UartReset()
if(serial2_initialized) uart_driver_delete(uart_Serial2);
if(serial3_initialized) uart_driver_delete(uart_Serial3);
These should set the corresponding flag serialX_initialized to false but they don't.
if(serial2_initialized) {uart_driver_delete(uart_Serial2);serial2_initialized=false;}
if(serial3_initialized) {uart_driver_delete(uart_Serial3);serial3_initialized=false;}Then reset(); ought to work fine without causing the spewing...
-
• #4
After you enable ESP32 connect via WIFI, reset() works without error. If you want to work via serial, you need to first make a hard reset and then connect through port, then there are no errors. Fun feature, we spent 2 days :)
Good day! The problem is this, when I begin to ship in esp32 code starts to take off error the port. If loading and not hung or not started endless reboot, give the command save(). The module then runs erratically or not work at all. What could be wrong?
I connected SIM800l on usart2.
CODE:
And take off that scary things
What does it all mean?