LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

laser micormeter mitutoyo

Hi,

I don´t have experience doing driver for instruments. I am trying to build the driver of a Mitutoyo Laser micrometer using the serial port of the computer. The model of the laser micrometer is MITUTOYO LSM 500 S. The user´s manual is this:

http://www.mitutoyo.com/manuals/99mbc094a_lsm-500s_516s.pdf

And the display unit: 

http://www.mitutoyo.com/Manuals/99MBC095ALSM6200.pdf

 

I have attached the VI that I have done..it´s run without errors..but I cannot read data.

Thank you very much for your help!!

Best regards

 

0 Kudos
Message 1 of 30
(4,647 Views)

@dinovo wrote:

Hi,

I don´t have experience doing driver for instruments. I am trying to build the driver of a Mitutoyo Laser micrometer using the serial port of the computer. The model of the laser micrometer is MITUTOYO LSM 500 S. The user´s manual is this:

http://www.mitutoyo.com/manuals/99mbc094a_lsm-500s_516s.pdf

And the display unit: 

http://www.mitutoyo.com/Manuals/99MBC095ALSM6200.pdf

 

I have attached the VI that I have done..it´s run without errors..but I cannot read data.

Thank you very much for your help!!

Best regards

 




 

I do not know if this is like other Mitutoyo devices that we have done but we found that you only get data when the button on the Mitutoyo device was pushed. You could not get real time data from this device. We have not done anything new with them for a while so mabey the new stuff is different.

Tim
GHSP
0 Kudos
Message 2 of 30
(4,645 Views)

Hi,

 

One tactical note, there is no time between the VISA write and the check for Bytes at the port, a small delay might give the instrument time to respond.

 

You are luck to be able to just read the instrument and pass the reply directly to a conversion to 'double' numeric.

 

 

-------
Mark Ramsdale
-------
0 Kudos
Message 3 of 30
(4,640 Views)

Thanks for your answer,

the display unit has a key not a button..

 

0 Kudos
Message 4 of 30
(4,622 Views)

Thanks Mark, in this Vi I have a delay, but it also doen´t work 😞

Download All
0 Kudos
Message 5 of 30
(4,619 Views)

Hi,

 

For the timer to be effective you should place it after the write, but before the "bytes at port".  Use the error line to force the timer to run between those two steps.

 

Are you getting no reply or possibly garbage replies from the instrument?

 

Have you been able to get a reply from the instrument by using MAX directly?

-------
Mark Ramsdale
-------
0 Kudos
Message 6 of 30
(4,611 Views)

You don't say what command you are sending and your string control is not configured to send a termination character such as \r (Carriage Return) or \n Line Feed). You also have to configure the gauge to use the same termination character. Since the instrument is using a termination character, it is silly to use the Bytes At Serial Port.

 

You are not getting any errors because there is nothing that can possibly generate an error. You can have nothing connected to the serial port and a write error will not be generated and if there are 0 bytes in the buffer, you will not read anything or get an error trying to read 0 bytes.

 

p.s. Inverting the stop button is silly. Did you copy some of this from a very, very old version of LabVIEW?

0 Kudos
Message 7 of 30
(4,609 Views)

You don't say what command you are sending

I write \r at string write control in the panel control..

 

"and your string control is not configured to send a termination character such as \r (Carriage Return) or \n Line Feed)."

how can I do it?

 

You also have to configure the gauge to use the same termination character. Since the instrument is using a termination character, it is silly to use the Bytes At Serial Port.

 I don´t know how to do it,,,could you help me please

 

"Inverting the stop button is silly. Did you copy some of this from a very, very old version of LabVIEW?"

yes, i am using a driver a have found out in the web

 

Thanks!!!

0 Kudos
Message 8 of 30
(4,600 Views)

You right click on the control and select '\' Codes Display. If you had started with the basic example that comes with LabVIEW, it would have been done for you. Are you sure that just sending a carriage return is enough for the gauge to respond with a measurement?

 

You configure the instrument by following the instructions in the manual. Look in the section for configuring the serial port. You would have had to refer to that section in order to set the com parameters in your code.

0 Kudos
Message 9 of 30
(4,596 Views)

"You right click on the control and select '\' Codes Display"

If I do it in the VI appears:

\s\\

now what I should do?

 

"Are you sure that just sending a carriage return is enough for the gauge to respond with a measurement?"

I don´t know. The communication specifications in the instrument manual are:

9600

ascii

8

star bit 1 bit

stop bit 1bit

parity check none

delimiter CR+LF

 

I don´t know if all these specifications are in the VI. Some are in the visa serial vi, but for example, the delimiter no. 

 

"You configure the instrument by following the instructions in the manual. Look in the section for configuring the serial port.

You would have had to refer to that section in order to set the com parameters in your code."

i think i did it..

 

0 Kudos
Message 10 of 30
(4,588 Views)