07-17-2019 04:58 PM
Hi,
I am attempting to control an XY translation stage using the Ludl MAC2002 controller. The module has an RS232 25 pin out port and I connected to my Windows PC using the provided 25pin to 9 pin RS232 cable and a RS232 to USB converter cable. The command seems to be written onto the controller because the RS232 LED status turns green whenever the command is sent. However, no response is found and the stage doesn't response according to the command. Has anyone experience with this module before? Any suggestion is really appreciated.
07-18-2019 01:46 AM
Hi hlmax,
Did you read your own device manual? (I don't think so…)
Just on page 1 it lists "Basic rules"! You didn't follow those BASIC RULES: append a CarriageReturn char to your commands!
Did you any of those "how to do serial communication?" threads here in the forum? (I don't think so…)
Don't use BytesAtPort! As can be read on page 2 of your manual your device answers with strings using the LineFeed as TermChar! All you need to do is to read an answer of 999 bytes after sending a valid command to your device!
07-22-2019 11:53 AM
Hi GerdW,
Thank you for your suggestion. I changed the code accordingly and before running the code, I checked the NI MAX to make sure the connection is okay but I also have the same error when reading (writing is okay). I also checked the DIP switch in the controller box and made sure it's 9600 baud rate with low level communication mode (ASCII command). Am I missing something here?
07-22-2019 02:07 PM - edited 07-22-2019 02:08 PM
07-23-2019 01:27 PM
Thanks a lot for your help GerdW. I tried your code, it also puts out similar timeout error 1073807339 at the VISA Read. I tried the HyperTerm before and it also wrote but no response in read 😕
We will probably move on to hard wire the stage motor with voltage inputs for now but this error is bothering when it should be straightforward.