Gustavo Ramirez / Mbed 2 deprecated lecturaAnalogaYPC

Dependencies:   TextLCD mbed

Fork of lecturaAnaloga by Gustavo Ramirez

main.cpp

Committer:
tony63
Date:
2013-09-03
Revision:
0:fd817c22d584
Child:
1:d4b9822b8df4

File content as of revision 0:fd817c22d584:

// ejemplo lectura analoga
// EJEMPLO CON UN LCD PARA EL MODULO FRDM-KL25Z PARA LECTURA ANALOGA

#include "mbed.h"
#include "TextLCD.h"
AnalogIn Vin(PTC2);
TextLCD lcd(PTE0, PTE1, PTE2, PTE3, PTE4, PTE5); // rs, e, d4-d7

int main( ){
    
    lcd.cls();
    wait(0.5);
    while(1){
    lcd.cls();
    lcd.printf("V(%f)", Vin.read());
    wait(0.5);
}
}