|
最近在看TM4C1294的uip以太网例程...例程enet_uIP里面有着一段读本机MAC地址到数组有点疑问,,
红色部分,,,读user register0,1
我找了半天手册和程序,都没找到这user register和MAC地址有啥子关系啊,啥时候就存储了MAC地址了啊
//
// Read the MAC address from the user registers.
//
ROM_FlashUserGet(&ui32User0, &ui32User1);
//
// Convert the 24/24 split MAC address from NV ram into a 32/16 split MAC
// address needed to program the hardware registers, then program the MAC
// address into the Ethernet Controller registers.
//
sTempAddr.addr[0] = ((ui32User0 >> 0) & 0xff);
sTempAddr.addr[1] = ((ui32User0 >> 8) & 0xff);
sTempAddr.addr[2] = ((ui32User0 >> 16) & 0xff);
sTempAddr.addr[3] = ((ui32User1 >> 0) & 0xff);
sTempAddr.addr[4] = ((ui32User1 >> 8) & 0xff);
sTempAddr.addr[5] = ((ui32User1 >> 16) & 0xff);
|
|