Proyecto Nivel, Edgar Ochoa, Erik Garcia

Dependencies:   MMA8451Q mbed

Committer:
verden32
Date:
Fri Feb 12 14:49:59 2016 +0000
Revision:
28:a34c81f0b387
Parent:
27:85d44b207258
Child:
29:13938c8e3765
final parte 4

Who changed what in which revision?

UserRevisionLine numberNew contents of line
verden32 15:9bd3eb94c3d8 1 #ifndef OCHOA
verden32 15:9bd3eb94c3d8 2 #define OCHOA
verden32 23:c5ef5e0f3809 3 #include "mbed.h"
verden32 23:c5ef5e0f3809 4 void Mensajes(){
verden32 28:a34c81f0b387 5 if(150<data[1] && data[1]>440){
verden32 23:c5ef5e0f3809 6 pc.printf("Nivel estable");}
verden32 27:85d44b207258 7 wait(.4);
verden32 28:a34c81f0b387 8 if(0<=data[1] && data[1]>=-16000){
verden32 28:a34c81f0b387 9 pc.printf("Nivel a la derecha");}
verden32 27:85d44b207258 10 wait(.4);
verden32 28:a34c81f0b387 11 if(0<=data[1] && data[1]>=16000){
verden32 28:a34c81f0b387 12 pc.printf("Nivel a la izquierda");}
verden32 28:a34c81f0b387 13 if(-36<=data[0] && data[0]>=16000){
verden32 28:a34c81f0b387 14 pc.printf("Nivel hacia adelante");}
verden32 27:85d44b207258 15 wait(.4);
verden32 28:a34c81f0b387 16 if(0<=data[0] && data[0]>=-16000){
verden32 28:a34c81f0b387 17 pc.printf("Nivel hacia atras");}
verden32 27:85d44b207258 18 wait(.4);
verden32 23:c5ef5e0f3809 19 //150-432
verden32 23:c5ef5e0f3809 20 }
verden32 14:867038a3f806 21 #endif