Skip to content

Instantly share code, notes, and snippets.

@smching
Created March 30, 2016 13:46
Show Gist options
  • Select an option

  • Save smching/335521c9a6fcea3ac784e6186e22f4b8 to your computer and use it in GitHub Desktop.

Select an option

Save smching/335521c9a6fcea3ac784e6186e22f4b8 to your computer and use it in GitHub Desktop.
Arduino电子密码锁
void initializeEEPROM(){
strcpy(buf, "1234"); //set password to 1234
eeprom_write_string(USER_PASSWORD_EEPROM_ADDRESS, buf); //write password to EEPROM
strcpy(buf, "1234"); //set password to 1234
eeprom_write_string(ADMIN_PASSWORD_EEPROM_ADDRESS, buf); //write password to EEPROM
DEBUG_PRINTLN("Initialize completed");
lcd.clear();
lcd.print("Initialized.");
delay(1000);
playOKTone();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment