Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed Servo TextLCD
main.cpp
00001 #include "Cassaforte.h" 00002 //#include "mbed.h" 00003 //#include <TextLCD.h> 00004 //I2C i2c(D14, D15); 00005 //TextLCD_I2C lcd(&i2c, 0x4E, TextLCD_I2C::LCD16x2, TextLCD_I2C::HD44780); 00006 /*DigitalOut led(LED1); 00007 void scrivi(char parola[]); 00008 void cambioCodice(); 00009 void inserisci();*/ 00010 InterruptIn button(PC_13); 00011 00012 int main() { 00013 /*lcd.setMode(TextLCD_I2C::DispOn); 00014 lcd.setCursor(TextLCD_I2C::CurOn_BlkOn);*/ 00015 inizializza(); 00016 button.rise(&cambioCodice); 00017 while(1) { 00018 scrivi("Cassaforte"); 00019 wait(0.2); 00020 } 00021 } 00022 00023 /*void scrivi(char parola[]){ 00024 lcd.cls(); 00025 lcd.printf("%s\n", parola); 00026 } 00027 00028 void cambioCodice(){ 00029 scrivi("Cambio codice di apertura"); 00030 lcd.setAddress(11,1); 00031 wait(3); 00032 lcd.cls(); 00033 scrivi("Digitare il nuo_ vo codice:"); 00034 lcd.setAddress(10,1); 00035 inserisci(); 00036 } 00037 00038 void inserisci(){ 00039 wait(1); 00040 lcd.putc('1'); 00041 wait(1); 00042 lcd.setAddress(11,1); 00043 lcd.putc('2'); 00044 wait(1); 00045 lcd.setAddress(12,1); 00046 lcd.putc('3'); 00047 wait(1); 00048 lcd.setAddress(13,1); 00049 lcd.putc('4'); 00050 wait(1); 00051 }*/
Generated on Tue Jul 19 2022 08:17:03 by
1.7.2