132

Dependencies:   mbed OneWire TextLCD

Revision:
3:20874daf248d
Parent:
2:ad0b044d0a10
--- a/main.cpp	Sat Dec 04 11:31:07 2010 +0000
+++ b/main.cpp	Mon Jul 01 15:23:14 2019 +0000
@@ -1,10 +1,38 @@
-// Hello World! for the TextLCD
+#include "mbed.h"
+#include <OneWire.h> 
+#include <TextLCD.h>
 
-#include "mbed.h"
-#include "TextLCD.h"
+/*  (Для NUCLEO-F401RE
+    1 > GND
+    2 > 5V
+    3 > n/c
+    4 > PA_13 (rs)
+    5 > GND
+    6 > PA_14 (e)
+    7-10 > n/c
+    11 > PC_13
+    12 > PB_13
+    13 > PB_14
+    14 > PB_15 
+    15 > GND
+    16 > 5V    */
 
-TextLCD lcd(p15, p16, p17, p18, p19, p20); // rs, e, d4-d7
+TextLCD lcd(PA_13, PA_14, PC_13, PB_13, PB_14, PB_15, TextLCD::LCD20x2); // rs, e, d4-d7
+uint8_t count[] = {0x20, 0x20, 0x4F, 0xCF, 0xD3, 0x43, 0x54, 0xC8, 0x54, 0x45, 0x20, 0xC4, 0x45, 0x48, 0x42, 0xC3, 0xC8, 0x20, 0x20, 0x20} ;
+uint8_t count1[] = {0x80, 0x42, 0x48, 0x45, 0x43, 0x45, 0x48, 0x4F, 0x3A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0xC0, 0x8C, 0x20, 0x20, 0x35, 0x2E, 0x30, 0x30};
+
+
+int main() { 
 
-int main() {
-    lcd.printf("Hello World!\n");
-}
+//for (i++){
+    lcd.locate(0,1);
+   lcd.putc(count1[2]);
+   lcd.putc(count1[3]);
+   lcd.putc(count1[4]);
+    //count+=1;
+    //wait(0.1);
+    //if(i==19) {i=0;} }
+    //lcd.printf("%02X", count1[7]);
+} 
+
+