06-08-2010 12:35 PM
Solved! Go to Solution.
06-08-2010 12:49 PM
06-08-2010 01:22 PM
06-08-2010 01:33 PM
RossGE wrote:
Yes, It is a Mahr Federal Maxim XL Indicator. I have it connected through a serial port on it through an adapter to a USB.
I am assuming you mean a USB <--> Serial adapter.
Its output according to the data sheet is Serial BCD, 13 digits, 52 bits; ASCII encoded 2400 baud asynchronous stream. Here are the data sheets i found online http://www.mahr.com/scripts/relocateFile.php?ContentID=6595&NodeID=11586&FileID=6996&ContentDataID=2...
The first thing you should do is to open up HyperTerminal if you're on Windows or an equivalent serial communication program if you are running a different OS. Set up the communication program for 2400 baud. It doesn't indicate number of stop bits or parity, so assume 8 data bits, 1 stop bit, no parity, and no flow control. See if you have something show up in the communication program. If you don't, then either the communication parameters are not correct, or you have a hardware problem, like a cable issue. Likely cabling issue is whether you need a null modem adapter or not.
Do this BEFORE you even think about delving into LabVIEW. The above exercise will also allow you to see if the device continuously spits out information, or if it requires some sort of "start" trigger.
06-08-2010 01:52 PM
I opened hyperterminal and inputted the specifications you advised. It said that it was connected but, nothing came up in the window. On the issue of contiuous flow i have an original cord that has a trigger button but, I initially concluded that i would need continuous flow to get the results and connections I needed and therefore part of my adapter cables has a switch for continuous flow. To check between the trigger cord and the continuous flow I tried them both and the trigger cord wouldn't even connect.
06-08-2010 01:58 PM
When said "continuous" I was referring to the device continuously sending a measurement over the serial port. Some instruments (like some DMMs) can continuously send out their measurement over the serial port without being explicitly asked for it.
If you cannot get this to work in HyperTerminal then it will never work with LabVIEW. You will need to check whatever other documentation you may have for the device to determine how to hook up the serial interface. If you have no other information then you will need to contact the manufacturer. Don't even mention LabVIEW to them. Just ask them how to connect the device so you can see the measurement(s) over HyperTerminal.
06-08-2010 02:16 PM
06-09-2010 12:31 PM
06-09-2010 01:14 PM
I'm assuming you mean "HyperTerminal" when you say hyperlink, unless you're using another program called hyperlink? In any event, if you can get it to work with HyperTerminal then you can open the "Basic Serial Write and Read" example that ships with LabVIEW. To replicate how HyperTerminal behaves you basically need a while loop around the read part. In other words, the case structure sorrounding the read gets replaced with a while loop. Since the device continuously send out data, you don't need the write part and you can essentially delete it.
You will eventually need to implement looking for the start of the measurement and the end. If the device ends a measurement with a special character, such as a linefeed, then you can configure the serial port connection to use a termination character and set the termination character to the one the instrument uses. The "Advanced Serial Write and Read" shows you how to configure the serial port to use a termination character to end a read. You can also use this example to start with since that already has a loop around the read. I suspect that the extra serial port parameter line flow control are not relevant to this setup, and you can leave them at the default value.
06-14-2010 09:51 AM