Extract the boot partition or other partitions
Edit This PageFiles/Tools Needed đ
- Platform Tools from Google (ADB and Fastboot)
- A Windows PC
For Surface Duo (1st Gen)
- TWRP image for Surface Duo (1st Gen): surfaceduo1-twrp.img
For Surface Duo 2
- TWRP image for Surface Duo 2: surfaceduo2-twrp.img
Getting your current boot slot (A/B)
Assuming your Surface Duo is currently booted into Androidâ˘ď¸, connect it to your PC with a USB cable and open a command prompt.
- First, we need to reboot into the Bootloader mode, to do so, run this command on your pc:
adb reboot bootloader
Your Surface Duo will reboot into the Bootloader mode.
Image of what you should see right now: Surface Duo in Bootloader mode
- In order to retrieve the current active slot, run this command on your PC:
fastboot getvar current-slot
A line with the text âcurrent-slot:â will appear. The value can be a or b.
Take note of your slot, we´ll assume it is b
- For the rest of this guide we´ll assume the current slot is
band we want to retrieve thebootpartition
Boot into TWRP
- We need to boot into TWRP, to do so, run the following command on your PC:
For Surface Duo (1st Gen):
- Plug your phone to your PC, open a command prompt and start by typing the following text, but do not press enter just yet
fastboot boot
- Go find the surfaceduo1-twrp.img file you downloaded earlier, right click it, click âCopy as pathâ
- Then go back to the Command Prompt window we started writing text in previously, and simply, right click on it with your mouse (or long press if youâre on a touch device), you should now see this:
- Now you can press enter
You will now boot to TWRP. Reminder that touch doesnât work on TWRP for now, so youâll have to work through your PC.
For Surface Duo 2:
- Plug your phone to your PC, open a command prompt and start by typing the following text, but do not press enter just yet
fastboot boot
- Go find the surfaceduo2-twrp.img file you downloaded earlier, right click it, click âCopy as pathâ
- Then go back to the Command Prompt window we started writing text in previously, and simply, right click on it with your mouse (or long press if youâre on a touch device), you should now see this:
- Now you can press enter
You will now boot to TWRP. Reminder that touch doesnât work on TWRP for now, so youâll have to work through your PC.
Your Surface Duo will boot into TWRP, touch will not work and the device will say it is locked. This is completely normal and expected.
Retrieve the location of our boot partition
- We need to open a shell to issue commands directly to the phone. To do so, run the following command on your PC:
adb shell "setenforce 0"
adb shell
You are now able to issue commands directly to your phone via your PC.
- Now, we need to find the location of our boot partition, as it is different for each device. To do so, run the following command on your PC:
ls /dev/block/platform/soc/
If youâre lucky, youâll get only one line of output:
Take note of all the lines that get output from this command. In my case, itâs only one and it is 1d84000.ufshc.
- Next we need to retrieve our mount point for our partition, to do so, run this command:
ls -al /dev/block/platform/soc/[the last line we took note of]/by-name/
In my case: ls -al /dev/block/platform/soc/1d84000.ufshc/by-name/
- This is going to output a lot of lines, with each partition name having its mount point. Look for the line that says
boot_[your slot]:
- Now letâs take note of its mount point, in my case:
/dev/block/sde26.
Letâs make an image of the partition:
dd if=/dev/block/[your mount point] of=/tmp/boot.img
In my case: dd if=/dev/block/sde26 of=/tmp/boot.img.
- Now letâs exit the shell and pull the boot.img from the device, to do so, run the following command on your PC:
exit
adb pull /tmp/boot.img
If you did everything correctly, you will now have your boot.img. Enjoy! đĽł
Š 2020-2024 The Duo WOA Authors
Snapdragon is a registered trademark of Qualcomm Incorporated. Microsoft, the Microsoft Corporate Logo, Windows, Surface, Surface Duo, Windows Hello, Continuum, Hyper-V, and DirectX are registered trademarks of Microsoft Corporation in the United States. Android is a registered trademark of Google LLC. Miracast is a registered trademark of the Wi-Fi Alliance. Other binaries may be copyright Qualcomm Incorporated and Microsoft Surface.
Limited emergency calling
Running Windows on your Surface Duo is not a replacement for a proper phone operating system and does not have emergency calling capabilities.
Hello from Seattle (US), France, Italy.