Monitor only one the USB to PC ?

Hi

How to monitor only the USB communication between the Arduino and the PC ?

I have connected a device to TXD & TXR pins on an Arduino Uno. When I send a message to the device I like to monitor the response on the RDX (a = Serial.readString():wink: , when I do serial.print(a) I can see the message that came in to RDX in the serial monitoring window BUT also this message is sent to the TXD pin again :slight_smile: ...so I get a loop.

There has to be a fundamental way to avoid this ?

I.e. I like to have one serial.print to the device and a serial.print for the USB or the serial monitoring window.

anyone know how to do this ?

I use arduino 1.8.13

BR
/Erik

You should probably use SoftwareSerial to create a second serial port on two other pins and use that for your mystery device. That way pins 0 and 1 are kept free for communication with the PC.

...R

Hello, ahh, problem solved, it was easy as I suspected :slight_smile:
BR
/Erik

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.