From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
03-05-2012 04:36 AM
I want to control a microcontroler with labview via USB
The Problem is " How can I connect / Identify / Communicate My device ?"
PS : I'm Beginner
03-05-2012 05:07 AM
See this example and also a bulk of threads available on this forum regarding SERIAL communication.
http://zone.ni.com/devzone/cda/epd/p/id/2669
03-05-2012 05:20 AM
Well, that’s a little long to explain in a post.
Which microcontroller do you want to use?
What are you suppose to control/acquire with the microcontroller?
Also, what languages do you speak? I may have two tutorials that explain the creation of an acquisition card from scratch but they are in Spanish.
I use them as a base to make my own USB card with 3 AI at 16bits, 4 DI/4DO, 1 AO at 8 bits, a PWM output and RS232/RS485 extension ports.
Nevertheless as I said before, that project requires some time as you need to build the hardware (which is quite error prone at the beginning), fight with the proper driver (and the compatibility issues since it is not signed by Microsoft), then create and debug your own communication protocol and etc...
So my recommendation is that you find a good tutorial online, set up the hardware and driver, and only when Windows detect your pic, we can talk about the labview program to communicate.
Sorry not to be of more help,
03-05-2012 05:52 AM
Hi
First of all I would have taken a look at this, this and this.
The communication is not so hard at all. You need to create a driver with the VISA Driver Wizard. Then you need to create your own commands that the microcontroller and your LabVIEW software recognize. These commands will be transfered with for example the basic serial read/write. We're doing this project at the company I work, and it was quite easy to get it to work. The only problem was that the C code developers and I could never agree on what the commands should be
03-05-2012 08:54 AM
If your microcontroller shows up as a serial device in the system (Virtual COM port) then DO NOT start programming USB unless you want
1) to waste your time
2) to go crazy
3) failure
If the device shows up as a com port (FTDI chip) then use serial programming (as the first reply mentions).
Shane.
03-06-2012 06:34 AM
I agree with Intaris, but I had one case where this did not work.
We bought a HAMEG HMP2030 porwer supply and installed the driver. It showed up as a virtual COM 3 port in MAX, but all communication with it failed. I had to create a VISA driver to be able to communicate with the device. I'm not quite sure what the problem with the serial communication was, but the VISA driver solved it.
05-07-2012 08:42 AM
Dear Even,
I have a problem with driver for Hameg HMP2030. maybe you wanna share the VISA driver that you created 😉
06-08-2012 10:08 AM
Hi Even,
we (at ASML) have a HAMEG HMP2030 too, the labVIEW driver downloaded from HAMEG site returns errors. Did you use this driver? And if it is possible can I use your solution as well?
best regards,
Miranda