I have a device running on the field in which the only upgrade option is UART DFU. What should i do for upgrading to Gecko bootloader for device having legacy UART bootloader.
There is no supported way to upgrade to Gecko Bootloader without flashing the device, since the bootloader cannot overwrite itself.
If you have no other choice, you can create a bluetooth application that includes the Gecko Bootloader binary as data array, and copies it to the bootloader flash address using the flash driver (nvm_hal.c/.h), while interrupts are disabled. But do this at your own risk! If something goes wrong during upgrade, you can brick your device.
How do you actually flash the merged file onto the device?
Use Simplicity Commander (found in C:\SiliconLabs\SimplicityStudio\v4\developer\adapter_packs\commander).
It is able to flash .s37 files.
You can use either the command line ("commander flash filename.s37") or the GUI.
Find documentation here: https://www.silabs.com/documents/public/user-guides/ug162-simplicity-commander-reference-guide.pdf