05-25-2009 01:34 AM
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.
05-25-2009 09:40 AM
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.
05-25-2009 08:43 PM
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 ?
05-25-2009 09:45 PM
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.