• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!
  • Fill out your device list and let everyone know which phones you have!    Edit Your Device Inventory

Can I flash an .img pulled from the device?

Search This thread

swangjang

Senior Member
Sep 12, 2018
136
90
Google Pixel 5
I have a Google Pixel 5.
Pixel stock roms don't have a modem.img in the rom.zip.
Instead, there's a radio.img that can't be mounted to see file contents.

I managed to pull the modem.img from by device by doing:
1. #ls -la /dev/block/bootdevice/by-name
to find which partition the modem.img is flashed in

2. #dd if=dev/block/(modem_a#) of=/sdcard/modem_a.img
#dd if=dev/block/(modem_b#) of=/sdcard/modem_b.img
to extract the modem images which can now be mounted and edited.

After editing the mbn files inside, is it safe to just "fastboot flash modem" the device?