[Nokia X5 (Nokia 5.1 Plus) Guides, News, Discussion] BennoMP:
This thread will go over restoring the IMEI number if you cleared the NVRAM (or fully formatted your phone). The official tool to use is the SN Writer tool from Mediatek but as the P60 processor is not compatible with that, I had to search for alternative ways.

First the legal blerb:

IT IS ILLEGAL TO FLASH A DIFFERENT IMEI NUMBER THAN THE ONE IT CAME WITH (AS FOUND ON THE SIM TRAY OR BOX).

I AM NOT RESPONSIBLE FOR ANY DAMAGE OR LEGAL AFFAIRS CAUSED BY USING THIS GUIDE. IF YOU DO BLAME IT ON ME THEN I WILL LAUGH AT YOU!

Now the guide.

You will need:

- The phone

- A USB cable

- A Windows computer (I used Windows XP, I will get to that later.)

- The drivers linked below (no other drivers seem to work properly or at all.)

- MauiMETA (linked below.)

Part 1: driver installation

These are essential to get the phone to be recognized

- Remove the phone if it's plugged in.

- If using Windows Vista or newer, disable driver signature enforcing (look up online if you don't know how to). For Windows XP there is no such limitation, you can just click a "continue anyway" button.

- Download and extract the drivers (linked below).

- Run "Install Drivers.bat" and follow instructions.

- Reboot the computer to be sure.

Part 2: installing MauiMETA

You will need this tool to start the phone to META mode and write the IMEI numbers.

- Download the setup program.

- Install the software by following on-screen instructions.

Part 3: getting the phone to go into meta mode

- Turn off the phone completely.

- REMOVE THE SIM CARD JUST IN CASE!

- Open the MauiMETA program on your computer.

- Check if the device select is set to "Smartphone" and if the drop-down in the top left is set to "IMEI Download"

- Click "reconnect" and plug in the phone.

- Wait until the phone displays "=> Meta mode" and the application either says "connected" or displays an error box.

Don't be scared of the error box. Just close it. Another may pop up, close that too. If the MauiMETA program displays a few boxes that say something with 6771, it's been detected and the IMEI Download tool is about to open.

Part 4: downloading an IMEI number to the phone

I would again like to warn you that flashing the non-original IMEI is illegal!

If the tool asks if it should find the database itself, click yes. There is no database you can load yourself, so the built-in one will work fine.

- Find your IMEI number(s). They should start with "35".

- Put in the IMEI number to the tool. The middle box is where you start typing. The very last number will need to go in the small box to the right. If you have a dual SIM model, there will be a submenu called "SIM_2" which you can find at the top of the tool.

- Click the "Download to phone" button and it should flash the IMEI numbers.

- When everything is done, hold the power button of the phone for about 10 seconds until it boots into the OS.

If everything went right, you should have a working phone now. I still need to figure out how to restore WiFi and BlueTooth MAC addresses, but the random ones the OS give you should do fine. Also ignore the NVRAM Error 0x10 wifi network, it indicates both are gone. Also some UI bits and pieces might be wrong on the latest Android because for example the notch values were loaded into device-specific partitions.