So I have an issue that I can't really think of a reason why it would be happening. I have an Arduino Mega connected on Serial3 to a RS232 breakout board with a male DB9 connector on it. I then have two female breakout boards connected. One is connected to the RS232 breakout board and the other to a Cisco DB9 to roll over cable, which is connected to my Cisco Switch, or if it is, it is being ignored.
For some reason no data sent from the Arduino is making it to the Cisco switch that I can tell. I did confirm that it is sending data using a USB to DB9 adapter and PUTTY. I can send and receive data from both the Arduino and PUTTY correctly to the other.
I can receive data from the switch perfectly. Cisco's default settings are the same as the Arduino's, 9600, 8bits, no parity, 1 stop bit etc...
I can also connect the switch to the USB to DB9 adapter directly and send and receive fine through it / PUTTY as well.
Does anyone have any suggestions why I'd be able to send data to and from Putty, but only receive data from the switch, or why the data going to the switch is failing?
void setup() {
Serial.begin(9600, SERIAL_8N1);
Serial3.begin(9600, SERIAL_8N1);
Serial.println("Ready....");
Serial.println();
}
void loop() {
// read from Serial3, write to Serial
if (Serial3.available()) {
int inByte = Serial3.read();
Serial.write(inByte);
}
// read from Serial, write to Serial3
if (Serial.available()) {
int inByte = Serial.read();
Serial3.write(inByte);
}
Serial3.println(); // Added just to test if a cr could be passed
Serial3.write(98); // Added just to test if a character could be directory passed
Serial3.write(10); // Added just to test if a cr could be passed
}