yashsingh1/xdaforums huggingface dataset:
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
Thank you so much for the specifics. I will recreate this setup on stock and well, find my remote... haha. I am currently working on a problem in vmware with android, trying to get a thread up to develop a fix for it, but after that I will experiment with the upscaler on stock, get it working, then recreate on root.. Again, appreciate your Time~!

also

Ohhh you know I will plug it into my other one too when I try this again. Thanks Again! I am not sure if this one is actually 4k or not but I know my other one is
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] abc1054:
Here is the setting picture of Ai upscaling
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] abc1054:
Sorry that was to blurry
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
Seriously Thank You, haha. I feel like such a dumb dumb. I think it may be this tv and it never even occurred to me. I'll do some scientific like experiments later XD
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] abc1054:
Ok, good luck
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] louforgiveno:
I believe that Play and Services should have the DATA erased instead of the CACHE.

From a different thread

"Make sure you clear data on Play Store and Services then reboot. If you're not clearing data the old failure will still be there."
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] Zer0_rulz:
I tried clearing the data of play store, services and the framework in a clean installed 9.1.1 and this is still the results on smarttube and vlc player, both video is running on 720p on a 4k TV
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] louforgiveno:
This was after doing the safetynet/magisk process right? With a reboot?

Thanks for testing!

The 720p file......is it 30fps or 60fps?
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] Zer0_rulz:
yes, i re do all the methods including what u said about clearing the data, then tested it

the file is 720p @30fps
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] Zer0_rulz:
back when i bought this shield, when i was testing the AI upscale on a 4k TV, even a 480p video on smartube and a videofile on 480p, the AI upscaling works, the shield was on a 8.2.3,
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] louforgiveno:
Thank you!

Well back to the drawing board....

Looked around a bit...hoping to find an apk that provides ai upscaling.....hoping there's a flag that can be switched in .smali to ignore bootloader status......a long shot, but just want to check
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] louforgiveno:
Yup 480p gets upscaled...just nothing below 480p.

I've meant to root and test all this myself....but being my main media device it's been hard to find a good time. I'll be testing this on 8.2.3 when i get around to it
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] Zer0_rulz:
U mean something like these?
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] louforgiveno:
Yes, but unfortunately I'm not sure which apk it is in....was hoping it was standalone...but looked through list yesterday and didn't find anything pertaining to upscaling....so yeah its probably buried in one of those apps....gonna be a pain to track it down....ugh
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
Gosh it's really exciting to see everyone working together on this! I will join you guys however I can tomorrow if y'all don't figure something out before then. Thanks everyone!!!
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] Zer0_rulz:
I installed link2sd to get a better view, maybe one of these apk's that ai upscaling are bundled on it something like that
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] pinvok3:
Thanks for the tremendous work!

I do have the same issue (v8.2.3). I can enable AI upscaling, but it always reverts back to 'Enhanced' as the media is unsupported. If I play 4k media it correctly says that it doesn't need to upscale. 1080p is always unsupported. At least no unlocked bootloader error anymore. :)

This happens on Kodi, NextTube and Netflix. I remember vividly that the upscaling worked on Netflix and NextTube before the rooting. I've followed the guide completely, also reset Google Play Services and all that.

Could it be, because I have no Google Account linked, and they need one for fancy data collection?

Before the fix, even Enhanced wasn't available so I'm happy already. The progress being made is really great.

If I can help with something, I'll happily support. I'm a software engineer but never have worked on Android related stuff. So I need at least some pointers where to look. :)

/Edit: I have recently changed from TV to a projector. So I can't guarantee that it's not a display configuration issue. But it's a 4k/HDR10 projector. So it should act like a normal 4k TV.
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] abc1054:
Thanks for all your hard works🙂
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
1. I might have misread what Nooted said, and assumed they got the upscaler working when maybe they were only referring to the root on stock part and being able to run apps not normally allowed on root.

2. That being said I did a test today to try to determine if using magiskhide settings with safetynet could Actually Even fix our issue and according to what I tried it cannot.

Here's what I did: I enabled magiskhide on literally everything on the machine, reboot.

Go into settings and I signed out of my google account, force stopped every single app installed and system app, cleared all data of everything, disabled every app that would allow it, uninstalled every update for the apps that would allow, and rebooted. Tried with and without google login and same problem.

3. I have corrected the title of this thread until an upscaler method can be fully found.

4. How I plan to proceed tomorrow:

I want to go through and start uninstalling apks, partition by partition, to see what happens. What does it break? Can we even delete some of these apps without some sort of weird crypto back-end break, etc? Could it be possible to find the app containing the Upscaler by means of elimination? IE keep deleting things until the upscaler option disapears or goes grey all together? Going to start in /vendor... there's some interesting apks in there.

If we can find the apk maybe we can pull it and do things with it

edit --I just thought about it but I forgot to try to lock the bootloader after all that and try again. I will try tomorrow
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] abc1054:
Jenneh, your totally awesome. Hope you and your family have a great holiday.. thanks for all you do. 🙂😁
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] Zer0_rulz:
I think freezing an apk will work, link2sd or sd maid can do it
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] Zer0_rulz:
I want to try to freeze these apk's to find the ai upscaler, but my question is, is it fine to install twrp on 9.1.1?, so i could have a backup incase of bootloops
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
You can def run TWRP, now backing up may be a different story when you go to restore. I was never actually successful with a restore, always bootlooped. Then again I never tried stock and that was a year ago so who knows. If it works for you please let me know.

Just to rule it out, I tried relocking the bootloader today with all the steps applied and the shield did not like that. It refused to boot entirely so I am going to play magic eraser today and I look forward to your results playing Mr Freeze and we will see what happens! I always like it when something can be turned off instead of removed or at least have that option available, :0
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] pinvok3:
Maybe I can propose a different way?

You can configure the upscaling through the Android system settings, they are therefore also available with `adb shell settings list system`.

I guess these are the settings the upscaler uses.

nv_upscale_detail=3
nv_upscale_filter=auto

The 3 is AI Enhancement.

I would dump all system apks, decompile them and search for "nv_upscale" strings.

I wrote a little script that can dump all system apks. Requires nodejs.

Spoiler content hidden.

I guess we can extend this script and add JADX. Go through all decompiled apks and look out for the config strings.

This way we will find all apps that are using the configuration and can be sure we are not missing a few.

/edit:

Okay, I did just that. This string seems to be used by TvSettings very often. It seems to controlling a certain service/library and is also responsible for checking the upscaling status. "Unlocked bootloader" is displayed by that app. I would suggest to concentrate on that App for now, especially the HWCService/INVDisplay and Upscale related files.

A cold guess into the dark:

Magisk Hide currently doesn't hide behind that specific display service/module and only behind the apps. The module blocks the upscaling because it still sees the root, but the apps think everything is fine.

Or we lost some kind of DRM keys during the boot unlocking phase.

There seems to be communication between the hardware layer and the app. Primarily the interface vendor.nvidia.hardware.graphics.display@1.0::INvDisplay could be interesting. This is where the upscale fail reason gets pulled from and should be responsible for activating the upscaling. I hope that the boot unlock isn't somehow reversibly burned into the hardware.
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
@pinvok3 Gosh WOW just wow! Thank You for your Amazing Share!! I will absolutely follow your advice and I will get that app pulled now to poke around.

Are you rolling 8.2.3 or one of the 9's btw??

Lastly "Or we lost some kind of DRM keys during the boot unlocking phase." Is this something we can obtain with a serial UART or JTAG adapter? I just got mine in and am not afraid to break the shield open here in a few days if there's something that could be obtained and shared there. I am new to all this so I appreciate everyone sharing the things
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] pinvok3:
I'm using 8.2.3. The newer 9 versions seem kind of sluggish. But the script should work on 9 regardless.

Sorry I have no idea. I've never worked on Android before and I've spent like 30 minutes on this. :D

Jtag is usually lower level stuff and I'm pretty sure it's undocumented. If it exists even.

I just remember, that on a previous phone (Sony Xperia) the drm keys were wiped once you unlock the bootloader, resulting in worse Camera image quality.

Considering that the upscale works correctly after unroot/relocking, I guess this would only be a soft lock. But still could be registered in the hardware somewhere, where we have no access to. Maybe it's still patchable though.
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
Thank You for even taking the time!! Your thirty minutes taught me more than a whole year, so I hope you get paid well doing whatever you do at your day job xD You're a legend in my book

I got the apk pulled for anyone who might want to look at it.

TvSettings.apk

drive.google.com

This is the 8.2.3 version

Here's Jadx

Releases · skylot/jadx

Dex to Java decompiler. Contribute to skylot/jadx development by creating an account on GitHub.

github.com

Here's a beginner friendly video using jadx and android studio to decompile apks
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] louforgiveno:
Ok, so it appears confirmed that it's the Unlocked Bootloader that keeps ai upscaling from working.(Deepisp)...next see if i can "interfere" with the reporting of unlocked....

But first.....back to the world cup final!
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] pinvok3:
Okay, I'm grasping straws right now, but my shield just crashed after I have started a movie with Dolby Vision enabled. Can someone confirm if Dolby Vision is grayed out (unavailable) on rooted devices but available on nonrooted ones? After this fix I was able to enable Dolby Vision but my system just died with this log:

It seems like some encrypted communication fails which takes the whole system with it. It makes me more suspicious that the bootloader unlock removes/hides/blocks some DRM keys required for AI/Dolby Audio to work. If we could somehow hook into the bootloader unlocking phase to see what's happening ..
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
(I had to ask @pinvok3 how) but in audio settings under advanced settings is the option.

This is on stock with root.

CONFIRMED

Dolby Audio Processing is greyed out on the Dev rooted 8.2.3 image with no ability to toggle on

(excuse my potato phone)
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] pinvok3:
Perfect. that's good to know. Thanks!

So your fix seems to enable the option again, but causes a crash in the system upon enabling. I guess the part that decodes Dolby signals and upscales media is denying it's work for some reason or another.

I remember that (At least on my old Xperia) I could backup the DRM keys before unlocking the bootloader and then reapply it after the root by flasing the binary file to some subdevice. Maybe it can be solved the same, but my knowledge is really limited here.
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] louforgiveno:
I'm uploading a zip containing the decompiled TvSettings apk in case anyone else wants to look through the .smali files....there's a lot here...kinda like finding a needle in a haystack with my abilities.

I've found a few interesting entries but haven't done any testing yet, just gradually looking through smali files that mention DeepISP and Upscaling/Video to get an idea of where edits can possibly be made.

Here..

TvSettings_decompiled.zip

drive.google.com
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] :
Does the boot images work for Nvidia shield 2017 16gb model?
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
@topbilal I decided to get the 2017 versions downloading today. I will get them flash ready and added to this thread when complete. It will take a few hours but I'll leave a comment on that thread when it's done. I'll try to get some modded boot's up too for 2017 on this thread after I finish that --note i cannot test these so it will be up to the community to do so.
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
Patched bootmods have been added for the 2017 16gb version of the shield. If anyone with one of these devices has the time to test, stock recovery images have been added here for the 2017, dev images too.

Need someone awesome to install stock 9.0.0, do not upgrade yet, run the bootmod patch, install magisk, and then go into the shield settings > About > and locate the upgrade. Select Download Only, do not install it yet.

When it is done you should be able to adb shell ls /data/ota_package and get your package zip name to adb pull for us. If you are able to and need any further guidance pm me.

-----sidenote

i noticed in patching the boots, the 2017 images use AVB 1.0 instead of 2.0 like on the 2019 pro. I theorize that is why the 2017 does not have the additional dtb and vbmeta partitions.
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
I wanted to share something I discovered today that I didn't know about before and this deals with TWRP.

Today I rewrote a GUIDE going over how to install Lineage OS on the shield.

I noticed that TWRP when opened will then establish a root shell with the device named RECOVERY

Spoiler content hidden.

So I adb shell ls and noticed that the contents /are not/ the same as what we see in a regular adb shell or in root exploring apps.

Spoiler content hidden.

In fact, the view we are used to seeing is referred to as "system_root" as listed above. If you were to ls that, you would see your traditional filesystem layout.

So therefore I was not seeing the full picture before... There's files here I pulled that I hadn't read before, I have to sort between the leftover lineage garbage and what not but I will share the native file dump later.

This also makes me wonder if I was trying to flash the "roms" wrong for this device. Maybe a new approach would be to make a modified and preinstalled system_root that could be adb pushed.

Not sure just wanted to share

--edit have to select the MOUNT option in TWRP and then system + vendor to see the full picture, otherwise a lot of empty folders
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
Spoiler content hidden.

These entries seem useful for my adbd project, maybe it will be useful for the other projects going on

---side note

in the decompiled adbd binary, it is refering to a "log" that it is reading from to determine whether or not adb can be run as root. The init.rc script linked above talks about a logd.rc but it is not actually located in the root with the other files. Maybe it is hidden somewhere?

Spoiler content hidden.

Spoiler content hidden.
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jakegiorlando:
Thanks for all the hard work everyone!!
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] zzattack:
Applied this approach to my 2019. AI upscaling doesn't appear to get blocked, but I can't say I've ever consciously seen it in action. Can't really get it to state that its actively upscaling any content however.

Unfortunately, any mention of dolby vision is removed from the display settings. There's no grayed out options either. Must have to do with the bootloader unlock. Anyone know if this can be restored by some zygisk, unsf, shamiko or magiskhide combination?
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
@zzattack zygisk and magiskhide were tried without any luck, unfortunately. " unsf, shamiko " I hadn't heard of these so not sure on that, maybe you can check for us? There's some folks working in the background dissembling and attempting to modify certain binaries (myself included but paused to work on other projects to learn more so i can contribute more here) but no new news as of yet. Just know folks are still looking into it and hopefully more news will be released in the future.
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] zzattack:
UNSF is just universal safety net fix. Shamiko is similar but from Chinese origin and to me a little vague in how it works.

Just now I'm noticing the rooted shield does not wake from standby either. Remote remains off and the only way to get it out of sleep is a power cycle. That's kind of a deal-breaker. Anyone else experience this?
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] dib_:
Is there any troubleshooting guide? I think I flashed the bootmod.img fine but now ADB doesn't connect at the bootloader menu

adb: error: failed to get feature set: no devices/emulators found

And rebooting the Shield it says "Your devices software can't be checked for corruption. Please lock the bootloader." and hangs at the NVIDIA screen. Do I start all this over from scratch?
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
@dib_ adb needs the adbd binary modified, that is being worked on. The bootloader screen is normal. Because your bootloader is unlocked. If you are completely stuck there just flash the stock firmware back, and honestly I would suggest you stay on stock until the community makes more progress.

This is where the device is at. Magisk works, modules work, stock apps work. No upscaler, no adb root (adb itself works), no dolby vision, all being worked on.

We can always use more people able to help troubleshoot and work on things like the upscaler, adbd, etc, but this method isn't perfect. It just works better than the dev root images from nvidia minus the adb limitations

@zzattack the sleep trouble haven't heard of.
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] dib_:
I think I made progress, I installed a firmware from scratch because I don't think the patched one here was compatible with what I had on the machine, even though it said the same version.
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] Manzing:
Hi, thanks @jenneh for your tutorial. I just got a 2017 Shield TV and flashed 8.2.3 stock version, then successfully rooted it with your instructions.

I just cannot install safety net package in Magisk as I am unable to select the file, I can't understand why. Using remote or controller, no way to move selection in any folder... only an empty "recent files" screen is displayed.

Is there any other way to do it ? Don't really want to install TWRP for it.

I managed to dump the OTA file, it should be 9.1 version as displayed on ATV.

In my case it was located in /data/data/com.nvidia.ota/app_download/ (for 8.2.3 version)

With 9.1+ version, OTA package is located in /data/ota_package

Do you want the untouched boot.img ?

I can upload it somewhere if you like.
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
For me personally I always had to use a mouse to be able to select the correct downloads folder. It's inconvenient but it is the only way I know of. (Plug in mouse, go to the menu on the left and somewhere in there you click on Download folder and you can access and install your modules.. idk what it is with magisk going to a different dl folder?)

I would absolutely love a copy of the 9.1 I really appreciate your time! You are amazing :DDDD

PS Thank You for Providing us the Pathing for the OTA on the 2017 that is so helpful;
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] Manzing:
Thanks, I solved my issue with the following adb command :

adb shell pm uninstall -k --user 0 com.android.documentsui

It removed the android's stock file app and then Magisk asked for another file manager to load the file.

EDIT : I don't recommend to do this as it will cause some issue, please use a USB mouse as suggested by Jenneh.

With a decent file manager it is much better :)

I sent you a MP with a link for 9.1 boot.img.
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] dib_:
Nevermind, think I was looking for https://xdaforums.com/t/learning-ab...the-staging-blob.4516537/page-3#post-87784093

Sounds like there isn't any known way to update a Shield even if I have the .zip
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] jenneh:
Thanks to our friend @Manzing we now have patched bootmods for the 2017 version of the shield. They got us both the 9.1 and 9.1.1! Both images have been added to the thread. Again thank you Manzing for taking the time!
[Nvidia Shield TV & Shield TV Pro (2019) Guides, Ne] fonicmaxxim:
This seems quite interesting, but I wonder what one would actually do with root on the Shield TV. I know this allows for full access to everything, but what can I really do with that, i.e. what are the use cases?

I would mainly be interested in debloating the stock firmware (i.e. remove unneeded apps like Plex, Google Music, telemetry stuff, ...). Has anyone done that? Also, is there a way to improve the stock's performance and make it less laggy?