45unsigned char node_mac[8];
49node_id_z1_restore(
void)
51 unsigned char buf[12];
55 node_id = (buf[2] << 8) | buf[3];
56 memcpy(node_mac, &buf[4], 8);
63node_id_z1_burn(
unsigned short id)
65 unsigned char buf[12];
66 memset(buf, 0,
sizeof(buf));
71 xmem_erase(XMEM_ERASE_UNIT_SIZE, NODE_ID_XMEM_OFFSET);
int xmem_erase(long size, unsigned long addr)
Erase a sector in the flash memory.
int xmem_pwrite(const void *_buf, int size, unsigned long addr)
int xmem_pread(void *_p, int size, unsigned long addr)
Read a number of bytes from an offset in the external memory.
Node-id (simple 16-bit identifiers) handling.
Header file to the external flash memory (XMem) API.