How to make MAC-addr. persistent on Cerberus?

Sometimes my Cerberus-boards are losing their MAC-addresses after deploying software to them. I changed the addresses by using MFDeploy, but sometimes it happens that the boards have the standard address “00-04-a3-00-00-00” after deployment.

Could I avoid this by setting the MAC by code like this?


byte[] macAddress = { 0x00, 0x04, 0xa3, 0x01, 0x02, 0x03 };
ni[0].PhysicalAddress = macAddress;

Or is there a good method to make it persistent by using an external tool?

Wouldn’t that just do the same thing like MFDeploy?

Because I don’t want to change the MAC every time I deploy my software to the cerberus. I just want the value to stay the same.
At the moment the cerberus loses the information sometimes unwanted.

No, in the current code, the MAC is never set. I only set it once by using MFDeploy. The cerberus remembers it most time but sometimes the MAC goes back to the standard value.

Now I’m searching for a possibility to make the cerberus remember it’s MAC forever. The code above was a suggestion by me to do this by code. But I’m wondering if there was another possibility than setting the MAC at every startup or deployment

I can’t really say how to replicate this. There’s no regularity.
My cerberus boards are clients in my tcp-network. I’ve got a master-app on my pc which sometimes can’t connect to one of the clients. This problem is always caused by a lost mac-address.