pp.415ff.
//#include <avr/io.h> #include <avr/eeprom.h> int main(){ eeprom_update_byte((uint8_t *)0, 9); // [0]番地に0d9を書き込む。 eeprom_update_word((uint16_t *)1, 0xabcd); // [1]~[2]番地に0xabcdを書き込む。 char str[] = "The work of telegraph offices, especially those using undersea cables, had not yet settled into a smooth routine."; eeprom_update_block(str, (char *)3, sizeof str); // [3]番地~に文字列(排列)を書き込む。 return 0; }