Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <LiquidCrystal_I2C.h>
- #include <Wire.h>
- LiquidCrystal_I2C lcd(0x3F,2,1,0,4,5,6,7,3, POSITIVE);
- unsigned long Tempo;
- unsigned long Tempo2;
- void setup(){
- lcd.begin (16,2);
- }
- void loop(){
- if ((millis() - Tempo) > 3000){
- Troca();
- Tempo = millis();
- }
- if ((millis() - Tempo2) > 3000){
- Troca2();
- Tempo2 = millis();
- }
- }
- void Troca(){
- lcd.setBacklight (HIGH);
- lcd.setCursor (0,0);
- lcd.print ("Relogio");
- delay (3000);
- lcd.clear();
- }
- void Troca2(){
- lcd.setCursor (0,1);
- lcd.print ("DS18B20");
- delay (3000);
- lcd.clear();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement