Applied engineering Team
/
VT4_novosel
V8_4
main.cpp@0:a5ad9b843e13, 2016-11-24 (annotated)
- Committer:
- jnovosel
- Date:
- Thu Nov 24 18:01:32 2016 +0000
- Revision:
- 0:a5ad9b843e13
VT4_V8_4
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
jnovosel | 0:a5ad9b843e13 | 1 | #include "mbed.h" |
jnovosel | 0:a5ad9b843e13 | 2 | #include "TextLCD.h" |
jnovosel | 0:a5ad9b843e13 | 3 | //TextLCD lcd(p19, p20, p21, p22, p23, p24); // rs, e, d0, d1, d2, d3 |
jnovosel | 0:a5ad9b843e13 | 4 | TextLCD lcd(p19, p20, p21, p22, p23, p24,TextLCD::LCD8x2); |
jnovosel | 0:a5ad9b843e13 | 5 | int x=0; |
jnovosel | 0:a5ad9b843e13 | 6 | int main() |
jnovosel | 0:a5ad9b843e13 | 7 | { |
jnovosel | 0:a5ad9b843e13 | 8 | lcd.printf("LCD Counter"); |
jnovosel | 0:a5ad9b843e13 | 9 | while (1) { |
jnovosel | 0:a5ad9b843e13 | 10 | lcd.locate(5,1); |
jnovosel | 0:a5ad9b843e13 | 11 | lcd.printf("%i",x); |
jnovosel | 0:a5ad9b843e13 | 12 | wait(1); |
jnovosel | 0:a5ad9b843e13 | 13 | x++; |
jnovosel | 0:a5ad9b843e13 | 14 | } |
jnovosel | 0:a5ad9b843e13 | 15 | } |