Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
30 views

Labview and Arduino Communication

This document describes two labs that involve serial communication between LabVIEW and Arduino. The first practice consists of designing a program in LabVIEW to light an LED connected to the Arduino. The second practice receives data from an LDR sensor connected to Arduino through LabVIEW. Both practices correctly configure serial communication and successfully verify programming through LabVIEW graphical interfaces.
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
30 views

Labview and Arduino Communication

This document describes two labs that involve serial communication between LabVIEW and Arduino. The first practice consists of designing a program in LabVIEW to light an LED connected to the Arduino. The second practice receives data from an LDR sensor connected to Arduino through LabVIEW. Both practices correctly configure serial communication and successfully verify programming through LabVIEW graphical interfaces.
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 10

CARLOS CISNEROS HIGHER TECHNOLOGICAL

INSTITUTE
CAREER: INDUSTRIAL ELECTRONICS
HMI LABORATORY / WORKSHOP GUIDE
PRACTICE No 5.- SERIAL COMMUNICATION OF LABVIEW
SOFTWARE WITH ARDUINO
1. GENERAL DATA:
NAMES OF THE MEMBERS:
JUAN BUÑAY CHAFLA

EDISON DAVID SIMBAÑA SIMBAÑA

DATE OF REALIZATION: DATE OF DELIVERY:

2017/08/17 2017/08/31

2. GOALS):

2.1. GENERAL

MAKE THE LABVIEW ARDUINO CONNECTION THROUGH SERIAL


COMMUNICATION USING A CABLE FOR THE ISSUANCE AND RECEPTION
OF DATA.

2.2. SPECIFIC
 Configuring the machine, with the arduino toolkit for the labview interface, and
loading the LIFA _BASE Sketch on arduino for successful serial communication
 Design 2 programs, one that allows me to turn on an LED, and another
program that allows me to receive data from an LDR sensor, using the
labview software and the Arduino card.
 Make the control diagram in the labview software and implement it with
Arduino.
 Implement the circuits on the breadboard, to verify the success of the
practice.

3. EQUIPMENT AND MATERIALS:

EQUIPMENT

 Computer
 Arduino board

SOFTWARE

 labview
 IDEN Arduino

MATERIALS

 led
 LDR(photoresistor)
 2 Resistance (330 ohm)
 Breadboard
 doorbell wire

4. THEORETICAL FRAMEWORK:

COMMUNICATION OF LABVIEW SOFTWARE WITH THE ARDUINO CARD

"LabVIEW is an extensive development environment that provides scientists


and engineers with unprecedented hardware integration and broad
compatibility. LabVIEW inspires you to solve problems, accelerates your
productivity, and gives you the confidence to continually innovate to create and
deploy measurement and control systems."
As they tell us on the National Instruments website, LabVIEW is a development
environment aimed at scientists and engineers, which aims to help us program
graphically in a simple way. Additionally, you have built-in, engineering-specific
libraries of software functions and hardware interfaces and features for analysis,
visualization, and data sharing.
We use the tools provided to us to control our Arduino from the PC monitor with
a graphical interface that we are going to create.

LDR (photoresist, photoresistor)

The LDR (light


dependent resistor) is a resistor that varies its value depending on the amount
of light that illuminates it.
The values of a photoresistor when it is completely illuminated and when it is
completely dark varies. It can measure ohms to 1000 ohms (1K) in full
illumination and can be 50K (50,000 Ohms) to several mega ohms when in the
dark.
The LDR is manufactured with materials with a crystalline structure, and uses
their photoconductive properties. The most common crystals used are:
cadmium sulfide and cadmium selenide.
5. PROCEDURE
We proceed to download and configure the following necessary packages from
National Instruments.
 Install vipm – labview package manager 2015 through this manager the
vipm arduino toolkit is installed
 Download vipm arduino toolkit
 Verify the recognition of the usb port by the arduino ide, measurement &
automation explorer and the windows device manager,
CONNECTION PROCESS
So that labview can communicate with arduino, the lifa_base program will be
sent to the arduino memory. The program can be found in the folder:
”c:\program files (x86)\national instruments\labview 2015\vi.lib\labview interface
for arduino\firmware\lifa_base“, which by default is installed in the arduino toolkit
download process. After the program is transferred, it is in charge of
communicating with the Arduino.

5.1. PROPOSED EXERCISES

EXERCISE N° 1
Design a program that allows you to turn on an LED using the labview software
and the Arduino card.

Arduino connection diagram, for the proposed exercise

Programming process
with labview
In this case, we begin by initializing the communication through the COM13
port, we proceed to configure the control that represents our digital pin as
output and subsequently assign the value of its state (on/off) using a push
button.
Below is our connection diagram as an example:

We configure the baud rate with which labview and arduino will communicate,
as well as our output port.
Once the program has been designed and all the necessary configurations
have been made in labview, we proceed to connect our Arduino to the PC and
upload the LIFA BASE sketch, and check our programming.

The control of turning on and off an LED was successfully observed and verified
through serial communication of the labview interface with Arduino through a
cable for the transmission and reception of data.

EXERCISE N° 2
Design a program that allows me to receive data from an LDR sensor, using the
labview software and the Arduino card.

Arduino connection diagram for the proposed exercise.


LDR (Light Dependent Resistor) are, as their name indicates, resistors whose
value varies according to the level of light to which they are exposed.
As always, we will have to look at the LDR sensor datasheet to know how it
works.
What we will do on our arduino is connect one pin of the sensor to 5 volts, and
the other will output a resistor to GND and a wire to the AnalogIn #0 pin.

Programming process with labview


We proceed to make the program diagram, we start communication through the
COM port, we proceed to configure the analog pin as data input of the LDR light
sensor.

We configure the baud rate with which labview and arduino will communicate.
Once the program has been designed and all the necessary configurations
have been made in labview, we proceed to connect our Arduino to the PC and
upload the LIFA BASE sketch, and check our programming.

The success of our program was observed and verified since the LDR light
sensor sends the data of the light level it receives to the labview interface.

6. CONCLUSIONS AND RECOMMENDATIONS


CONCLUSIONS:
 In this class the knowledge acquired about labview communication with
the Arduino card was put into practice.
 We learned how to install and configure the necessary drivers for labview
to communicate with Arduino.
 This practice has been fundamentally technical since we learned to turn
on an LED, and receive data from an LDR light sensor, manipulating our
Arduino board from the labview interface.

RECOMMENDATIONS:
 Research the LIFA base library and which version to use since it is
essential for the communication of the Ardu card. not with labview.
 Configure the baud rate, COM port and outputs from the labview
interface before performing the simulation to avoid inconveniences.
 Observe that all connections are in accordance with the diagram to avoid
inconveniences when performing the physical simulation of the circuit.

7. LINKOGRAPHY:

http://www.naylampmechatronics.com/blog/23_TUTORIAL-ARDUINO-Y-
LABVIEW.html
https://geekytheory.com/arduino-y-labview
https://geekytheory.com/barra-leds-ldr-sensor-con-arduino
8. ANNEXES:

You might also like