[Lenovo P780] absolutechaos:
Before I begin, I'd like to thank everyone in this forum, you have been a great help with customizing and troubleshooting phones. I'm also going to apologize for the long wall of text. I wanted to be as detailed as I can while I tried doing this on my own. Any help is appreciated!

The problem and what I want to do:

- My old P780 starts throwing out errors about 2 minutes after booting up the phone, about various apps (Notification Center, Process System, google play services, etc.) has stopped or is not responding. Errors pop up at a rate of about 1-2 messages per second, making the phone unusable. Since this starts 2 minutes after boot, I am still able to navigate and change settings for a while.

- I want to restore the phone to a working state with stock ROM or if not asking too much, maybe better TWRP + Custom ROM + SuperSU.

Phone details:

Lenovo P780 8GB, ROW

OS: Android 4.4.2

Build: P780_ROW_8G_S228_150112

BB Chip	: MT6589

MS Board.	: P780_ROW

IMEI1	: [Hidden for safety and privacy reasons]

IMEI2	: [Hidden for safety and privacy reasons]

Modem Ver.	: P780. V24, 2015/0

Bar code	: [Hidden for safety and privacy reasons]

Build Time:	: Mon Jan 12 16:49

Kernel Ver.	: 3.4.67 (buildslave@nj-bs6)

MP PREEMPT Mon Jan 12 16:2

Android Ver.	: 4.4.2

SW Ver.	: ALPS.KK1.MP5.V1

Custom Build Verno. : P780_ROW_

Observations:

- Takes about 5-15 minutes to boot.

- Restoring to factory via settings does not work, it goes thru the motions, but on reboot its back to the home screen, my 4-digit PIN to unlock the device is still there along with the wallpaper, messages from 2015, etc. Only the internal clock appears to have reset to 1/1/2010.

- Setting changes do not appear to survive reboot, including enabling developer mode. They get put back to what ever the setting was.

- This makes enabling developer mode a pain, but is still possible.

- After enabling developer mode and USB Debugging, I can see the phone storage on windows, currently 2.68GB of 5.73GB free. Unable to create, paste, modify or delete files.

- I do not remember if this phone was made in 2014. Some info on phone suggest it is 2015. Not sure if this helps.

What I've tried:

- Successfully installed Windows_10_MTK_VCOM_USB_Preloader_Drivers my windows 10 x64 machine, and ADB

- I can get to developer settings and enable USB debugging, which lets me see the phone via 'adb devices' on an administrative command line on PC, also confirming that the phone drivers are correctly installed.

C:\Users\arnol\Desktop\P780RestorationSetup>adb devices
List of devices attached
OZ8PQKGMIRY5DMZS device

- I can browse from the command line using 'adb shell' but only as $ and not #. both su and sudo fail to run.

C:\Users\arnol\Desktop\P780RestorationSetup>adb shell
shell@P780_ROW:/ $ su
[-] Connection to ui timed out
shell@P780_ROW:/ $ sudo
/system/bin/sh: sudo: not found
127|shell@P780_ROW:/ $

- I tried rooting from command line but it fails

C:\Users\arnol\Desktop\P780RestorationSetup>adb root
adbd cannot run as root in production builds

- Run 'adb reboot-bootloader' reboots the phone into normal mode instead of fastboot.

- Run 'adb reboot recovery' reboots the phone into stock recovery.

- power on + volume up it says "Have been in factory mode..." and some chinese text and some memory test options and phone info. I've added the info to phone details above.

- Running adb while here shows unauthorized.

C:\Users\arnol\Desktop\P780RestorationSetup>adb devices
List of devices attached
? unauthorized

- Navigating to clear emmc will make it say formating /data, then reboots almost immediately afterwards. No noticable effect.

- power on + volume down it says "Have been in meta mode..." and some chinese text, and nothing else happens. It still shows as unauthorized in adb, and is not found in fastboot.

- Followed the steps in https://xdaforums.com/lenovo-p780/development/lenovo-p780-guide-t2658144 to flash STOCK ROM ROW119 8GB. SP Flash Tool seems to be working but after 15 minutes and 90% done, it gives this error: BROM ERROR: S_CHKSUM_ERROR(1041). Some more research I found said this could be a fatal error, whle others say they got around it by deleting the Checksum.ini file. I deleted the checksum file and re-ran SP Flash Tool. It got to 100% but still give error 1041. Note: I used SP Flash Tool V3.1304.0.sn119 for this step.

- Used SP Flash Tool V5.13.52.200 to format EMMC and run memory test. It now gives BROM ERROR: S_DA_MT_DEDICATED_PATTERN_ERROR (3094). Attempt to flash STOCK ROM ROW119 8GB, it also gives error (1041).

- I tried the steps listed here https://xdaforums.com/lenovo-p780/help/rooting-tutorial-kitkat-t2835605 to install TWRP. It gave "pmt changed for the rom it must be downloaded". Tried editing the scatter file as suggested, but same error. Also tried firmware upgrade button, still no go.

- I am out of ideas at this point. If there's anything I might have missed please let me know. I appreciate the help!

Background Info:

- I'm an IT guy who's very familiar with Windows, and starting to learn how to use Linux.

- Phone was rooted before with KingRoot.

- I remember trying to uninstall a system app, which may be partly or directly the cause of this

- I do not remember what system app it was (did it way back 2015).

- This was my first attempt to mess around with my phone, I was pretty noobish at the time.

- I have since been more careful and successfully flashed custom roms on 2 other phones, an Android One Sprout8 and a Xiaomi Mi5, both now happily running LineageOS 14.1.

- We can skip any steps involving backups. Nothing is needed from the phone (other than to get it working!).