SP Flash Tool does not recognize the firmware scatter file


Question

I have a neffos X1 Lite and it seems that it boots only in the twrp recovery console.



Anyway I am trying to restore my official recovery console (i have no backup) using the official firmware http://www.neffos.com/en/support/download/X1-Lite



Inside this zipped file, there is a file scatter.txt that contains the following content.



preloader 0x0
pgpt 0x0
recovery 0x8000
para 0x1008000
expdb 0x1088000
frp 0x1a88000
ppl 0x1b88000
nvdata 0x1bc8000
metadata 0x3bc8000
protect1 0x5bc8000
protect2 0x63c8000
seccfg 0x7000000
proinfo 0x7040000
oemkeystore 0x7800000
md1img 0x8000000
md1dsp 0x9800000
md1arm7 0x9c00000
md3img 0x9f00000
nvram 0xa400000
lk 0xa900000
lk2 0xaa00000
boot 0xab00000
logo 0xbb00000
tee1 0xc300000
tee2 0xc800000
secro 0xcd00000
keystore 0xd300000
system 0xe000000
cache 0xeb800000
userdata 0x106800000
flashinfo 0xFFFF0080
sgpt 0xFFFF0000


Now, using SP_Flash_Tool-5.1916_Win to load this scatter file I get an error "Invalid format". So, how am I supposed to un-brick my phone? I still have access to ADB, Fastboot and no matter what I can not boot to OS.



enter image description here


Answer

The ROM you provided does not contain a valid scatter file or recovery.img so you can not use SP Flash Tool.



I recommend you to make a backup of boot, copy the boot.emmc.win to PC, then to another phone and patch it with Magisk Manager apk



After successful patching, copy the patched file back to PC



Reboot the phone to bootloader, and flash the magisk_patched.img from fastboot



fastboot flash boot "C:\adb\magisk_patched.img"


If for whatever reason you are not allowed to flash from fastboot, you can flash it from TWRP



When phone is working, just install Magisk Manager apk



Note: The /system partition and /data partition are encrypted, thats why you can not install Magisk.zip from TWRP



Patching the boot.img with Magisk Manager will remove the "verify" flag and patch against dm-verity, which will allow you to boot with modified recovery partition



Edit:



If you have a working similar phone, you can perform a "Read Back" of the recovery partition. based on your question, i have created a scatter file for the recovery partition



for the read back, select Region EMMC_USER and use the start address and size from this:



############################################################################################################
#
# General Setting
#
############################################################################################################
- general: MTK_PLATFORM_CFG
info:
- config_version: V1.1.2
platform: MT6755
project: TP904A
storage: EMMC
boot_channel: MSDC_0
block_size: 0x20000
############################################################################################################
#
# Layout Setting
#
############################################################################################################
- partition_index: SYS2
partition_name: recovery
file_name: recovery.img
is_download: true
type: NORMAL_ROM
linear_start_addr: 0x8000
physical_start_addr: 0x8000
partition_size: 0x1000000
region: EMMC_USER
storage: HW_STORAGE_EMMC
boundary_check: true
is_reserved: false
operation_type: UPDATE
is_upgradable: true
reserve: 0x00


Edit 2:



based on your output of /proc/partitions from twrp here is the complete scatter file (use carefully, no warranty it works)



MT6755_Android_scatter_TP904A.txt


Topics


2D Engines   3D Engines   9-Patch   Action Bars   Activities   ADB   Advertisements   Analytics   Animations   ANR   AOP   API   APK   APT   Architecture   Audio   Autocomplete   Background Processing   Backward Compatibility   Badges   Bar Codes   Benchmarking   Bitmaps   Bluetooth   Blur Effects   Bread Crumbs   BRMS   Browser Extensions   Build Systems   Bundles   Buttons   Caching   Camera   Canvas   Cards   Carousels   Changelog   Checkboxes   Cloud Storages   Color Analysis   Color Pickers   Colors   Comet/Push   Compass Sensors   Conferences   Content Providers   Continuous Integration   Crash Reports   Credit Cards   Credits   CSV   Curl/Flip   Data Binding   Data Generators   Data Structures   Database   Database Browsers   Date &   Debugging   Decompilers   Deep Links   Dependency Injections   Design   Design Patterns   Dex   Dialogs   Distributed Computing   Distribution Platforms   Download Managers   Drawables   Emoji   Emulators   EPUB   Equalizers &   Event Buses   Exception Handling   Face Recognition   Feedback &   File System   File/Directory   Fingerprint   Floating Action   Fonts   Forms   Fragments   FRP   FSM   Functional Programming   Gamepads   Games   Geocaching   Gestures   GIF   Glow Pad   Gradle Plugins   Graphics   Grid Views   Highlighting   HTML   HTTP Mocking   Icons   IDE   IDE Plugins   Image Croppers   Image Loaders   Image Pickers   Image Processing   Image Views   Instrumentation   Intents   Job Schedulers   JSON   Keyboard   Kotlin   Layouts   Library Demos   List View   List Views   Localization   Location   Lock Patterns   Logcat   Logging   Mails   Maps   Markdown   Mathematics   Maven Plugins   MBaaS   Media   Menus   Messaging   MIME   Mobile Web   Native Image   Navigation   NDK   Networking   NFC   NoSQL   Number Pickers   OAuth   Object Mocking   OCR Engines   OpenGL   ORM   Other Pickers   Parallax List   Parcelables   Particle Systems   Password Inputs   PDF   Permissions   Physics Engines   Platforms   Plugin Frameworks   Preferences   Progress Indicators   ProGuard   Properties   Protocol Buffer   Pull To   Purchases   Push/Pull   QR Codes   Quick Return   Radio Buttons   Range Bars   Ratings   Recycler Views   Resources   REST   Ripple Effects   RSS   Screenshots   Scripting   Scroll Views   SDK   Search Inputs   Security   Sensors   Services   Showcase Views   Signatures   Sliding Panels   Snackbars   SOAP   Social Networks   Spannable   Spinners   Splash Screens   SSH   Static Analysis   Status Bars   Styling   SVG   System   Tags   Task Managers   TDD &   Template Engines   Testing   Testing Tools   Text Formatting   Text Views   Text Watchers   Text-to   Toasts   Toolkits For   Tools   Tooltips   Trainings   TV   Twitter   Updaters   USB   User Stories   Utils   Validation   Video   View Adapters   View Pagers   Views   Watch Face   Wearable Data   Wearables   Weather   Web Tools   Web Views   WebRTC   WebSockets   Wheel Widgets   Wi-Fi   Widgets   Windows   Wizards   XML   XMPP   YAML   ZIP Codes