LabVIEW Interface for Arduino Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

chronic problem of arduino and labview

Solved!
Go to solution

Hi

i have folow many videos for how to connect the arduino with labview and I have LV 2013 and last version of arduino .

I tried to implement the blinking LED on pin 13 but I always got this error message

(Error 5002 occurred at Init.vi.  Unable to establish connection with Arduino.  Please ensure that you have selected the correct COM port and that you have flashed the Arduino with the correct firmware.

This error code is undefined. Undefined errors might occur for a number of reasons. For example, no one has provided a description for the code, or you might have wired a number that is not an error code to the error code input. )

my arduino uno card has a microcontroller with name (ATMEGA328P-PU) does that a real UONarduino or not.

I read many posts like mine which says to increas time out and so many soultions but still got this error

please advise if there is any solution to this issue

0 Kudos
Message 1 of 7
(6,985 Views)

You need to supply more information. Are you using LINX? If not, you should use the LINX libraries (https://www.labviewmakerhub.com/doku.php?id=libraries:linx:start). Have you wired a control to the COM port selection? Have you selected the appropriate COM for your Arduino?

0 Kudos
Message 2 of 7
(6,009 Views)

Because LiFA is no longer supported by National Instruments you should eliminate the problems you mention above by using LINX.

But if you prefer fix the problems you mention

First using the Arduino IDE find the example Arduiuno Blink sketch then compile, download and run the sketch

Have you installed LIFA using the VI package manager. 

LIFA will not work with the latest versions of the Arduino IDE.  You need to use version 1.0.5 of the Arduino software.

Using the Arduino IDE open  the LIFA_Base.ino sketch .  Next compile and download the LIFA_Base.ino sketch to your Arduino board. 

Next test the installation by running the Analog Read.VI that comes with LIFA  You can not run the Arduino Blink sketch after you installed LIFA. 

hrh212

Message 3 of 7
(6,009 Views)

dr. _messina , No I m not using the LINX , and i select the com from arduino which same as the com in windows.

hrh212, Im using version 1.0.5 and already installed the lifa base.ino and compli is done also.

please advise how to test installation by running the Analog Read.VI that comes with LIFA.

I tried to did the blinking test by labview



0 Kudos
Message 4 of 7
(6,009 Views)
Solution
Accepted by topic author Mustafasei

It sounds like you are not connecting LabVIEW to the Arduino. You will need some sort of COM port communication in LabVIEW. This is in addition to communication through the Arduino IDE.

As hrh212 indicated, LIFA is no longer supported. LINX is a much simpler way to use Arduinos with LabVIEW. With LINX, there is no need to use the Arduino IDE. All of the programming is performed in LabVIEW. I highly recommend switching to LINX if you want support.

0 Kudos
Message 5 of 7
(6,009 Views)

Dears

Thank you I have searched about the LINX on youtube and found the benefits for it and it works now

0 Kudos
Message 6 of 7
(6,009 Views)

To find the Analog Read.Vi in Labview 2013 proceed as follows.

In the main Menu select "Help".

Select "Find Examples".

On the left side of the screen select "Search".

In keywords box enter "Arduino",

In Double click  keywords" box double click on Arduino.

You will see a list of 17 examples.

At top of list double click on "Arduino Analog Read PIN.VI" to open it.

To get starter with LINX go to :

<ttps://www.labviewmakerhub.com/doku.php?id=libraries:linx:start>

hrh212

Message 7 of 7
(6,009 Views)