Arduino

download Arduino

of 11

Transcript of Arduino

How do I Install the LabVIEW Interface for Arduino Toolkit Using VIPM?Primary Software:Primary Software Version:2009 SP1Primary Software Fixed Version:N/ASecondary Software:N/A

Problem:I want to use the LabVIEW Interface for Arduino. How do I Install the LabVIEW Interface for Arduino toolkit using VI Package Manager (VIPM)?

Solution:1. Make sure you have the most recent version of VI Package Manager (VIPM) installed on your system. You can download VIPM Community Edition for freehere.

2. LaunchVIPM.

3. Browse toLabVIEW Interface for Arduinoin the list of packages.

4. Click theInstall &Upgrade Packagesbutton.

5. ClickContinue.

6. ClickFinish.

The LabVIEW Interface for Arduino is now installed on your system. Once the toolkit is installed you can use VIPM to check for updates for it. When there is an update to the toolkit the icon in VIPM will change to look like the image below. Clicking theUpgrade Packagesbutton will update the toolkit to the latest version.

Related Links:NI Arduino CommunityArduino HomePage

How Do I Load the LabVIEW Interface for Arduino Firmware Onto My Arduino Uno?Primary Software:Primary Software Version:1.0Primary Software Fixed Version:N/ASecondary Software:N/A

Problem:I want to use the LabVIEW Interface for Arduino Uno. How do I load the Arduino firmware onto my Arduino Uno?

Solution:Connect the Arduino Uno to your PC as described inKB 5INA7UYG: How do I Connect an Arduino Uno to my PC?..

Install the LabVIEW Interface for Arduino toolkit as described inKB 5L38JQYG: How do I Install the LabVIEW Interface for Arduino Toolkit Using VIPM?. Open the Arduino IDE by browsing to the folder that you extracted in step 1 and double clickingarduino.exe

The Arduino IDE will open. Click FileOpen and browse to LVIFA_Base.pde found inC:\Program Files\National Instruments\LabVIEW 2010\vi.lib\LabVIEW Interface for Arduino\Firmware\LVIFA_Base Note:If the LVIFA_Base.pde is missing a copy can be downloaded fromhere. Choose the Arduino board type by clickingToolsBoardArduino Uno

Choose the COM port by clickingToolsSerial Portand choosing the COM port that corresponds to your Arduino Uno.

You can determine the COM port that corresponds to your Arduino Uno using the device manager by clickingStartControl PanelDevice Managerand expandingPorts(LTP & COM). Click theUploadbutton to upload the firmware to the Arduino Uno.

The Arduino IDE should reportDone Uploadingwhen the firmware has been successfully uploaded to the Arduino.

You are now ready to use the Arduino Uno with the LabVIEW Interface for Arduino Uno.

Related Links:Arduino HomepageDeveloper Zone Community: LabVIEW Interface for Arduino CommunityDeveloper Zone Community: LabVIEW Interface for Arduino Setup Procedure

Referencia del LenguajeVisita lareferencia extendidapara caractersticas ms avanzadas del Lenguaje Arduino y lapgina de libreraspara estudiar cmo conectar con distintos tipos de hardware.Los programas hechos con Arduino se dividen en tres partes principales:estructura,valores(variables y constantes), yfunciones. El Lenguaje de programacin Arduino se basa en C/C++.Estructura setup()(inicializacin) loop()(bucle)Estructuras de control if(comparador si-entonces) if...else(comparador si...sino) for(bucle con contador) switch case(comparador mltiple) while(bucle por comparacin booleana) do... while(bucle por comparacin booleana) break(salida de bloque de cdigo) continue(continuacin en bloque de cdigo) return(devuelve valor a programa)Sintaxis ;(punto y coma) {}(llaves) //(comentarios en una lnea) /* */(comentarios en mltiples lneas)Operadores Aritmticos = (asignacin) + (suma) - (resta) * (multiplicacin) / (divisin) % (resto)Operadores Comparativos ==(igual a) !=(distinto de) (mayor que) =(mayor o igual que)Operadores Booleanos &&(y) ||(o) !(negacin)Operadores de Composicin ++(incrementa) --(decrementa) +=(composicin suma) -=(composicin resta) *=(composicin multiplicacin) /=(composicin divisin)VariablesConstantes HIGH|LOW INPUT|OUTPUT true|false Constantes NumricasTipos de Datos boolean(booleano) char(carcter) byte int(entero) unsigned int(entero sin signo) long(entero 32b) unsigned long(entero 32b sin signo) float(en coma flotante) double(en coma flotante de 32b) string(cadena de caracteres) array(cadena) void(vaco)Conversin char() byte() int() long() float()FuncionesE/S Digitales pinMode() digitalWrite() digitalRead()E/S Analgicas analogRead() analogWrite() -PWM(modulacin por ancho de pulso)E/S Avanzadas tone() noTone() shiftOut() pulseIn()Tiempo millis() micros() delay() delayMicroseconds()Matemticas min()(mnimo) max()(mximo) abs()(valor absoluto) constrain()(limita) map()(cambia valor de rango) pow()(eleva a un nmero) sq()(eleva al cuadrado) sqrt()(raz cuadrada)Trigonometra sin()(seno) cos()(coseno) tan()(tangente)Nmeros Aleatorios randomSeed() random()Communicacin Serial

Echs algo en falta?Visita lareferencia extendidao lapgina de libreras. Tambin puedes visitar lapgina de cdigo propuesto por la comunidad.

Pgina principal ReferenciaCorrecciones, sugerencias, y nueva documentacin debern ser publicadas en elForo (castellano)o en elForo (ingls).El texto de la referencia de Arduino est publicado bajo la licenciaCreative Commons Reconocimiento-Compartir bajo la misma licencia 3.0. Los ejemplos de cdigo de la referencia estn liberados al dominio pblico.