yashsingh1/xdaforums huggingface dataset:
[Fire TV Original Android Development] Pro-me3us:
Yes, the last lot of 2nd gen Cubes manufactured come with PS7229 (2021).

Be sure that it's actually sealed (has the tear tab). I see things sold on Ebay as new even when they have been opened and used once or twice. If the seller has sold a number of Cubes and is listing them as new, it's probably legitimately new.

Example of tear tab (white arrows):

Amazon did ship these in clear bags like this, so that's a good sign it's really new as well. Some sellers also have 'best offer' options that you could probably haggle $10 off with.
[Fire TV Original Android Development] abdul1907:
Thank you, I will buy a brand new sealed box on ebay, I found it there. I wonder if a HDD can be connected to the Fire Cube 2nd generation and is its power sufficient to feed the HDD? I have used a stick before and even though I bought an OTG converter, it could not feed the HDD.
[Fire TV Original Android Development] Pro-me3us:
Maybe it would work, it depends how much power it needs. There's only one USB port on the Cube so I'd recommend a powered USB hub. Unless you plan to use a remote through CEC, you'll need a Bluetooth dongle (~$5) to pair the fire remote in CE, and so a second USB port. My response to a similar question.

I didn't have any problems accessing an HDD plugged into a powered hub, I haven't tried booting from one.
[Fire TV Original Android Development] abdul1907:
I understand, I will try it when I receive it. By the way, does the L1 certificate of the device remain when I install CoreLEC after unlocking the bootloader? Have you tried whether Netflix Prime Video etc. service providers broadcast 4K in the original Fire OS software?
[Fire TV Original Android Development] Pro-me3us:
Widevine L1 & Playeady certifications are unaffected by the unlock or CE. Netflix and Prime Video aren't either.
[Fire TV Original Android Development] abdul1907:
A new test video has been released for Fel devices. Can you try them on Fire Cube?

FEL TEST ST DL P7 CMV4.0 4000nits V3.mp4

drive.google.com

FEL TEST ST DL P7 CMV2.9 4000nits V3.mp4

drive.google.com

If it resolves the fel layer, text appears on the screen. I tried it on my shield and the TV's own player, only red appeared.
[Fire TV Original Android Development] Pro-me3us:
I haven't been keeping up with all the nightlies and DV changes. I just updated my test stick to CE-NG 20.5 nightly 0327, and FEL videos don't play as lossess on this build. I'm seeing the same being reported on the AM6/U22XJ thread. I'll need to wait for a fix in the next nightly to test these videos.
[Fire TV Original Android Development] Pro-me3us:
@abdul1907 updated to nightly NG 20.5 0329, FEL is working again, CMV2.9 works fine. I don't have a TV that supports CMV4.0 to test that. Since it's the same SOC and CE firmware as the AM6+/U22XJ is using, there isn't any reason it shouldn't work on the Cube too.

If you end up getting Cube I can share the nightly kernel.img with packed raven dtb if you need it.
[Fire TV Original Android Development] Fritzaa:
Quick question, is Alexa enabled when usb-booted?

Alexa voice control?

... Alexa PAUSE VIDEO?
[Fire TV Original Android Development] Toad King:
I got a Fire Cube and would like the 20.5 nightly kernel for FEL. Also I'm very new to all this but is there a reason we can't just use a standalone DTB file like the other devices CoreELEC supports?
[Fire TV Original Android Development] Pro-me3us:
No, Alexa needs FireOS for authentication and communication with Amazon. The mic isn't active at all in CE.

The 2nd gen Cube bootloader is compiled with an extra security option enabled that only allows it to load a dtb that is embedded in the boot/kernel image. This is more secure because the boot image is verified during boot, and manipulating the dtb within the boot.img would cause an authentication error. In short, Amazon is better at security than the average Chinese company 😄

The dtb.img can be inserted into the CE kernel.img fairly easily with mkbootimg/unmkbootimg. I'm just saving people those extra steps.

A note, if you are noticing that CE is freezing sometimes when booting on raven, this is caused by a problem with the new MT7668 bluetooth driver. If you aren't using the Cube's internal BT, I'd disable that driver for now.

Either run this command with SSH:

echo blacklist bt_mt7668 > /storage/.config/modprobe.d/blacklist.conf

or alternatively copy the attached blacklist.conf (unzip first) to configfiles/modprobe.d/ with Samba.
[Fire TV Original Android Development] Toad King:
Seems to work well here but one major issue: I can't seem to get it to wake up from standby when turning my TV off and on again. It just shows no HDMI signal until I manually power cycle it. Is there a specific CEC setting I'm missing?
[Fire TV Original Android Development] Pro-me3us:
The suspend state doesn't work with most g12a/b/sm1 devices without a bootloader modification.

These older Amlogic devices never truly go to sleep in Android when the TV is off. For the Cube that makes more sense since it's working as an Alexa device 24/7. But in CE you should be able to power off your TV without the TV trying to put the Cube in suspend.

CEC control options are in:

CoreELEC Settings / Input / Peripherals / CEC Adapter

Try changing 'When the TV is switched off' to 'ignore'

Also in case you hadn't already seen, when using the CE shutdown command, press the action button on the Cube to power it back on. No need to unplug/replug or rely on a smart plug.
[Fire TV Original Android Development] Toad King:
Huh, that's weird because I have an AM6B+ and it can wake up from suspend just fine when I switch to its HDMI input (but not on TV start). Kinda sucks having to leave it on all the time but it is what it is.
[Fire TV Original Android Development] Pro-me3us:
I remember seeing that the AM6 was able to use the CE power suspend fix up until Ugoos started encrypting their bootloaders. There are a few AM6 variants, I don't know which version that was. Since Ugoos released a dual boot CE/Android firmware for the AM6, I wouldn't be surprised if they applied their own bl301 bootloader fix.

So your AM6+ can go into suspend and wake on HDMI input switch but not on TV power on? That's odd, both situations seem like they would rely on CEC.

I tried playing around with suspend on the Cube. The Cube will wake on action button press (gpio input), but most of the hardware remains disabled. I was able to jimmy-rig USB power to come back on, but WiFi and uart were still off making it harder to debug. I'm not sure much can be done without modifying bl301, but that would brick a secure boot device.

While idle the Cube is using 2 watts, and 80% of it's volume is an aluminum heat sink. So it's not using much electricity, and should be staying cool if that's any consolation.
[Fire TV Original Android Development] Toad King:
Yeah. My TV (Bravia X93L) is new and I'm still getting used to it but it seems to have some weird quirks around CEC overall. When a device is first turned on or connected over HDMI it can take up to a minute before remote navigation actually seems to work. Not sure if this is expected behavior or just an issue with this make/model.

Back to more related news: It looks like a big fix for DV/FEL stuff landed in the latest 21.0 nightly builds.
[Fire TV Original Android Development] Pro-me3us:
The nightly changes are coming faster than I can follow. Attached is the latest CE-NG 21 nightly kernel.img with embedded raven dtb. Let me know if you see any playback differences between the AM6+ and Cube. My audio setup is limited, I can see that lossless audio is passed through, but not with much granularity.

If you are anxious to jump on any nightly and don't want to wait, this the dtb/kernel packing procedure:

unpack new kernel.img

./unmkbootimg -i kernel.img

place raven_dtb.img in the same folder, and repack the kernel.img

./mkbootimg --base 0 --pagesize 2048 --kernel_offset 0x01080000 --ramdisk_offset 0x01000000 --second_offset 0x00f00000 --tags_offset 0x00000100 --kernel kernel --ramdisk ramdisk.cpio.gz --second raven_dtb.img -o kernel.img

The output kernel.img can then be copied over the CE USB stick.

EDIT: Updated the OP with the release version of CoreELEC 21.0, which includes all nightly changes up to April 6th, 2024.
[Fire TV Original Android Development] ddogishere:
Hello great work done here, thanks.

How do you create own kernel.img in windows as these cmd's are not recognised in windows cmd. Thanks.
[Fire TV Original Android Development] Pro-me3us:
mkbootimg / unmkbootimg are Linux programs, I don't know what Windows program can be used instead.

If you post the kernel.img from the build that you want to try, I can pack the raven.dtb into it.
[Fire TV Original Android Development] ddogishere:
Is a 9.2.3, thanks.
[Fire TV Original Android Development] Pro-me3us:
I doubt 9.2.3 will boot, it's 4 years old. You'd at least want to rebuild the raven.dtb with the 9.x source, and even then it's hard to say what drivers and dependencies might be missing that the Cube needs.

You can give it a try, here's your kernel.img back with dtb packed in.
[Fire TV Original Android Development] ddogishere:
Hi buddy, if I update to latest firmware in twrp, what exactly will I be losing and will I be able to downgrade after that? TIA.
[Fire TV Original Android Development] Pro-me3us:
TWRP isn't used for updating CoreELEC, it's either updated through CoreELEC directly or by moving the update manually to the /storage/.update directory on the USB stick, then rebooting back into CE for the upgrade to take place.

CE only installs on the USB stick. I don't know of any disadvantages to updating to CE 20.5 or CE 21.0. If you want to downgrade, wipe the USB drive and go through the install procedure again with the lower version.
[Fire TV Original Android Development] ddogishere:
Thanks. I find that when you update you have to reinsert the kernel.img manually via PC or it won't boot to CoreELEC.

And is update to Amazon latest firmware in twrp ok, what do one lose and is Amazon firmware downgrades also possible?

Thanks again.
[Fire TV Original Android Development] Wagmans:
You definitely need a new othb 2nd gen cube for this? Any old used 2nd gen cube off ebay wouldn’t work? It’s pretty hard to find a new one at this point.
[Fire TV Original Android Development] Pro-me3us:
The only requirement is that the 2nd gen Cube be on firmware below PS7603 (October 2022), which can be unlocked. A new sealed Cube is guaranteed to be on PS7229 or older firmware. It' possible you could find a used Cube with firmware below PS7603, but it would have to had been offline for 1.5 years, or the owner blocked updates.

That's normal, CoreELEC doesn't include a raven.dtb. It needs to be added to the new kernel.img after any update. Posting the dtb packed kernel.img's in the OP is currectly the simplest solution.

Alternatively, the generic CE tar (not img.gz) file for any CE version can be downloaded from github, and the kernel.img with raven.dtb added directly to the tar file, then the tar file moved to /storage/.update. When the Cube reboots to update, the raven.dtb packed kernel.img will be present in the install and the Cube will boot normally the first time.

It's generally ok to flash any firmware bin through TWRP. I can't gaurantee that Amazon hasn't slipped in a trojan horse on any new update, but at this point I don't think Amazon cares enough about a couple hundred discontinued rooted cubes to make that effort. I can say that I have tested PS7652/3564 (September 2023) and it works fine, no surprises.

Firmware has progressively gotten more restrictive, but most restrictions have little impact with root. PS7669/4007 (February 2024) removes local ADB connections, which breaks any apps that rely on ADB. Someone would have to make a Magisk module to get around that restriction, but I wouldn't wait around for that to happen.

You're free to downgrade to any firmware through TWRP, but a TWRP data wipe (equivalent of a factory reset) is highly recommended when going in that direction. The Cube will need to go through device setup / registration after a data wipe, and again avoiding the OTA update process. If you have any questions or concerns about the upgrade/downgrade process ask in the main raven rooting thread, to keep things here CE oriented.
[Fire TV Original Android Development] Wagmans:
Personally I’d rather just flash over the internal FireoS firmware completely and run Coreelec on it. I don’t really care about the original FireTV functionality.

Used boxes are relatively cheap and easy to find- if I can find one cheap enough I’m going to pick one up to fool around with.
[Fire TV Original Android Development] ddogishere:
Hi @Pro-me3us hope you are well. Do you know how to use the firetv remote in coreelec, do I buy a BT dongle for that as well? Thanks and can you please do a dtb for CE-22 just in case we want to try out the testing for CE-22.
[Fire TV Original Android Development] Pro-me3us:
Fire remotes use Bluetooth LE and BLE functionality isn't working for the MT7668 driver under CE. So yes a BT dongle is needed to add BLE support.

There aren't any CE-22 alpha builds posted on the release page. There's only pre-alpha nightly builds and those appear and disappear every few days. If you end up installing a CE-22 nightly you can post the kernel.img here for dtb packing.
[Fire TV Original Android Development] ddogishere:
Thank you for your help. I managed to use my TV remote to control CoreELEC via HDMI-CEC. So that will do for now.

Btw, do you know anyone @ OSMC who can supply the 3D code patches for Kodi omega?

Thanks.
[Fire TV Original Android Development] Pro-me3us:
No sorry, CE is my only experience with the world of Kodi OS's.
[Fire TV Original Android Development] signde:
I picked up a brand new in box fire cube 2 last weekend off eBay. I've read through all the instructions and the links here multiple times in preparation.

The unit arrived and was in fact sealed. I started on the process of skipping the forced update. Plugged in ethernet, saw the download started, unplugged ethernet. Held back + menu for a few seconds and sure enough got Voice View. Backed out of that, proceeded with entering my Amazon account details.

Before I hit submit I plugged the ethernet back and this is where it went wrong. A second or so after I plugged ethernet back in, the process acted like it died and bounced me right back to the first screen where it asks you to hit play, then select a language, then connect to internet for updates again.

Now when I unplug the ethernet cord once updates start, once I get the network error screen, I can no longer get Voice View to come up. Instead holding back + menu nets me with a a green box around the error message, see attached picture.

I've shut the box off and tried this two more times, same result.

I guess I am screwed? In the AFTVnews comments there seems to be at least one other person this happened to. It looks like voice view hack is a one time tutorial that happens the first time you enable it:

About VoiceView for Fire TV - Amazon Customer Service

VoiceView is a screen reader for Fire TV devices. It speaks on-screen text out loud as you navigate menu options and settings. You can also use VoiceView to help you set up your device.

www.amazon.com

Without that tutorial popup, the stop updates hack won't work?

I researched this for weeks, watched ebay for weeks, and laid out every step exactly in advance. This would be just my luck if I am now stuck and wasted money. I would appreciate any advice.

EDIT: Scratch all that, I did a hardware reset on the device and now I am back to Voice View. Leaving this here for posterity in case someone else hits this.
[Fire TV Original Android Development] kuileman:
Just get once update, then the system go into PS7212, and AFTVnews's method will be work fine.

I also got a brand-new firetv Cube this week . I'm afraid of updating. Bad experience.
[Fire TV Original Android Development] Pro-me3us:
If skipping the registration FireOS update goes horribly wrong, and the Cube reboots into recovery to update the firmware, pull the power cord right away! Better to brick than update.

All new 2nd gen Cubes have DFU access, a bootrom level recovery mode that can unbrick, unlock & root the device. It's just more work.

@kuileman Sounds like you got REALLY lucky if your Cube updated and landed on PS7212! The last batch of Cubes made ship with PS7229 then update to PS7614 (can't unlock & DFU access gone). Yours must have been made in 2019/2020.

For anyone with questions or worried about getting past the registration update, the main unlocking thread can go into as much detail as needed to feel more comfortable with the process.
[Fire TV Original Android Development] signde:
I feel like I have finally got all the kinks with mine worked out. Everything was really just a learning process.

I had laggy poster images in CE which was solved by a better USB stick. I am using this $9 PNY Elite and get 27.83 MB/sec which seems good enough to resolve that issue.

I started off with a Cable Matters USB Ethernet Hub which when wired was okay (250mbps) but I noticed when streaming high bitrate content off my NAS shares the device seemed to choke. I switched to WiFi and now all good. Not sure if that was just too much for the USB bus or what but wireless seems to do the job.

Also had an issue with lockup on booting CE, applied the bluetooth disable fix and that is good now too.

Last thing I sorted out was the device turning off and not being able to start without pressing the action button on the device. Disabled the CEC and set my Harmony settings for the activity to leave the device powered on all the time and all is good there now too. I am using an ancient USB Microsoft Media Center Remote and apparently it was issuing a shutdown command when I changed activities.

Pretty much everything I needed to know was in this thread, just had to tinker a bit. The whole process has been fun. Most importantly the device seems very solid and plays back everything I have thrown at it. Big thanks to everyone that made this possible.
[Fire TV Original Android Development] Pro-me3us:
A couple people have asked about running CE from the Cube's eMMC. I'd rather avoid complications of the ceemmc tool, because it resizes and adds partitions. However it's possible to migrate and run CE's /storage from the eMMC, and with the kernel and part of the system images running in RAM, you get most of the performance benefits.

The instructions come from Peter in the Homatics thread, and I've added them to the FAQ in case they need expanding on. CE will still boot from the USB stick, but it will mount and use the eMMC data partition (/data/coreelec_storage/). This won't affect FireOS, just keep in mind there is only ~12GB of usable eMMC storage.

250mbps should be more than enough, even when I've tried using the stock 100mbps adapter it was able to handle 60-75Mbps streams. You're on CE21? In CE20 we had to use advanced settings to increase the video cache. That was deprecated in CE21, and the option was added to Settings ► Services ► Caching. Try increasing the cache size to 200-500MB. I'll update the FAQ.

I don't know how much power the Cube vbus can output. I'd guess enough to handle at least two USB2 devices, but The USB2 port outputs 500mA total, shared among all the USB devices connected to the unpowered hub. That should be enough for a couple low-power devices, but can be hard to predict. I've always played it conservatively and used a powered USB hub.

The MediaTek MT7668 WiFi/BT drivers have been one of the biggest source of CE problems. I'm not completely sure that there won't be occasional lockups on boot even with the BT driver disabled. This problem isn't present in EmuELEC so it might be specific to CE+MT7668 drivers.

I tried working on getting the Cube to wake from suspend with CEC or action button press, but the WiFi driver would fail on wake.

I have my TV's CEC send power off command disabled. So maybe CoreELEC's CEC power off option will need to be disabled on most people's Cubes.

The Cube does have an IR receiver in it, but I'm not sure it's even used in FireOS. I couldn't see IR events in FireOS until modifying the native dtb. I was never able to detect IR events in CE. I suspect that it requires using Amazon's modified meson IR driver. The source is available, so maybe it could be ported. Since the Fire TV remote is only partly IR (just power and volume buttons) I gave up on it. The newer Fire TV remotes with channel buttons do have full IR and BT functionality, and in FireOS on the 3rd gen Cube I see IR events without having to make any modifications.
[Fire TV Original Android Development] signde:
I didn't know you could do the full ceemmc route with this box, that is good to know. I have probably read this entire thread three times over before I started this and yet somehow missed you can install CE storage on the eMMC until after I tried a better USB stick. Doing the move to eMMC is my plan.

I am on CE 21. I had seen the recommend advanced settings in the FAQ (buffermode, memorysize, readfactor) and applied them but I was unaware they were only valid for CE 20 so no I don't have those applied in light of that. For what it is worth I am seeing higher throughput with WiFi than I am on wired USB. Ethernet tops out around 250mbps for me while WiFi is closer to 325mbps. I'll test with the updated settings but i'm perfectly content with WiFi for now.

I appreciate that you tried. I understand it's complicated given the nature of the box being an Alexa unit and designed to stay on all the time. The ability to wake remotely is the last real item on my wishlist here but I can live with it just being on all the time. It's a tiny box and probably not using a lot of power.

Unrelated to al of the above, I have been seeing some chatter in the CE forum about VS10 engine support on the Ugoos. I am not that up to snuff on what VS10 is yet but is this something that will work on the Cube 2 as well in a future version of CE?
[Fire TV Original Android Development] Pro-me3us:
I only added the eMMC booting instructions in the last couple days. I had tried it out a month or two ago. I remember it shaved off 10sec from the bootup time, but didn't evaluate it for regular Kodi use. You'll have to let us know how much of a noticable difference it makes.

I think 325Mbps is the best I've seen anyone report on WiFi, I'd stick to that too. @cityhunter_1919_xyz you may be interested to hear raveb getting over 200Mbps on WiFi.

I ran an iperf3 speed test and got the following results in CE:

WiFi: 100-150Mbps (limited by my router WiFi AP)

Amazon 100Mbps Ethernet adapter: 95Mbps

Cable Matters 1000Mbps Ethernet adapter:

278-283Mbps (powered USB hub + CE USB Stick)​

242Mbps (powered USB hub + CE USB Stick + USB BT dongle)​

282Mbps (FireOS - no USB hub)​

​

My BT dongle is consuming ~40Mbps of the 480Mbps USB2 bus. I don't know where the other 60Mbps is being lost, a small bit could be the USB hub.

Yeah, I see it consume ~1.8W - 2W when idle under CE, not too bad.

Any features that are SOC dependent like video processing (VS10 & VSVDB Block stuff) should work the same across any of the s922 devices, probably even s905x2/x3 boxes. The Dolby VS10 engine is what is used in FireOS when you choose to have Dolby Vision always on. It can be used to convert SDR/HDR10/HLG to DV. Cpm is making some additional improvements to that code.

I haven't tested any of Cpm's builds yet, at least one person reported them working on the U22X-J so I'm not expecting any problems on the Cube.
[Fire TV Original Android Development] kuileman:
I tried @cpm the VS10 version. ( https://discourse.coreelec.org/t/edid-override-injecting-a-dolby-vsvdb-block/51510/150).

Amazing work.

Just Set Dispaly-led(not use VS10 mapping), the screen looks clearer than ever nightly version.

I think this version made my fire tv cube 2nd playing films as good as Blueray Disc player.

I also used "Dolby vison always on " function.

This function can solve the OSD and Subtitle turing into black colour when playing some particular DV movies.