app inventor bluetooth arduino

16
APP INVENTOR + BLUETOOTH Alberto Yúfera José Pujol IES Vicente Aleixandre, Sevilla

Upload: jose-pujol-perez

Post on 17-Jan-2017

4.214 views

Category:

Education


6 download

TRANSCRIPT

Page 1: App inventor bluetooth Arduino

APP INVENTOR+

BLUETOOTHAlberto Yúfera

José PujolIES Vicente Aleixandre, Sevilla

Page 2: App inventor bluetooth Arduino

Sumario

● Qué es App Inventor

● Finalidad de la app

● Hardware

● Software : Interfaz app + programación+ código Arduino

● Descarga e instalación

Page 3: App inventor bluetooth Arduino

App Inventor

● Entorno de desarrollo para aplicaciones móviles Android

● Entorno gráfico de programación , orientado a la educación

● Creado por el MIT en 2009

● Software libre

Page 4: App inventor bluetooth Arduino

Interfaz

Page 5: App inventor bluetooth Arduino

BLOQUES

Page 6: App inventor bluetooth Arduino

Finalidad app

Controlar Arduino desde el teléfono móvil mediante bluetooth.

Encender y apagar un led mediante un pulsador en la pantalla del

teléfono

Page 7: App inventor bluetooth Arduino

Hardware

APP

● Dispositivo android ● o Emulador android

ARDUINO

● Bluetooth HC06 , HC05● LED

Page 8: App inventor bluetooth Arduino

Hardware arduino-bluetooth

HC06 ARDUINO

GND GND

5V 5V

Tx(entr) Rx(sal)

Rx(sal) Tx(ent)

Page 9: App inventor bluetooth Arduino

Interfaz

Botón ON / OFF

Listpicker, almacena listas de palabras y al pulsarlo nos las muestra.Almacena los dispositivos bluetooth con los que podemos conectar

Page 10: App inventor bluetooth Arduino

Interfaz

● Dispositivo android ⇨ Maestro

● HC06 ⇨ Esclavo

Page 11: App inventor bluetooth Arduino

BLOQUES

BLUETOOTH- ListPicker

Page 12: App inventor bluetooth Arduino

BloQUES

Pulsador

Page 13: App inventor bluetooth Arduino

Código Arduino

int incomingByte; const int ledPin = 13;

void setup() { pinMode(ledPin, OUTPUT); Serial.begin(9600); }

void loop() { if (Serial.available()>0){

incomingByte=Serial.read();if (incomingByte == ’H’ ) {

digitalWrite(ledPin, HIGH);}if(incomingByte == ’L’ ){

digitalWrite(ledPin, LOW);}

}}

Ejemplos→ Comunicación→ PhysicalPixel

Page 14: App inventor bluetooth Arduino

Descarga e instalación app

Formato APK

Page 15: App inventor bluetooth Arduino

CONEXIÓN BLUETOOTH

BLUETOOTH- ListPicker

Page 16: App inventor bluetooth Arduino

Licencia

Presentación realizada por Alberto Yúfera Daza 1ºBachillerato IES Vicente Aleixandre

Revisada por José Pujol. Mayo de 2016

Este guía se distribuye bajo licencia Reconocimiento- CompartirIgual Creative commons 4.0