44 static unsigned char eeprom[65536];
52 sprintf(name,
"eeprom.%d.%d", node_x(), node_y());
53 f = open(name, O_WRONLY | O_APPEND | O_CREAT, 0644);
54 lseek(f, addr, SEEK_SET);
58 printf(
"eeprom_write(addr 0x%02x, buf %p, size %d);\n", addr, buf, size);
60 memcpy(&eeprom[addr], buf, size);
66 memcpy(buf, &eeprom[addr], size);