Olivier Smeesters
/
ExtTextLCDTest
Testbed for ExtTextLCD
Revision 0:0a32d52ad7db, committed 2011-02-05
- Comitter:
- osmeest
- Date:
- Sat Feb 05 23:19:52 2011 +0000
- Commit message:
Changed in this revision
diff -r 000000000000 -r 0a32d52ad7db ExtTextLCD.lib --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/ExtTextLCD.lib Sat Feb 05 23:19:52 2011 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/osmeest/code/ExtTextLCD/#2773889d6143
diff -r 000000000000 -r 0a32d52ad7db main.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Sat Feb 05 23:19:52 2011 +0000 @@ -0,0 +1,36 @@ +// Hello World! for the TextLCD + +#include "ext_text_lcd/TextLCD.h" +#include <sstream> +#include <iostream> +#include <iomanip> + +using namespace std; +using namespace ext_text_lcd; + +//TextLCD lcd(p28, p27, p26, p25, p24, p23, TextLCD::LCD20x2); // rs, e, d4-d7 +TextLCD lcd(p28, p27, Port2, 0, TextLCD::LCD20x2); // rs, e, d4-d7 + +int main() { + lcd.setDisplayControl(TextLCD::DisplayOn, TextLCD::CursorOn, TextLCD::BlinkingCursor); + + lcd.locate(0,0); + lcd.printf("(0,0)"); + lcd.locate(0,1); + lcd.printf("(0,1)"); + lcd.locate(14,0); + lcd.printf("(19,0)"); + lcd.locate(14,1); + lcd.printf("(19,1)"); + + while (1) { + lcd.locate(0,0); + wait(2); + lcd.locate(0,1); + wait(2); + lcd.locate(19,0); + wait(2); + lcd.locate(19,1); + wait(2); + } +}
diff -r 000000000000 -r 0a32d52ad7db mbed.bld --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Sat Feb 05 23:19:52 2011 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/9a9732ce53a1