0

I have an issue with an Arduino Nano.

I want to communicate with it through the Serial-Port. Meaning I want to send and receive Serial commands. With USB and the "Serial Monitor" this works nice. Now I have connected the COM-Port of the PC with Adruinos Digital Pins 0 and 1 (RX and TX) and a GND PIN. (3 Cables total).

Here is a minimal example of my Code:

void setup() {
 Serial.begin(9600,SERIAL_8N1);
 Serial.println("Start");
}
void loop() {
 Serial.println("Hello World");
 delay( 1000 );
}

The Serial Monitor says:

Start
Hello World
Hello World
Hello World
Hello World
...

Putty however says:

▒▒▒R▒▒▒t▒*▒▒▒R▒▒▒t▒*▒▒▒R▒▒▒t▒*▒▒▒R▒▒▒t▒*▒▒▒R▒▒▒t▒*▒::
 ▒▒t▒*▒▒▒R▒▒▒t▒*▒▒▒R▒▒▒t▒*▒▒▒R▒▒▒t▒*▒▒▒R▒▒▒t▒*▒▒▒R▒▒▒t▒*▒▒▒R▒▒▒t▒*▒▒▒R▒▒▒t▒*▒▒ ▒R▒▒▒t▒*▒▒▒R▒▒▒t▒*

Putty is connected with - BaudRate: 9600 - Data Bits: - Stop Bits: 1 - Parity: None - Flow Control: None

What is wrong here?

Update: The PC has a 9-pin D socket (Image) This is connected to a RS232 to RJ45 connector (image) From the RJ45-Cable I used the Brown, Blue, and White/Green Cable to connect with the Arduino

asked Dec 21, 2015 at 12:51
2
  • 1
    Is this a 9-pin D socket built in to the PC? Commented Dec 21, 2015 at 12:57
  • I have updated my question Commented Dec 21, 2015 at 13:04

1 Answer 1

3

RS232 is not TTL. You need a level converter. For more details see https://www.sparkfun.com/tutorials/215.

answered Dec 21, 2015 at 12:59
1
  • Thanks. That's it! I just found it in the documentation: "Don't connect these pins directly to an RS232 serial port; they operate at +/- 12V and can damage your Arduino board." arduino.cc/en/Reference/Serial Commented Dec 21, 2015 at 13:14

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.