Edgar Ochoa
/
ProyectoNivel
Proyecto Nivel, Edgar Ochoa, Erik Garcia
Diff: main.cpp
- Revision:
- 25:2d2f8736f147
- Parent:
- 22:de1ab79df237
diff -r c5ef5e0f3809 -r 2d2f8736f147 main.cpp --- a/main.cpp Fri Feb 12 14:19:58 2016 +0000 +++ b/main.cpp Fri Feb 12 14:38:24 2016 +0000 @@ -1,16 +1,20 @@ #include "adcBasic.h" -#include "mbed.h" -#include "MMA8451Q.h" -MMA8451Q acc(PTE25, PTE24); +float x,y,z; PwmOut r(LED_RED); PwmOut g(LED_GREEN); PwmOut b(LED_BLUE); Serial pc(USBTX,USBRX); -float x,y,z; +int16_t data[3]; +#include "Ochoa.h" +#include "versionerik.h" +#include "mbed.h" +#include "MMA8451Q.h" +MMA8451Q acc(PTE25, PTE24); -int16_t data[3]; + + int main() { pc.baud(9600); //velocidad serial// @@ -24,8 +28,8 @@ z = 1.0 - abs(data[0]/16500.0); y = 1.0 - abs(data[1]/16500.0); x = 1.0 - abs(data[2]/16500.0); - - + erik_nivel(); + Mensajes(); pc.printf("%d,%d,%d,\n",data[0],data[1],data[2]); wait(0.4);