My goal is controlling an HP signal generator via RS232.
The HP requires simple text strings (ie, "SYSTEM:BEEP") followed by CR (CRLF optional). Queries returned text strings (ie, "FREQ?").
When I connect the HP directly (well, via USB/serial adapter) to the computer running CoolTerm I can control the HP. When connected to Arduino I can't get any response from the HP. (See code, attached.)
When connecting the Arduino to CoolTerm I receive the control string "SYSTEM:REMOTE" but when Arduino is connected to the HP, nothing. (The TD LED flashed on the RS232 adapter connected to the Arduino.)
I get nothing from HP: no change of the display, no beep, no RS232 response. For query to HP, I am supposed to see a response. For command, no response, just change in the display.
Coan you list the wiring running list of the 2 setups you are using, as I still suspect a hardware error in your connection method.
correct these running lists to your actual setups :
the working setup using PC montor USB to TTL level converter to HP.
a) usb cable from PC to usb port on 232 converter
b) 232 converter output, standard serial 232 null modem cable to HP
the NON-working setup using Arduino USB to 232 converter to HP
a) usb cable form Arduino to 232 converter
b) 232 converter output, standard serial 232 null modem cable to HP
The depicted setup above wont work with Arduino, as the USB on your PC is a master USB port.
On your Arduino the USB is a slave USB port.
Pls note : dont get lost in USB port discussions, if that is NOT the issue, if you are using a different setup than depicted above.
the working setup using PC monitor application:
a) RS232 serial null-modem cable direct to HP
the NON-working setup using Arduino USB to 232 converter to HP
a) direct wiring (jumpers) to 232 converter
b) 232 converter output, standard serial 232 null modem cable to HP
the working setup using PC monitor application:
a) USB cable from PC to USB/serial adapter
b) RS232 serial null-modem cable from USB/serial adapter to HP
the NON-working setup using Arduino USB to 232 converter to HP
a) direct wiring (jumpers) to 232 converter
b) 232 converter output, standard serial 232 null modem cable to HP