Connecting YAT terminal to Arduino Monitor via ESP32-S3-OTG

vapisoft
Posts: 12
Joined: Sun Sep 03, 2023 6:12 am

Connecting YAT terminal to Arduino Monitor via ESP32-S3-OTG

Postby vapisoft » Sun Sep 03, 2023 12:11 pm

I connected the USB to a YAT terminal (on the PC) via Port 23 (the Arduino uses Port 21).
Now it works only Half duplex depending on the settings of the “Flow Control” parameter in the YAT settings.

Hardware (RTS/CTS) works from Arduino to Terminal.
Software (XOn/XOff) works from Terminal to Arduino.
Combined (RTS/CTS + XOn/XOff) works from Arduino to Terminal.

What do I need to do to make it work Full duplex?

The software:
  1. void loop() {
  2.   while(HWSerial.available()){
  3.     size_t l = HWSerial.available();
  4.     uint8_t b[l];
  5.     l = HWSerial.read(b, l);
  6.     USBSerial.write(b, l);
  7.     HWSerial.println("loop: from monitor");
  8.   }
  9.   while(USBSerial.available()){
  10.     size_t l = USBSerial.available();
  11.     uint8_t b[l];
  12.     l = HWSerial.read(b, l);
  13.     HWSerial.write(b, l);
  14.     HWSerial.println("loop: from terminal");
  15.   }
  16.  

Who is online

Users browsing this forum: Google [Bot] and 45 guests