yadaken yadaken / Mbed 2 deprecated TextLCD_HelloWorld

Dependencies:   mbed

Fork of TextLCD_HelloWorld by Simon Ford

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers main.cpp Source File

main.cpp

00001 // Hello World! for the TextLCD
00002 
00003 #include "mbed.h"
00004 #include "TextLCD.h"
00005 
00006 TextLCD lcd(p24, p25, p26, p27, p28, p29, p30); // rs, e, d4-d7
00007 
00008 int main() {
00009     int count = 0;
00010 
00011     lcd.printf("Hello World!\n");
00012     
00013     while(1) {
00014         lcd.locate(8,1);
00015         lcd.printf("%04d",count);
00016         count++;
00017         wait(1.0);
00018     }
00019 }