We will be issuing out harsher penalties for users abusing the Razer Insider forum for zSilver. Please ensure you read the House Rules before posting.

[ROM] [Storage][Netflix] Adoptable Mi Rom by gabrielgagz v1.2

Discussion in 'Razer Forge TV' started by gabrielgag, Dec 9, 2016.

  1. gabrielgag

    gabrielgag Active Member

    [​IMG]

    I am not responsible for bricked devices or dead USB sticks. Please do some research if you have any concerns about features included in this ROM before flashing it! YOU are choosing to make these modifications. YOUR WARRANTY WILL BE VOID!

    DOWNLOADS: https://plus.google.com/102509526912041899879/posts/XM8kyxwcDrY

    CHANGELOG

    V1.2

    - Cortex is Back! A new spoof can make Cortex and Netflix co-exist in the rom
    - TestCtrlConnection (Recommendations or Discover row) completely removed
    - HdHomeRun View App (sound) fixed @chateau

    FEATURES

    - Adoptable Storage (via patched boot image)
    - Netflix (Android Tv) capable (via spoofed/faked build.prop) (you need sideload the apk)
    - Rooted with SuperSu
    - Busybox and init.d
    - Deodexed and Zipaligned
    - Cortex Store completely removed
    - Recomendations or Discover Row deleted (yeah!)

    INSTALL

    - Unlock bootloader
    - Flash my ported TWRP
    - Boot into recovery
    - Flash Adoptable_Mi_Rom_by_gabrielgagz_v1.2.zip
    - Reboot and Enjoy

    The user @g|itch wrote a perfect and detailed tutorial with all installation steps. Click here!

    You system will reboot 2 or 3 times maybe, dont worry, it's normal...

    FAQ

    Q: My System and my Tv says that my Forge is a Mi Box...is this ok?
    A: That's because your system is faked to cheat Netflix and get it working (Only v1.0)

    Q: I miss Cortex, how can i have it again?
    A: Flash cortex_restorer_by_gabrielgagz.zip but you will loose Netflix (Only v1.0)

    Q: I love Netflix, but i don't want external storage. Can you fix it?
    A: Download the Marshmallow system image from Razer web, extract and flash the boot.img via fastboot

    Q: I just want adoptable storage, not Netflix and loose Cortex...is that possible?
    A: Yes, flash adoptable_boot_image_by_gabrielgagz (Only v1.0)

    Q: I hate all your rom. How can i come back to stock?
    A: I hate you too. Download Marshmallow system image from Razer web and flash via fastboot


    DONATE

    If you like this work you can contribute via paypal, i spent several hours of my free time doing this!
     
    Last edited: Dec 23, 2016
  2. g|itch

    g|itch Member

    Installation Instructions

    I take absolutely no credit for Gabriel's awesome work. My contribution for the community is what I hope will be a truly comprehensive step-by-step installation guide, hopefully encouraging many of you to be comfortable enough to go ahead and try.

    For the record, I've done this only on Windows 10. Everything about it should theoretically work fine from Windows Vista to this point, but you will possibly need to point to the right drivers manually even after installing them through the SDK on pre-Windows 10 systems.

    IMPORTANT DISCLAIMER - I am in no way responsible for any damages that may be incurred following these instructions. Understand that while it's typically a very safe and worry-free process, there is always risk involved when altering firmware on any device. Please proceed with caution at your own discretion.

    Latest update:
    12-23-2016 (v1.2)

    Necessary hardware:
    • USB 2.0 male A to male A cable
    • USB mouse
    Step 1 - Set up your Forge and PC
    • Download and install Android Studio
      • Choose 'Standard' on first run after install to finish configuring
      • NOTE: 3rd party tools exist that install just ADB and the necessary drivers, but we'll be sticking with the official install instructions for our purposes, as these are the drivers I've tested and confirmed working.
    • Install the Google USB Driver
      • Follow the linked instructions to install using Android SDK manager, which can be accessed by launching Android Studio, selecting 'Configure' in the bottom right, then 'SDK Manager'
      • Note that the driver is located under the 'SDK Tools' tab
    • Create and configure the adb_usb.ini file:
      • In the same elevated command prompt, Copy/Paste or type the following lines exactly as shown, hitting enter after each entry
      • Code:
        mkdir %USERPROFILE%\.android\
        echo 0x1532 >> "%USERPROFILE%\.android\adb_usb.ini"
    • Enable Developer Mode and enable USB Debugging on your Forge
      • From the home screen, go to Settings -> About
      • Highlight and click 'Build' repeatedly until developer mode is unlocked
      • From the home screen, go to Settings -> Developer options -> Debugging and turn 'USB debugging' on.
    • Switch the USB port to Device Mode
      • From the home screen, go to Settings -> Razer Options -> Device Mode and set 'Device Mode' on.
      • Proceed to step 2!
      • Note: USB accessories will no longer respond at this point. It is normal and to be expected.
    Now that your computer is set up and the Forge is ready to receive, it's time to move to flashing!

    Step 2 - Get in the drivers seat
    • Connect the Forge and set up ADB
      • While still powered on and connected to your TV, connect your Forge to your PC through your USB 2.0 A to A cable
      • Windows 10 should detect and install the correct driver automatically if you installed the drivers through Android Studio
      • Open a new elevated command prompt (right click Start -> 'Command Prompt (Admin)') or use the existing one if you haven't closed it
      • type the following commands, hitting enter each line:
      • Code:
        cd c:\forge
        adb kill-server
        adb start-server
        adb devices
      • If all is well, ADB should return 1 connected device.
        • If no devices are found, verify Forge is in Developer Mode, and that Device Mode and USB Debugging are enabled, then verify there are no errors shown in Windows Device Manager (right click Start -> Device Manager).
        • If errors are present, follow the driver install instructions found in the Android Studio help pages (note: I can't offer driver support. Google is your friend for any answers you may need.)
    • Push the ROM to your Forge through ADB
      • If you followed earlier instructions, you have the ROM, the twrp image, and all the tools in the same folder.
      • Push the Adoptable_Mi_Rom_by_gabrielgagz_v1.2.zip file to your Forge
      • Code:
        adb push Adoptable_Mi_Rom_by_gabrielgagz_v1.2.zip /sdcard/
      • The file is now in your Forge storage so we can flash it in the final steps
    • Test fastboot and unlock the bootloader
      • Code:
        adb reboot bootloader
      • Your console should reboot to the Razer logo, and Windows should detect and install a second set of drivers for Fastboot to work
      • Code:
        fastboot devices
      • 1 attached device should be listed. If not, check your drivers, referring to the Android Studio help pages for driver assistance if any problems again.
      • Code:
        fastboot oem unlock
        fastboot reboot bootloader
      • Your bootloader is now unlocked and ready for the final steps
    Step 3 - Forging a better machine

    Congrats! If you made it this far, you're all good to go to finish off the last of the steps. I must warn you, from this point forward is where the real risk comes in, and once again, please proceed with caution. Most importantly, when working with firmware updates always make sure you have a reliable power source. I assume no responsibility for any damage that may arise from proceeding at your own discretion.
    • Flash TWRP and boot into it
      • Continuing as always in the same elevated command prompt:
      • Code:
        fastboot flash recovery unnoficial_twrp_3.0.2.0_pearlyn.img
      • This will flash the recovery image to your Forge.
      • Before proceeding with the next step, be ready to swap the USB cable on the Forge with a mouse after hitting enter, as soon as the Forge screen goes blank. This is necessary so TWRP detects it during boot.
      • Code:
        fastboot boot unnoficial_twrp_3.0.2.0_pearlyn.img
      • SWAP THE USB CONNECTION FOR A MOUSE RIGHT AWAY
    • Backup and Flash the new ROM
      • First thing in TWRP, go to settings, click on the brightness menu, and un-check 'Enable screen timeout'
      • Return to main menu
      • Backup if you're inclined to do so
      • Click 'Install'
      • Select 'Adoptable_Mi_Rom_by_gabrielgagz_v1.2.zip' uploaded in Step 2
      • Continue through the prompts and install the new ROM
      • Reboot
    That's it! Now all you need to do is go through the setup. Although I would strongly recommend performing a factory reset at this point to clear any potential data conflicts, for those that really don't want to lose previous saves and such, as long as you were on 6.0.1 before, you shouldn't run into too many problems.

    For the record, on a freshly reformatted install without any of the Google bloat added back in except Youtube and Play Music alongside Kodi and Netlfix, a fresh reboot will yield me 1150-1200MB's free RAM in Kodi compared to 600-700MB pre-custom rom.

    Again, huge thanks and all credit to Gabriel for putting his time towards building this. If my install guide helps you, please consider donating to him as a thank you!

    Changelog:
    12-10-16: v1.0 launch
    12-12-16: Changed final flashing steps thanks to @BoogalooShrimp's feedback
    12-23-16: v1.2 updates
     
    Last edited: Dec 23, 2016
  3. Huz

    Huz Active Member

    Wow really great job! This really is amazing and very useful. Thanks for the share. Cheers!
     
  4. Damac10

    Damac10 Member

    Woohoo

    Sent from my GT-I9190 using Tapatalk
     
  5. BoogalooShrimp

    BoogalooShrimp Active Member

    I really want to do this but my noob paranoia is kicking in again. Anyone with some quick tips on how to do this?

    Unlock bootloader? How to flash and then boot into recovery? I assume I'll need a usb drive to do this?

    Thanks a million gabriel!
     
  6. g|itch

    g|itch Member

    Success! I have it up and running, and so far it seems pretty solid! Since I don't have a working USB hub, I pushed the rom over ADB, installed TWRP and then booted into the TWRP image while quickly swapping the USB cable for a keyboard/mouse combo to install the ROM.

    Netflix: Works extremely well. Just like every other Android device I've ever used Netflix on, the video is slow to buffer up to full HD, and starts at a significantly bad quality as usual... but like I said, pretty standard for Android Netflix. Once it's running at full HD, I actually have to say it's one of the cleanest and clearest pictures I've ever seen from Netflix. I started monitoring my bandwidth to make sure it was in fact 1080p and wasn't suddenly streaming and downscaling 4k because it thinks it's a Mi. Looks fantastic.

    Bonus: Killing cortex seems to have given back somewhere from 150-200 MB of free RAM, allowing Kodi to run even better, and letting you set a higher video buffer.

    Issues:
    1) Cast to Netlfix isn't working, confirmed on several versions of the Ninja APK up to the latest. The device you're casting from will see it, and will get Netflix to launch if it's not already loaded, but then times out from there. Videos never start, and you get an eventual error on the device you're casting from. No big deal considering Netflix as a whole at least works. It's everything I wanted... Kodi and Netflix Ninja living in harmony on my Forge.

    2) Pressing the power button on the Serval controller brings up a crashed app report the first time you press it after booting. After that, the button just doesn't have any effect, so again, no big deal. This is to be expected since Cortex was removed, and it's default behavior is to launch Cortex.

    I still have a lot of playing around with it to do, but for now, sleep. Thanks Gabriel, great build!

    I suggest Googling a bit on each step to be sure of what you're doing, but most of the steps are rather generic and you'll be able to find the details. First step will be installing the Android SDK and ensuring you install the Google Drivers.

    To unlock the bootloader, follow the steps to lock it listed here, substituting "fastboot oem lock" with "fastboot oem unlock" instead.

    It can probably seem overwhelming and not detailed enough if you've never played around with custom roms before, but be patient. I'll try to find some time in the next few days to try supplementing Gabriel's info with some more guided and detailed step-by-step instructions.

    Edit: Done!
     
    Last edited: Dec 12, 2016
    Xen0sys and gabrielgag like this.
  7. Damac10

    Damac10 Member

    Just blue tooth fix left. I want to use my Madcatz Controller on this via blue tooth. Great work

    Sent from my GT-I9190 using Tapatalk
     
  8. BoogalooShrimp

    BoogalooShrimp Active Member

    Omg I'm so excited. I'll have to wait until Sunday so I have more time to learn the process and get this UPGRADE installed.
     
  9. gabrielgag

    gabrielgag Active Member

    Thanks man! This is the kind of feedback i was expecting...

    1) Yep i note that...i'll check the logs to see if i can do someting...but i dont think so...

    2) Probably i can do something to fix this. I have experience modifing android keylayouts, if a kl exists for the Serval, maybe i can point the power button to another function...

    EDIT: Yes, we have a serval keylayout...probably in the next version i'll try to fix the power button issue

    The weirdest thing is that the keylayouts for Madcatz exists in system but marked as "1bad"...probably in the next version, renaming the propers kl can fix the issue...i dont know...
     
    Last edited: Dec 9, 2016
    Xen0sys likes this.
  10. Xen0sys

    Xen0sys New Member

    Nice work. Puts Razer to shame for taking this long to deliver no Netlifx.

    Who knew all it took was gutting Cortex to get Netflix - a trade I'd make any day :stuck_out_tongue_winking_eye:
     
    gabrielgag likes this.
  11. xamindar

    xamindar New Member

    OMG you removed the advertisement row! This is seriously the best thing that has ever happened for my forge. Thank you man!
     
    Xen0sys and gabrielgag like this.
  12. g|itch

    g|itch Member

    EDIT: Since I had the first response, I edited that post to move the walkthrough up for better visibility. Click here.
     
    Last edited: Dec 12, 2016
    ncarneiro and gabrielgag like this.
  13. chateau

    chateau Member

    I posted the following over at Silicon Dust. Not sure if there is anything that can be done about the Silicon Dust HomeRun View app with no sound. There is no option under Settings, Sound to fix the problem. Not sure what is happening with the ForgeTV locking up while using it as a DVR for View app. You do have to format an external hard drive as Internal Storage for the DVR to work. Maybe that has something to do with it. Any help would be appreciated.

    @ gabrielgag - You are a genius. Your ROM appears to make it possible to use ForgeTV as the DVR on Silicon Dust's View app.

    Is there anything you can do in Settings, Sound such as the Mi Box has to redirect Sound Output to HDMI? This is what the Silicon Dust View app needs if I understand correctly. Originally the Nexus Player on Android 6 had an option there to change Surround Sound from Auto to Never, not sure if it still exists in Android 7.


    I posted the following at Silicon Dust Forum.

     
    Last edited by a moderator: Dec 12, 2016
    gabrielgag likes this.
  14. gabrielgag

    gabrielgag Active Member

    Thanks man for this kick ass tutorial! This is a great contribution. I'll put a link in the Op...

    I'll check when i have some time. But i think i can't do nothing about this issue. ...sorry
     
    g|itch likes this.
  15. chateau

    chateau Member

    Thanks. It works so well now with Kodi that it may not matter anyway. Hopefully someone over at Silicon Dust Forum can help out as well.

    Running your ROM on my ForgeTV right now with the Silicon Dust DVR running and have 5 channels recording while using Kodi to watch 1 channel and all is well. Hard to believe we would have ever been able to do this with a ForgeTV.

    Take a bow man, you deserve it.
     
    gabrielgag likes this.
  16. BoogalooShrimp

    BoogalooShrimp Active Member

    help if possible please. I obviously did something wrong somewhere... I cannot get the last command to work...

    "fastboot reboot recovery". this does nothing, except the command prompt provides acceptable list of commands right after.

    as far as I can tell, it did flash the recovery file successfully.
     
  17. gabrielgag

    gabrielgag Active Member

    Just do a "fastboot reboot". Once in system, enable adb and do "adb reboot recovery"
     
  18. BoogalooShrimp

    BoogalooShrimp Active Member

    hm.. no i'm getting a "no command' dead android guy with an exclamation mark... i'm gonna go back to the beginning of step 2 and try it all again... i feel like a moron. lol
     
  19. xamindar

    xamindar New Member

    Sounds like you haven't yet installed the custom recovery.
     
    Xen0sys likes this.
  20. BoogalooShrimp

    BoogalooShrimp Active Member

    i don't get it... i'm getting all the way up to the "flash recovery" step... command prompt shows:

    "target reported max download size of 536870912 bytes"
    sending recovery (15240 KB)
    etc etc etc.
    Okay
    Writing recovery
    Finished. total time 1.368 seconds.

    then I do "fastboot reboot" (recovery does not work)

    then I type "adb reboot recovery"

    I get the dead android... argh