LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Communication with Arduino via LIFA

Hello guys. I'm new to LabVIEW and I have an issue with that thing.

 

I have made a simple program which communicate with Arduino. The only feature is to switch on or switch off an LED diode using a button. Program works, but it works only one time. When I stop my program and turn it back on, there is no reaction. Pressing the switch in VI doesn't change the state of diode. Every time I have to disconnect my Arduino from the computer and connect it back to make it work again. Do you know how to solve that issue?

0 Kudos
Message 1 of 4
(2,804 Views)

LIFA has long since been deprecated and replaced with LINX

 

You can find LINX and get support for it on the LabVIEW Maker Hub

========================
=== Engineer Ambiguously ===
========================
Message 2 of 4
(2,725 Views)

Thank you 😉

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

@marek.matw wrote:

Program works, but it works only one time. When I stop my program and turn it back on, there is no reaction. 


When you say "stop my program" I truly hope you don't mean pressing the Stop button on the tool bar (next to the run continuous and pause).  This stop button is basically a task kill, and doesn't finish the clean up processes like closing references, and releasing hardware references.  I suspect this is your problem and you should avoid using this stop button at all costs.  It is a last resort.  The famous quote is, something like "Using the stop button is like crashing your car into a tree when you want to stop it, it might stop but the condition it is in afterwards will likely not be very good." or something.  Make a button on your UI that stops your program and runs clean up.  You can also use an event structure to capture the close window, and have that properly stop your code.

 

And if you have some time you should check out some free LabVIEW training.

 

 

NI Learning Center

NI Getting Started

-Hardware Basics

-MyRIO Project Essentials Guide (lots of good simple circuits with links to youtube demonstrations)

-LabVEW Basics

-DAQ Application Tutorials

-cRIO Developer's Guide 

Learn NI Training Resource Videos

6 Hour LabVIEW Introduction
Self Paced training for students
Self Paced training beginner to advanced, SSP Required

0 Kudos
Message 4 of 4
(2,694 Views)