To set a unique MAC address during run time, you need to add a special callback function that allows this change. Simply select your ETHERNET PORT module where you define the NetX IP Instance associated with the NetX or NetX Duo application. An example is shown in the below figure.
Then select the Callback in the properties tab as shown in the following figure.
In this example, the name of the function is entered as setMacAddress. An example definition of that function is given below and it uses the FMI unique_idGet function to generate an MCU unique MAC Address. This code would be placed in the .c file of the thread that owns the Netx IP instance.
// REA's Vendor MAC range: 00:30:55:xx:xx:xx