RS232 - No communication with specific device (TX voltage drops)

Hello everyeone,

This is my very first forum post so please correct me if I'm doing something wrong.

I'm working on an Arduino sketch that communicates with my Growatt inverter.
This should allow me to receive various information from the inverter (e.g., output power, voltages, etc.).

The Growatt inverter supports RS232 communication so I've decided to buy an RS232 shield for my Arduino Uno.
To be exact, I'm using the RS232 Arduino Uno shield from Keyestudio: KS0406 keyestudio RS232 to TTL Conversion Shield Compatible with Arduino - Keyestudio Wiki

I've basically finished the software but for some reason I receive no response from the inverter over RS232.
To troubleshoot this, I've already tested several things, of which the following list of tests were succesful:

  • I was able to connect the Arduino Uno using the RS232 shield and a straight-through cable (let's call this cable "cable A") to an RS232-to-USB converter to my laptop. I was able to receive the data properly and transmitted data from the laptop was received properly by the Arduino (this basically simulates the behavior of the inverter).
  • I was also able to connect an RS232 straight-through cable (let's call this "Cable B") from the RS232-to-USB converter from my laptop to the RS232 port of the inverter. I was able to transmit the same data that the Arduino sketch is transmitting and actually received a proper response from the inverter.

Now for the weird part, when I use "Cable B" to connect the Arduino Uno using the RS232 shield directly to the inverter, no data is received from the inverter.

Using the results of the tests above, I think I can make a few assumptions:

  • Cable B is wired properly, since I was able to use this cable to communicate from my laptop to the inverter.
  • The RS232 shield seems to be working for both transmitting and receiving, since I was able to use "Cable A" to send and receive data to and from my laptop.

This leaves my quite puzzled to be honest, since everything seems to be in order.

As a final test, I took my digital oscilloscope to take a look at the TX and RX lines on the RS232 shield.
I noticed something interesting there.

When leaving the RS232 connector on the RS232 shield disconnected or when connecting it to my RS232-to-USB adapter on my laptop (using "Cable A"), the voltage levels varied between approx. -7V and +7V:


After connecting the RS232 connector to the inverter (using "Cable B"), I noticed that the voltage levels for the TX line (coming from the Arduino) dropped significantly to approx. -7V and -3V (so no positive voltages anymore at all):

As a truely final test I measured the voltages of the TX line of "Cable B" when I used that cable to connect my laptop to the inverter. I noticed that the voltages varied between approx. -7V and +7V, which I suppose is fine:

I suppose the dropping voltages explain the reason why the inverter does not respond, but I am absolutely clueless about why the voltages actually drop.

Does anyone have any idea what could be the reason for the dropping voltages?

Thanks in advance!

Kevin

Voltages drop because of a load placed on the circuit. You ask questions that only you can answer because you have not supplied any information to form an answer. Draw a schematic of how you have all the connections made for each of your tests. Supply links or data sheets for all your adapter devices. Did you tell us which Arduino board you are using?

Your scope picture of the RS-232 signal looks proper. RS-232 uses +3 to +25 volts and -3 to -25 volts for signalling. Today the high limits are usually around 12 volts. The voltages that are not valid are those between +3 and -3.

Paul

Alright, I managed to solve the issue. Apparently the RS232 shield uses a male DB9 connector while the shield itself seems to be wired internally as a DCE device (which I suppose is kind of uncommon?).
Interestingly enough all other RS232 shields I find online have a female DB9 connector instead.
Because of this, basically the TX and RX connectors were mixed up causing the TX from the shield being connected to the TX of the inverter (I would need a null-modem cable instead of a straight-through cable).
I suppose this explains the dropping voltages since multiple devices are "pulling" the TX line.
I resoldered the pinning of the cable and everything is working fine now.

Welcome to the world of data communications! You have discovered why test equipment is necessary.

Paul