• 1
  • 239
  • 240
  • 241(current)
  • 242
  • 243
  • 553
Linux ChromeBox Kodi E-Z Setup Script (LibreELEC/Linux+Kodi) [2017/02/21]
(2015-02-18, 10:20)Matt Devo Wrote:
(2015-02-18, 08:12)meeotch Wrote: Just got my Asus Chromebox, and installed Ubuntu/Kodi dual-boot. Relatively painless, except...

1) My wifi link seems slow. On first boot after the script updated my firmware, I couldn't connect to my wifi network at all for about 10min - kept getting the "out of range" error in chromeos. After I managed to connect & finish installing ubuntu, my link speed (as given by iwconfig) never seems to get above ~120Mbps (802.11n), or ~300Mbps (802.11ac). By comparison, my ancient laptop, sitting at the same location, gets a 200-450Mbps 802.11n link. Before flashing back to the stock firmware to see if it's any better, I thought I'd post here.

when running a dual boot setup, you're running the stock firmware, just with a fixed/modified legacy boot payload. This has absolutely no effect on networking, wired or wifi, under ChromeOS or any other OS. Any issues you are having with wifi are due to something else - your router, RF environment, wifi card hardware/firmware/drivers, etc. Also, unless Asus changed components, the included Atheros wifi/BT module is dual-band (2.4/5GHz) abgn, not ac. Also, the reported link speed and actual transfer speed are loosely correlated at best.

I can confirm. My HP (I think they're using the same wifi card, no?) connects at a stable 300mbs *link* speed, which is the maximum (only 2x2 mimo) I think only the Dell has AC wifi, which would top out at 866mbs or so.
Reply
(2015-02-17, 22:20)Matt Devo Wrote:
(2015-02-17, 21:20)hockeycoach Wrote: Thanks for the reply!
Due to "personal malloc errors" (aka brain cramps) I had done a bunch of screen grabs during the installation... just in case, and I just looked, and yes I did answer 'y' to the install Kodi question.

I will try your search suggestion.
It was very late last night when I finished the install and I had been scratching my head on another issue when I noticed the Kodi thing.

if it didn't install automatically as it should have (I'll check that here shortly, just LMK what options you chose for version and metapackage), you can just follow the instructions on the Kodi wiki for linux/Ubuntu installation and all should be fine.


Hi Matt
So I did the search for kodi as you suggested and found it! Thanks ! Added it to the menu, all is good.
The other issue I was fighting, where it would not automount a 32G sd card seems to have cleared itself up after rebooting.

Now I'm playing with the colour levels between the asus chomebox and my sharp aquos , (xrandr) but not too worried I'll get it the way I want it... eventually Smile

The only thing left to sell this setup to my wife is to have Kodi start automatically after power up and Ubuntu boot. I'm going to look into the RC scripts and add it there... unless there is another way you might suggest.
Reply
(2015-02-18, 17:40)hockeycoach Wrote: Hi Matt
So I did the search for kodi as you suggested and found it! Thanks ! Added it to the menu, all is good.
The other issue I was fighting, where it would not automount a 32G sd card seems to have cleared itself up after rebooting.

Now I'm playing with the colour levels between the asus chomebox and my sharp aquos , (xrandr) but not too worried I'll get it the way I want it... eventually Smile

The only thing left to sell this setup to my wife is to have Kodi start automatically after power up and Ubuntu boot. I'm going to look into the RC scripts and add it there... unless there is another way you might suggest.

that's outside of my area of expertise, as I'm an OpenELEC user myself. Try the Linux/Live support forum as well as the Kodi wiki. I only provide the Ubuntu option for historical reasons (and user request)
Reply
Hockeycoach, If you apt-get Kodi then the standalone option xsession gets added automatically. You basically only need to set autologin. Would be easier to just install Kodibuntu, though, if you don't need to run full blown Ubuntu/Unity. I did post my steps a few pages back. Works really good. I'm using a PS3 remote and the waf factor is superhigh, including playback of Netflix through netflixbmc. In fact it works so good that I'm going to give away a box to my sister, and that is saying a lot!
Reply
i am sorry to bother you, but i think i need help.

I just tried to update my standalone build of xbmc 4.something.

I updated the core like this:
Quote:-------------------------------------------------------------
Updating the coreboot Firmware (standalone)
-------------------------------------------------------------
As of version 3.0 of the script, you can simply re-download/re-run the script under any Linux distro with a full bash shell. The dual-boot related options will be disabled, but the Standalone Setup / coreboot firmware update option will be available.

If you are running a Linux distro which does not have a full bash shell, such as OpenELEC, you should use my standalone firmware updater script from an SSH terminal. This script is only intended to update a ChromeBox already running my custom coreboot firmware (via the EZ setup script), and will not work under ChromeOS/ChromiumOS.

Code:
curl -L -O http://goo.gl/HSZer4
bash HSZer4

Note: the bash command will require using the 'sudo' prefix if not running OpenELEC (since with OE, you are always logged in as the root user). Additionally, this script must be run immediately after booting, otherwise it may fail to detect the current firmware version.
When i try to run it again, it says, that it is already up to date, yet the date of the latest firmware is the 29th of jan. There has been updates since - how can i get those?
Quote:You already have the latest firmware (20150129)

But since this seems to have worked somehow, i tried to update openELEC. I pulled newest openelec .tar http://releases.openelec.tv/OpenELEC-Gen...-5.0.2.tar and put it in the /updates folder. I rebooted and it seems as it was installed quite fine.


But i am afraid it was only a "dirty install", since it did not loose any settings or network folders etc. All stayed the same. Since we are supposed to do a fresh setup, i was wondering what i did wrong, and how i can do a clean setup?

Sorry for my english Big Grin And thanks in advance.
Reply
@AttacktheCow,

- there's no need to update the firmware unless you are having issues that a new version fixes
- if you look at the change log, 2015-01-29 is the latest/current firmware version. The firmware isn't always updated every time the script is
- the firmware and OpenELEC are not coupled in any way, so you can (should) just update OpenELEC in the future
- a dirty install is ok for the 4.x -> 5.0 update as long as you don't run into issues; if you do, then a clean install is recommended. Or just use the 'Hard Reset' function under the OpenELEC General settings.
Reply
Thanks for the replies, fritsch & matt.

(2015-02-18, 09:03)fritsch Wrote: Which kind of ramp do you display?
When you force your GPU to full, what can you still see on this image: https://dl.dropboxusercontent.com/u/5572...b_test.jpg

I'm using the grayscale ramp video linked in the wiki (playing it in kodi): file link.
When I set the GPU to "Full" and view the image you linked, I can see down to maybe about the 2nd or 3rd black box on the top row, but that whole row is very dark. In "Limited 16:235", the top row has what looks like a smooth gradation. Two points worth noting: 1) system appears to come up in "Limited" mode. 2) my display is actually a computer monitor (Dell U2410) connected through HDMI, as I don't own a t.v. I suspect this makes a difference, but it should still be possible to both eliminate banding & have correct levels - or am I misunderstanding?

(2015-02-18, 10:20)Matt Devo Wrote: unless Asus changed components, the included Atheros wifi/BT module is dual-band (2.4/5GHz) abgn, not ac. Also, the reported link speed and actual transfer speed are loosely correlated at best.

Thanks for the correction - I missed that in the iwconfig output. I should probably mention that the link speeds fluctuate wildly, despite my router being about 30ft away. Anyway, I believe what you say, but will nonetheless test against the duplicate stock chromebox that amazon is mistakenly delivering today. I'll test the actual throughput & link speed, provided that I can find a suitable way of doing both on ChromeOS. (Suggestions welcome.)
Reply
How would a 16 to 235 ramp look on a 0 to 255 display?

A test image with full rgb should look correct.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
@fritsch - o.k., so I think I've got it... The key being this sentence: "By default XBMC takes the original 16-235 levels and expands them to 0-255."

So xbmc assumes that input video files have preserved the 16-235 range from the original source material, and by default scales this to 1-255, which is then either re/de-scaled to 16-235 (Limited) for output to a t.v. or left alone (Full) for output to a monitor. So when viewing on a monitor, you're stuck with either banding (if you expand) or incorrect levels (if you don't).

Two things that still confuse me: 1) if I play that full-range grayscale ramp video with all scaling turned off ("Limited" kodi / "Full" xrandr), the ramp is smooth, but the range is clearly smaller than the same file played in the stock ubuntu Videos application, which displays a deeper black / brighter white. Does this indicate that all/most video players are assuming a 16-235 range for .mp4 content, and scaling accordingly?

2) is this a valid assumption to begin with? I would think that it would make more sense for the ripping/encoding application to apply the scaling (along with dithering to clean up the banding) itself, given that 16-235 is really a broadcast thing... or at least that there would be info embedded in the files indicating the correct range, and that kodi / other video apps would read this, rather than assuming anything.
Reply
(2015-02-19, 00:16)meeotch Wrote: So xbmc assumes that input video files have preserved the 16-235 range from the original source material, and by default scales this to 1-255, which is then either re/de-scaled to 16-235 (Limited) for output to a t.v. or left alone (Full) for output to a monitor. So when viewing on a monitor, you're stuck with either banding (if you expand) or incorrect levels (if you don't).
That's not exactly how it works. Modern videos codecs use a YUV color space (MPEG-1, 2, 4, H.264, VC1, HEVC, etc). It's supposed to be 16-235 per the various specs. PCs don't work in YUV color space. They work in RGB. So they have to convert YUV to RGB. When this is done it's possible to pick a target output range. Generally RGB 0-255 or RGB 16-235. You don't want to be stretching or compressing the RGB output levels after the YUV -> RGB conversion. You also don't want to convert it back to YUV. I don't know where the various options for manipulating the output range are taking place. Ideally they would change the mathematical factors in the YUV -> RGB conversion, but I suspect that's not the case for the option in Kodi menu. The xrandr --output HDMI1 --set "Broadcast RGB" "Full" option seems to change the YUV -> RGB factors, but I could be wrong.
Reply
Meetoch. Stop trying to reinvent the wheel.
If your display supports rgb full then you set xrandr to full, and XBMC to full. That is the best way and the only way. Then you adjust your display to get it right. This gives the best quality in XBMC, and it looks right when you are logged on to a normal desktop environment. The xrandr command can be set as a global init.

If your display does not support rgb full, then you'd still have to sett xrandr to full and set XBMC to limited. That is if you want the best image quality in Kodi. (Unless Kodi use a 2-pass rgb to rgb conversion, which would be a strange thing to do) But the desktop environment would look wrong with xrandr set to full. If you're using kodi-standalone then I would suggest having a xrandr set rgb to full when starting kodi-standalone, and rgb to limited when starting the desktop environment. ( If you're using chrome launcher, then you'd need to use a custom script to set the correct level when starting/stopping Google Chrome from within xbmc)

And Stereodude is right, and the post that you are referring to is wrong. (and the rest of that post is not entirely correct either)
Reply
Not trying to reinvent the wheel - just trying to understand the wheel. Clearly, if the wiki is linking to partially correct info, then the topic is more involved than it seems. The various posts here have helped - including yours, so thanks for that.

In my particular case, I've got multiple sources coming into this monitor, and intend on using the chromebox for more than just kodi (hence the dual-boot non-standalone install), and in fact, I've got a plasma t.v. on the way, so I'll be revisiting this all again soon... So understanding why is as important as understanding what. "Build a man a fire, and he'll be warm for a day. Set a man on fire, and he'll be warm for the rest of his life."

Anyway, if I've finally got it right, it seems to boil down to: 16-235 range is inherent to the codec & would be "right" assuming the rest of the chain is video equipment. I.e. scaling is only necessary to make the image fit in with the rest of what's going on in a PC (gui, etc.). Only in the case of a display that natively eats 16-235 is there a special configuration, which is specifically to pass the data through unscaled, rather than scaling in the decode then de-scaling at the GPU. This is a bump up in image quality for the video, at the expense of everything else being improperly out-of-range for the display. (Except maybe kodi is smart enough to adjust its gui values to 16-235 as well?)

-----------
EDIT: regarding the wifi issue, my admittedly unscientific results: stock chromebox did indeed show similar wifi performance, based on copying a ~700MB file over the network, since that's all I could think of to do from ChromeOS. However, I did manage to get pretty good speed in general by forcing it to connect to the 5GHz side of my router. Something like ~25MB/s.
Reply
You're spinning away with your wrongful theories again.
As I said, the correct thing , considering your display accepts rgb full, is to set xrandr rgb full and Kodi to full.

The 16-236 range in a codec is in YUV format, there is no such thing as an unscaled YUV 16-235 to RGB (or RGB 16-235/limited for that matter). This color space conversion is slightly lossy at best, meaning YUV 16-235 to RGB full is more accurate. And that is only half of the story: your display is internally using RGB full, so if you send RGB limited into the display it will convert that into rgb full , which in itself is lossy as well. So using rgb full all the way is basically a double win.

Yes the GUI will adjusted accordingly if set Kodi to limited, not that it matters in your case.
Reply
Matt Devo, you rock!!!

My htpc died last week. I was pretty sad as I had built it myself --> http://forum.kodi.tv/showthread.php?tid=134694

I ordered an Asus chromebox for $142 on Amazon

With your script, I got it up and running with openelec in 20 min.

It is as fast and snappy as my former htpc, which was an AMD A6, but much smaller, quieter and more power efficient

To top it all off, I ended up getting 1TB on Google Drive for 2 years lol. The promotional materials for the chromebox said 100GB, but Google gave me 1TB. That sure was a nice surprise.

Thanks, man!!
Reply
(2015-02-19, 03:34)Soli Wrote: there is no such thing as an unscaled YUV 16-235 to RGB (or RGB 16-235/limited for that matter)

Not sure what you mean by this - surely you can convert YUV 16-235 to any encoding you want, RGB 16-235, RGB 1-255, 16-bit, floating point, cineon... But anyway, yes, I get it - with my current full range monitor, it makes sense to let the scaling happen during the decode in kodi, and the rest of the chain is full range. I'm happier knowing why this is than just that it is, so thanks to everyone who took the time to explain.
Reply
  • 1
  • 239
  • 240
  • 241(current)
  • 242
  • 243
  • 553

Logout Mark Read Team Forum Stats Members Help
ChromeBox Kodi E-Z Setup Script (LibreELEC/Linux+Kodi) [2017/02/21]37