How to read continuously from rs232?

You can post your problem related to LabView Projects here. We will try our best to help you out.
Post Reply
Clayton
Posts:35
Joined:Mon Feb 20, 2017 10:34 am
How to read continuously from rs232?

Post by Clayton » Mon Feb 20, 2017 10:57 am

Hello,

I am new to LabVIEW and my questions would be obvious for some for you. So please help if you know the solution.

This is for my school project. For your information, we need to program an Altera DE2 board to control the traffic lights (something like that) and at the same time, the board transmits the states of the lights to a computer with LabVIEW installed via RS-232 cable.

The rest of the project was going well except for the LabVIEW part because as I said earlier, I am new to LabVIEW.

We are using the 'Basic Serial Write and Read.vi' provided in the NI examples folder. The problem is that we don't know how to modify the vi in order to receive continuously the data coming form the DE2 board. Each time, the vi stops to read after it received 24 bytes of data.

Thus, the first question is:
1.) How to read continuously from the RS-232 port? (We tried to use 'while loop' but with no success, maybe we were doing it the wrong way.) If you know the solution, please shed some light for us in a detailed manner.

Junaid_Shahid
Posts:110
Joined:Tue Feb 14, 2017 9:00 am

Re: How to read continuously from rs232?

Post by Junaid_Shahid » Mon Feb 20, 2017 11:00 am

Clayton wrote:
Mon Feb 20, 2017 10:57 am
Hello,

I am new to LabVIEW and my questions would be obvious for some for you. So please help if you know the solution.

This is for my school project. For your information, we need to program an Altera DE2 board to control the traffic lights (something like that) and at the same time, the board transmits the states of the lights to a computer with LabVIEW installed via RS-232 cable.

The rest of the project was going well except for the LabVIEW part because as I said earlier, I am new to LabVIEW.

We are using the 'Basic Serial Write and Read.vi' provided in the NI examples folder. The problem is that we don't know how to modify the vi in order to receive continuously the data coming form the DE2 board. Each time, the vi stops to read after it received 24 bytes of data.

Thus, the first question is:
1.) How to read continuously from the RS-232 port? (We tried to use 'while loop' but with no success, maybe we were doing it the wrong way.) If you know the solution, please shed some light for us in a detailed manner.
Answer of your question is as follows:

GET CONTINUOUS DATA FROM COM PORT IN LABVIEW

Post Reply