Skip to content

Commit

Permalink
Ajout chaine
Browse files Browse the repository at this point in the history
  • Loading branch information
PiFou86 committed Dec 18, 2023
1 parent 449b022 commit 15e011d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions random/EEPROM/include/SauvegardeDonneesEEPROM.h
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,11 @@ void SauvegardeDonneesEEPROM<TypeDonneesASauvegarder>::afficherContenuEEPROM() {
Serial.print(TEXT_BOLD);
Serial.print(TEXT_BG_BLACK);
Serial.print(TEXT_BLUE);
} else if (adresseAAfficher == ADRESSE_ADRESSE_DEBUT_DONNEES ||
adresseAAfficher == ADRESSE_ADRESSE_DEBUT_DONNEES + 1) {
Serial.print(TEXT_BOLD);
Serial.print(TEXT_BG_BLACK);
Serial.print(TEXT_YELLOW);
} else if (adresseAAfficher == adresseDonnees ||
adresseAAfficher == adresseDonnees + 1) {
Serial.print(TEXT_BOLD);
Expand Down
4 changes: 3 additions & 1 deletion random/EEPROM/src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
struct MaStructure {
int a;
int b;
char c[16];
};

void setup() {
Expand All @@ -15,7 +16,8 @@ void setup() {
MaStructure maStructure;
maStructure.a = 0x1234;
maStructure.b = 0x4321;
SauvegardeDonneesEEPROM<MaStructure> sauvegardeDonneesEEPROM(0x6666);
strcpy(maStructure.c, "Chocolatine !");
SauvegardeDonneesEEPROM<MaStructure> sauvegardeDonneesEEPROM(0x0666);
sauvegardeDonneesEEPROM.afficherContenuEEPROM();
//for (size_t i = 0; i < 1024; i++) {
for (size_t i = 0; i < 2; i++) {
Expand Down

0 comments on commit 15e011d

Please sign in to comment.