LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

RS232 serial communication

I have just started with labview.
I have a RS232 device that give me a continues serial string.
My problem is that I'm not able to synchronize the data so that the first
character will be the first in the displayed string.
Is there anyone that have some suggestions??

Thanks Jostein
0 Kudos
Message 1 of 14
(3,512 Views)
Hi,

Looks to me you've got to split the string. The device probably puts a
special character before or after every value. Could you send the string the
device sends? This would help...

Regards,

Wiebe Walstra.



--
AIR technical Automation
www.air.nl
"Jostein Hageberg" wrote in message
news:DimK5.1503$Yy1.30640@news1.online.no...
I have just started with labview.
I have a RS232 device that give me a continues serial string.
My problem is that I'm not able to synchronize the data so that the first
character will be the first in the displayed string.
Is there anyone that have some suggestions??

Thanks Jostein
0 Kudos
Message 2 of 14
(3,518 Views)
Hallo, AIR,

Du meintest am 30.10.00 zum Thema Re: RS232 serial communication:

>> I have a RS232 device that give me a continues serial string.
>> My problem is that I'm not able to synchronize the data so that the
>> first character will be the first in the displayed string.> Looks to me you've got to split the string. The device probably

> puts a special character before or after every value. Could you
> send the string the device sends? This would help...

Sounds like a Metex-/Conrad-DMM.
The strings might be
...
3.46 V
3.47 V
....
and are send as

... 3.4
6 V 3.4
7 V 3.4
8 V ...

I would take the dimension letter as delimiter.


Viele Gruesse!
Helmut
0 Kudos
Message 3 of 14
(3,512 Views)
Hi

That's right. The message looks like the one you describe.

Jostein Hageberg


Helmut Hullen skrev i
meldingsnyheter:7oqXxE2sfjB@hhullen.btx.dtag.de...
> Hallo, AIR,
>
> Du meintest am 30.10.00 zum Thema Re: RS232 serial communication:
>
> >> I have a RS232 device that give me a continues serial string.
> >> My problem is that I'm not able to synchronize the data so that the
> >> first character will be the first in the displayed string.> Looks to
me you've got to split the string. The device probably
>
> > puts a special character before or after every value. Could you
> > send the string the device sends? This would help...
>
> Sounds like a Metex-/Conrad-DMM.
> The strings might be
> ...
> 3.46 V

> 3.47 V
> ....
> and are send as
>
> ... 3.4
> 6 V 3.4
> 7 V 3.4
> 8 V ...
>
> I would take the dimension letter as delimiter.
>
>
> Viele Gruesse!
> Helmut
>
0 Kudos
Message 4 of 14
(3,512 Views)
Hallo, Jostein,

Du meintest am 30.10.00 zum Thema SV: RS232 serial communication:

> The strings might be
>> ...
>> 3.46 V
>> 3.47 V
>> ....
>> and are send as
>>
>> ... 3.4
>> 6 V 3.4
>> 7 V 3.4
>> 8 V ...
>>
>> I would take the dimension letter as delimiter.

> That's right. The message looks like the one you describe.

LabView can split strings. Look at the string library.

Viele Gruesse!
Helmut
0 Kudos
Message 5 of 14
(3,512 Views)
Hai all,
 
I've some problem with RS 232 communication between LabView 8.0.1 and my sensor module which has a scan rate of 600 Hz.
Now the actual problem is that even after the physical connection between my PC and the sensor is disconnected, PC is showing the readings for another 2 minutes or so. It means the PC was not showing the up-to-date data, which makes no sense in this program.
 
I use baud rate of 9600, 8-N-1 configuration for the communication and niether i was able to see the whole data in a single screen. It was showing each data on individual running of the program,ie, first it will show the command itself, then for second time this will be removed and first data that has been send by sensor will comes and so on.
 
After showing the complete set of data it will start showing from the written command itself,ie, the procedure as same as above.
 
How can i rectify these problem?
How can i aquire current data from the sensor?
 
Please help me urgently
 
Thanking You All
Using LabVIEW 8.0, 8.0.1, 8.2
0 Kudos
Message 6 of 14
(3,067 Views)
Hai all,
 
I've some problem with RS232 communication between LabView 8.0.1 and my sensor module which has a scan rate of 600 Hz.
Now the actual problem is that even after the physical connection between my PC and the sensor is disconnected, PC is showing the readings for another 2 minutes or so. It means the PC was not showing the up-to-date data, which makes no sense in this program.
 
I use baud rate of 9600-8-N-1 configuration for the communication and niether i was able to see the whole data in a single screen. It was showing each data on individual running of the program,ie, first it will show the command itself, then for second time this will be removed and first data that has been send by sensor will comes and so on.
 
After showing the complete set of data it will start showing from the written command itself,ie, the procedure as same as above.
 
How can i rectify these problem?
How can i aquire current data from the sensor?
 
Please help me urgently
 
Thanking You All
Using LabVIEW 8.0, 8.0.1, 8.2
0 Kudos
Message 7 of 14
(3,064 Views)
Why did you change the text to bold and why did you hijack an old thread? It would have been better to start a new one.
 
In any case, there might be a couple of different reasons. You might have a problem with the termination character. With the VISA Configure Serial Port, is it set to true? If it is and the sensor is sending multiple strings and appending a CR or LF at the end of each string, your VISA Read will terminate as soon as the first termination character is seen, requiring you to do multiple reads. Or, you are not reading fast enough to keep up with the sensor. How are you specifying the number of bytes to read? Are you using the VISA Bytes at Serial Port?
 
You might want to attach the VI you've written and some more information on the serial specifications of the sensor.
Message 8 of 14
(3,061 Views)
i am new to this discussion forum. so please forgive me. i dont know how to start a new one
 
Sorry
Using LabVIEW 8.0, 8.0.1, 8.2
0 Kudos
Message 9 of 14
(3,056 Views)
Hai Dennis
 
Thanks for your help.
The problem with termination character is solved out.
But the major problem is sustaining.ie, the display of recieved datas even after the physical connection between guage and PC is kept open.
How can it be possible to display the data when no data provider is present unless PC is taking the datas from its own buffer i think.
Is there any remedy for this
Using LabVIEW 8.0, 8.0.1, 8.2
0 Kudos
Message 10 of 14
(3,052 Views)