LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to continuously transmit data serially for a user specified time using LabVIEW????

Solved!
Go to solution

Hello everyone,

I need to send data continuously using serial communication to microcontroller for a user specified time...Any suggestions plzzzzz??????

0 Kudos
Message 1 of 8
(3,180 Views)

Put the transmission of data in a WHILE loop

Message 2 of 8
(3,171 Views)

How much code have you written do far?

 

Have you got anything working?  Your question is so broad that it is hard to suggest anything...

Did you try communicating with the microcontroller using a terminal emulator (ie: HyperTerm).?

 

Have you looked at the serial communication examples?

 

There are litterally 10000 posts of this forum with examples for using LabVIEW with the serial port.

And what do you mean by continuously send data to the microcontroller?  What time intervals is the data sent?  What size?  Termination? What data rate? etc?

 

You need to provide details...

Message 3 of 8
(3,166 Views)

I need to transmit characters a,b,c,d depending on what user selects an option in the front panel..The user will enter a time according to his wish...i need to send that character continuously for that fix time and after that it should stop sending that character...Any suggestions????

0 Kudos
Message 4 of 8
(3,146 Views)

Well, you need to open your VISA connection for one. Then you will need to add a loop. You will also need a Wait inside the loop to control the delay and timing. An alternative would be to use a timed loop.



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
Message 5 of 8
(3,143 Views)

HI Maati

 

Use the example VIs. Basic Serial Read Write.VI should help you.

 

Use a timed loop to set the period at which the read write should happen.

---------------- Be Good. Do Good. ---------------------
Message 6 of 8
(3,130 Views)

Or go to this link as it provides answers to many questions about serial communication:

http://forums.ni.com/t5/LabVIEW/How-do-I-read-and-use-or-display-data-from-the-serial-port/m-p/19388...

 

It's an old post, but still usefull.  Maybe I should take the time to write a nugget about it.

Message 7 of 8
(3,116 Views)
Solution
Accepted by topic author Maati

Here's one that I like and is easy to modify.  You can copy the snippet directly into your block diagram:

http://forums.ni.com/t5/LabVIEW/Reading-time-interval-of-serial-port/m-p/1529140#M568806

 

 

In case I didn't provide this link, it has some interesting stuff...

http://forums.ni.com/t5/LabVIEW/Change-Baud-Rate/m-p/276265#M146432

 

 

Message 8 of 8
(3,113 Views)