From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Need VI to read Micro-epsilon laser data

I would like to use LabView to read the data from a micro-epsilon laser displacement sensor (model #1401-20). The laser connects to the COM port via a RS232 connector. Micro-epsilon does not support LabView, but does supply a .dll file. Being a novice in LabView, I would appreciate any advice/help on how to access the data from the laser so I can use it from within LabView. Thanks.
0 Kudos
Message 1 of 12
(9,175 Views)
You can try to interface to the DLL with the Call Library Fucntion Node. This is on the Advanced palette. There is a shipping document called "using External Code in LabVIEW" that descibes how to use it. Go to Help>Search the LabVIEW Bookshelf to read it. Your other option is it directly communicate with it using the LabVIEW serial port functions. There are a couple of shipping examples for serial communication. They use VISA Writes and Reads to send/receive data over the serial port. You can also try the Instrument I/O Assistant. This too uses VISA to communicate but it generates some to all of the coding you might have to do on your own.
Message 2 of 12
(9,172 Views)
Here is a link to some software on the micro-epsilon website. I didn't see any manuals that describe the communication commands. Maybe they are buried inside the .exe files.
 
0 Kudos
Message 3 of 12
(9,163 Views)
I am using a ME NCDT 1800 laser in a displacement appliction, and I must say, it is a very nice piece of hardware! The manual that comes with the unit (which I do not see on the download page of their web site) has detail of the communications protocol. It is basically straight 32 bit binary words. If I remember correctly, the serial data rate is a dismal 9600 Baud. I am curious why you wish to read the laser output through RS-232. The DB connector on the controller has an analog output on it that is MUCH faster than the serial output. I am using this with a standard NI DAQ card, and can use the full sampling rate of the ME unit. In my case, this is 5K samples/second. The only need that I can see for the serial connection is for set-up. You can change the averaging mode and some of the averaging parameters (within fairly tight limits), and you can command the laser sampling to start/stop. However, in my application, I am letting the laser run and sample continuously, and triggering the DAQ card for waveform synchronization. This seems to work very well for me. I am using the envelope limit comparator built into Labview to perform a Go-No-Go decision on my sample scans. If you are so inclined, I would be interested in hearing more about your experience with these lasers, as I have been setting this system up over the last few months, and have had quite a lot of fun producing the required mechanical conditions for proper sample presentation to the laser. Good luck Dave Green Manager, National Automation and Technologies, Inc.
0 Kudos
Message 4 of 12
(9,155 Views)
Thanks to everyone for their input. The reason we're interested in the digital vs. the analog data is because we're getting a fair amount of noise with the analog and we've been told that using the digital signal could reduce this. And since my programming skills are minimal at best, I was hoping that someone might've already written a .vi that would allow Labview to interpret the laser data and be willing to share it. In the absence of this, would anyone be able to offer any advice in terms of filtering the analog output to reduce noise? Thanks again for your help.
0 Kudos
Message 5 of 12
(9,140 Views)
Interesting that you should mention analog noise. We found that the brick switch power pack that came with our unit had a fairly dirty voltage output that was getting right through to, and superimposing itself onto the analog signal output. With the factory block, we had a baseline hash noise of approx. 15 mv P/P output. When we substituted with a GOOD power pack, the baseline hash disappeared into the digitization noise level. I am not saying that this is your problem, but it certainly is something to consider. BTW, did you check your manual for the serial info?? I am told that the serial option is just that; an optional board that must be factory installed. If you did not order your unit with the serial option, good luck. I was told that if I wanted the option on my unit, I would have to ship the unit to the factory in Germany!! Not a pleasant thought. Have a nice day, Dave
0 Kudos
Message 6 of 12
(9,132 Views)
Hi, Dave.  Thanks again for your input.  Just curious - what model power supply have you had success with?
0 Kudos
Message 7 of 12
(9,100 Views)

We used an Omron switching, DIN rail mounted power pack. I don't remember the exact part number, but it is the type used for industrial control loop power supplies, and is rated at about 2 amps DC. I was VERY surprised that the brick with the uE laser was so poor. As if the darn package didn't cost enough!

BTW, we have, and are still experiencing misc. base-line drifting in our unit. I find that after a fast step-change in analog output value, we have to wait upwards of 2 seconds for the baseline to return to normal. The only suggestion that our local tech rep had was to use the "Manual Zero" feature after each measurement. This seems to help, but what a nuisance. Also, on a sharp positive to less-positive output transition, we sometimes get a huge negative spike to full negative saturation, then back to the elevated baseline reading. Have you experienced any of this type of "crud" on your output.

If you wish to contact me directly, my e-mail is

 

ve3eoq@iaw.com

 

Good luck,

 

Dave Green

Project Manager, National Automation and Technologies, Inc.

 

0 Kudos
Message 8 of 12
(9,092 Views)

Very interesting -- I'm not sure whether our "crud" is the same as yours (I like the term, though), but we've definitely had some questionable readings. We experienced very problematic drifting (to full saturation) that simply went away when we attached the laser to a laptop vs. a computer (not to say this was the cause of the problem but since it worked, we didn't fuss any further with it). The other thing we've noticed is that if we remove the AC power supply from the laptop and run from the battery, our noise is REALLY reduced. We're still trying to arrive at a configuration that will work for us long-term, which is why I thought we'd ask you for a little more info about your power supply. I agree that for the cost of the laser, "plug and play" really would've seemed in order! Thanks again,

Michele

0 Kudos
Message 9 of 12
(9,087 Views)
Sounds like we may have problems in common. The fact that your signal cleans up when you use a laptop, tends to imply that you have a difference in circuit common (ground??) potentials between your desktop computer and your laser unit. We are using ours in diffrential output mode, with the shield of the laser output amplifyer connected to power-line earth ground, and also to the chassis gnd/analog input common on our DAQ card ( in the desktop pc ). I have not tried a laptop on ours, might be an idea, as I carry a laptop with me. I am going to try to attach a Microsoft Word document to this message. It contains some screen shots of our laser output (from data saved to Excel). The really interesting shot is the next to last picture. In this one, a conveyor belt lacing bump has passed under the laser beam, which is mounted at right angles vertically, so that it aims straight dowm on the conveyor surface. We expect the bump from the lacing, but not the loooooooong time required for the trace to return to base line value. The X-scale is 0 to 800 milliseconds. The lacing is only the highest point, and a very small area on either side of it. In our application, we need to make a minimum of 2 consecutive measurements in the time shown in the graph X scale. Needless to say, we can't. Our local service rep's only suggestion was to use the external contact closure to zero out the amplifyer after a measurement/before taking the next one. My concern with this (aside from the Mickey-Mouse-Factor), is that we will eventually get to the point that there is no adjustment left! Our rep is coming back to site tomorrow afternoon, so hopefully, he may have something intelligent to suggest. I will let you know if there is any positive news.
0 Kudos
Message 10 of 12
(9,075 Views)