[Fire TV Android Development] TechVendetta:
This thread is for development updates, and an eventual release of testing candidates for the future of dual booting CM12 android roms on the Amazon Fire TV. At this time I am not planing on supporting the Fire TV stick since my development platform is based off USB3 booting.

There currently isn't even a stable branch in CM12 upstream so things are quite tricky right now.

I may eventually setup public nightlies once the core is stable.

IN PROGRESS FORM HERE: https://t.co/TXp9z7htDx

The goals for development are in this order:

Wifi [working]

Bluetooth [crashing]

Stable core [random resets possibly storage related]

Audio [possibly needs hacking to default to hdmi]

Recovery system [rom boots using the recovery partition currently]

Hardware Acceleration [untested]

Android TV addons [require stable core]

USB Formating and install app [apparently not everyone knows what gparted is]

Modified version of Rbox's bootloader [I'd like to add recovery to the loader then have stock and custom boot options]

Also, if you want to be ready for possible nightly testing, I highly recommend going to walmart and buying one of the playstation USB3 hubs. It's about $20 but allows you to plug in a USB3 drive and keyboard and mouse until bluetooth is working.

SETTING UP USB BOOTING:

#include <std_disclaimer.h>
/* * Your warranty is now void. *
* I am not responsible for bricked devices, dead USB drives,
* thermonuclear war, or you getting fired because the alarm app failed. Please
* do some research if you have any concerns about features included in these files
* before flashing them! YOU are choosing to make these modifications, and if
* you point the finger at me for messing up your device, I will laugh at you. */

PART ONE [Preparing the drive]:

This process will eventually be streamlined but for now I'll explain the process and how it relates to testing builds during development. Since the Fire TV only has an 8gb flash chip and has no hardware recovery trigger, it is quite the unforgiving device to develop on. The current boot method for my CM12 builds involves flashing over the recovery partition and using it as a sort of dualboot partition. The modified recovery partition then searches for ext4 partitions on and external (USB3 preferred) flash drive. Currently each build generates its own boot image to be flashed over recovery, but I'm currently in the process of exploring the possibility of following Rbox's method of loading a boot image from a system folder instead making only one flash to the actual device necessary going forward.

For USB3 booting during the development process I highly recommend using a USB3 hub for a keyboard and mouse while bluetooth pairing and control mapping is being worked on. I also recommend a USB3 drive.

1) Turn on a Linux machine or boot a Live CD

2) Open Gparted

3) Delete any partitions on the usb drive

4) Create three ext4 partitions, the first partion is system and should be about 1GB, the THIRD partition is cache, and should be about 768mb with 0mb following, you should then have the middle portion empty in the display, in this SECOND partition make your data partition fill the rest of the space.

PART TWO [Preparing the bootloader]:

WARNING this process currently involves replacing your recovery partition, remember kids dd and root is like holding a grenade, make sure you don't throw it at something you care about.

Also, if you are testing a build and it does not load using the previous bootloader, try flashing the latest one from the nightlies (and vise versa) as I am still in the process of stream lining the boot process as far as what should take place before system bring up on our device. If a different boot image loads the system with noticeably more stability let me know asap so I can track the causes of my current issues.

adb connect <STOCK FIRE TV IP>
adb push boot-<DATE>.img /sdcard
adb shell
cd /sdcard
su
dd if=boot-<DATE>.img of=/dev/block/platform/msm_sdcc.1/by-name/recovery

Next I recommend side loading this apk to make rebooting into USB boot easier.

The three most recent "boot" images have been added to the downloads section, remember these should be flashed to recovery. Although they would work in boot, that would disable Rbox's loader and prevent you from loading stock OS.

PART THREE [Playing with instability]:

Great so now you have a USB3 booting image flashed to your recovery partition and you have an empty flash drive. This is where the tinkering begins. In the download section you will find a .tar.gz archive with a somewhat booting system with the aforementioned issues. Inside this archive is a system.img file which you will use dd to flash to the first partition of the flash drive you formated. After the system image is flashed you can plug your flash drive into your hub and reboot into recovery. Things will be great, wifi will show up and if you're quick enough you can complete setup and make it to the launcher. (the issue I'm currently working on is an odd timed reset that may be kernel or storage related oddly if you make it to the launcher and don't touch anything, it takes longer to reset)

If you made it this far, welcome to development. You can help by "kanging" (replacing system apk's and files with other versions to find more stable matches, or remove apks until things don't die then report back to me) Also if you make it to this point go ahead and fill out the form I mentioned earlier. Eventually any hotfix builds I do between nightly builds will be accessible to those users to play with.

Overhauling the boot system next and working on the reset debugging.

XDA:DevDB Information

TechVendetta ROM Development, ROM for the Amazon Fire TV

Contributors

TechVendetta, rbox

Source Code: https://github.com/TechV/android_device_amazon_bueller

ROM OS Version: 5.0.x Lollipop

Based On: CyanogenMod

Version Information

Status: Testing

Created 2015-01-29

Last Updated 2015-01-29