I want to simulate the output of a serial sensor via the Arduino Uno’s TX (pin 1) output and read it on another datalogger that has an Rx input. Before connecting the serial output, I wanted to test the output by connecting the Tx line to a DB9 that is connected back to the PC via a USB serial adapter and running Putty. I have set up my test as follow:
Programmed the ARDUINO UNO to output a value of 0 as per the example below.
void setup() {
Serial.begin(9600);
}
void loop() {
Serial.println("0");
delay(500);
}
I connected a wire from pin 1 (TX) on the Arduino to pin 2 of a DB9 serial cable that is the Rx line.
The DB9 is connected to a USB serial cable connected to a PC using Putty.
Putty is programmed with the same Baud rate and configuration 8,N, 1
Problem: Uno’s Tx light flashes accordingly and I can see the data correctly using the Serial monitor. Data received on Putty shows as garbage but at the correct delay sequence. I have tried several settings but I cannot seem to get the correct ASCII string.
Output seen on Putty. I must add that the program sends Serial.Println("0), then Serial.Println(10..100) in subsequent lines with a delay of 500 per line. Just wanted to keep the programming message short.