wifi_mqtt_hcsr04_lcd1602_i2c
Diff: main.cpp
- Revision:
- 1:e045394f109e
- Parent:
- 0:824096cc05af
diff -r 824096cc05af -r e045394f109e main.cpp --- a/main.cpp Fri May 19 18:21:24 2017 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,33 +0,0 @@ -#include "mbed.h" -#include <LiquidCrystal_I2C.h> - -// Set the LCD address to 0x27 for a 16 chars and 2 line display -LiquidCrystal_I2C lcd(0x4E, 16, 2); - - - -int main() -{ - - // initialize the LCD - lcd.begin(); - - // Turn on the blacklight and print a message. - lcd.backlight(); - lcd.print("Hello, world!"); - - while (1) { - /* - // Read temperature register - data_write[0] = LM75_REG_TEMP; - i2c.write(LM75_ADDR, data_write, 1, 1); // no stop - i2c.stop(); - wait(0.01); - i2c.read(LM75_ADDR, data_read, 2, 0); - i2c.stop(); -*/ - wait(0.01); - } - -} -