Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

need some help here please..

Hi, i'm currently using labview 8.5 for my final year project and i'm new to it.

I'm asked to do a connection between a microcontroller PIC18f4520 and labview by using a rs232 cable and to get data from the microcontroller to show on labview.

Do I use DAQ or VISA to get data from the microcontroller?

I've tried using some of the examples in labview but i still could not manage to get any data from the microcontroller using labview.

 

Is there anyone who can help me with it ? It would be best if there's an example for it.Thanks.

0 Kudos
Message 1 of 4
(3,311 Views)

You use VISA and there are a couple of serial examples.

 

I would recomend that before doing any LabVIEW programming, you use a program like Hyperterminal to verify you have the right com settings and correct type of serial cable. 

0 Kudos
Message 2 of 4
(3,303 Views)

I did use hyperterminal to try out and it worked. But when I use labview, it actually could not get any data from the microcontroller.

 

I used the example 'Basic serial write and read' and did a loopback by using the rs232 cable. But when I connect it to the microcontroller, I could not get any data. Is it possible that anyone could show me any example of the wiring using labview ? 

0 Kudos
Message 3 of 4
(3,290 Views)

The example you used should work no differently than using Hyperterminal. Do you need to first send a command in order to read something back? If so, did you send the correct termination character(s)? In the example, the \r\n are a carriage return and line feed. This is what Hyperterminal sends at the end of a command.

 

If you really want other examples, just do a search of the board for 'serial'. There have been thousands and thousands of posts on the subject.

0 Kudos
Message 4 of 4
(3,285 Views)