Приведение примеров eeprom

This commit is contained in:
EgorShin committed 2024-10-14 17:33:58 +07:00
1 parent c9f5563111
commit 52adac2b59
10 files changed
+88 -32

No files matched your search

@@ -12,18 +12,11 @@
void setup() {
// initialize the LED pin as an output.
pinMode(13, OUTPUT);
pinMode(LED_BUILTIN, OUTPUT);
EEPROM.begin();
/***
Iterate through each byte of the EEPROM storage.
Larger AVR processors have larger EEPROM sizes, E.g:
- Arduino Duemilanove: 512 B EEPROM storage.
- Arduino Uno: 1 kB EEPROM storage.
- Arduino Mega: 4 kB EEPROM storage.
Rather than hard-coding the length, you should use the pre-provided length function.
This will make your code portable to all AVR processors.
***/
for (int i = 0 ; i < EEPROM.length() ; i++) {
@@ -31,7 +24,7 @@ void setup() {
}
// turn the LED on when we're done
digitalWrite(13, HIGH);
digitalWrite(LED_BUILTIN, HIGH);
}
void loop() {