OSMC and Hyperion

We had been having a good run, but then had a moment last night watching BBC iPlayer! That won’t have been 4K. In fact I don’t have any 4K content at all to try. All 1080p here.

thank you, ill give it a shot

Use this sketch.


I have my baud rate set at 115200. Needs to match the same settings in the webUI. Just select Adalight with that fastled sketch on your board.

@sam_nazarko when I installed hyperion.ng I experimented with getting it to start on boot. I am using the new Kodi app to do it but I also have systemctl enable hyperion so I believe I have to ways in place to start hyperion.ng on boot.

My question is that I accidentally added it to a service in the OSMC settings app, its greyed out and says (stopped). Obviously, this does not need to be here but I can’t remember how I added it. I referenced a different thread to add it into this folder that I can’t find at the moment.

Also, if I am using a @hissingshark build that I compiled from the installer, is there a way to update to any changes you make on git w/o doing a full uninstall and reinstall? I just want to commit your changes to my install.

Here is a photo of what I screwed up. Where might I find this folder lol?

I see the same thing. I can even hit pause and it continues to play until it syncs back up. I usually can hit play after and maybe in 5 seconds or so it will skip forward. I’ve been playing with difference capture frequencies and sizes also, which could be the issue. Also, maybe we should try turning off blackborder detection and see it it helps with A/V sync issues.

Greetings all.

According to its developers Hyperion is on the cusp of moving from Alpha to Beta!

The a/v sync bug is now fixed on Vero4K using Hyperion.ng and the latest kernel. It turns out we were missing some changes that had been included on other distros that the fixes had been targeted for.

You will need to:

Backup your configs:
There is an option to export your configs from the web GUI. You can then re-import them after the update.
Configuration->General->Import/Export Configuration->Export

Install the June OSMC update as usual:
uname -r should show at least 3.14.29-150-osmc
If you don’t then the AML grabber will be broken altogether.

Update my installer:
Easiest just to delete the hyperion-vero4k folder and clone it again:
(git clone https://github.com/hissingshark/hyperion-vero4k).

Update hyperion.ng
sudo ./install from inside the folder
Select Hyperion.ng->Install from binary

Restore your configs:
Configuration->General->Import/Export Configuration->Choose file then Import

NOTE - The pre-built binaries are updated to the latest stable commit and built for Framebuffer and AML grabbing. There’s no need to be compiling from source unless you specifically need another option like using external grabbers or want to be testing newer versions (there’s no real need to do that - if it was working I’d likely have updated the binaries anyway).


thanks for the update @hissingshark … i switched to your installer (had the version anthrax posted some month ago) since the june update gave me the sad face while playing video. looking good again :slight_smile:

Dear @hissingshark @sam_nazarko thanks for awesome work. Now i am able to run hyperion NG on VERO without glitch. I have jist Arduino Nano, Vero 4K and LED WS2801.
Just a few things to do for others who are interested. If you have external grabber you will need to make your own build from @hissingshark sources. At least i hope so. Am i right @hissingshark?
If you are using amlogic grabber follow these instructions OSMC and Hyperion - #537 by hissingshark

After all you need to change double_write_mode parameter of amvdec for H265(HEVC) and VP9(Youtube etc) decoder to value 3. I hope that everyone with VERO otherwise will have problems to make hyperion works with HEVC and VP9. Exact problem i don´t know. Bellow is just for info what parameters for doublewirte mode means.

/* DOUBLE_WRITE_MODE is enabled only when NV21 8 bit output is needed */
    /* hevc->double_write_mode:
    	0, no double write;
    	1, 1:1 ratio;
    	2, (1/4):(1/4) ratio;
    	3, (1/4):(1/4) ratio, with both compressed frame included
    	0x10, double write only

I am using a little modified script from @portisch CoreElec dev, but you can do that your way.
I have in hyperion.service following

    ExecStartPre=/bin/sh -c "exec sh /usr/share/hyperion/bin/platform.sh start"
    ExecStopPost=/bin/sh -c "exec sh /usr/share/hyperion/bin/platform.sh stop"

and script file platform.sh


if [ -d /sys/module/amvdec_h265 ] && [ -d /sys/module/amvdec_vp9 ];then
    case "$1" in
	sudo chmod 0666 /sys/module/amvdec_h265/parameters/double_write_mode
	sudo chmod 0666 /sys/module/amvdec_vp9/parameters/double_write_mode
        echo 3 > /sys/module/amvdec_h265/parameters/double_write_mode
        echo 3 > /sys/module/amvdec_vp9/parameters/double_write_mode
	sudo chmod 0666 /sys/module/amvdec_h265/parameters/double_write_mode
	sudo chmod 0666 /sys/module/amvdec_vp9/parameters/double_write_mode
        echo 0 > /sys/module/amvdec_h265/parameters/double_write_mode
        echo 0 > /sys/module/amvdec_vp9/parameters/double_write_mode

This will automatically rewrite permissions and values for double write paramaters for start and back to default values if you stop hyperion. Don´t forget to made platform.sh executable (chmod +x platform.sh) and chmod it to 0666.

Best regards

Perhaps you can clear this up for me? I’ve never had the opportunity to test an external grabber. My understanding is that you would need to build with V4L2 selected? Is that right?

I do not include this in my builds because that grabber appears to override the AML grabber with the effect that during video playback:

  1. There is no grabbing in the web GUI preview window;
  2. There’s a notification in the top right of the TV to say a video is playing, and the "resume from " option indicates that the video has been playing, but no playback happens on screen.

It may be that with a USB grabber connected it would work normally, but without one I cannot tell!

Is this only for usage with USB grabbers and stuff? Why must I need to turn on double write mode?

Also, besides the script app for Kodi, is there a way to have the LEDs turn off while the screensaver is on using hyperion.ng?

The script can also enable hyperion.ng at startup if you don’t have it done so already.

Hey @hissingshark,

after an afternoon of fiddling and using your AWESOME installer I now have a working Ambilight on my Vero4K+ again.

BUT (and there always is one): For the life of me I can’t figure out how to have the leds turned on automatically - this has never been an issue before…

  1. I have imported the old config and it’s working fine.
  2. I have successfully added and testet the hyperion systemd service unit
  3. after rebooting the hyerion webgui runs fine but the lights are off
  4. only after toggling disable hyperion → enable hyperion in the webgui the lights come on :frowning:

Does anybody have any explanation/idea?


1 Like

Have a look at this addon - this should fit your needs



Same thing here. @hissingshark

Do I need a comment for a specific branch after running sudo ./install.sh?

As in ‘sudo ./install.sh f7d5c2c9’

There you would be specifying a commit to build from, if that’s what you want to do/test for some reason. Otherwise it defaults to the latest stable looking commit. The branch is always master.

If you are installing from binaries then specifying a commit wont make any difference. Those are pre-built from the default/stable commit.

So close! Lets see:

  1. Are you using AML grabber?
  2. How are you connecting the Vero4k to the LEDs?
  3. I assume you’ve registered hyperion to autostart with “sudo systemctl enable hyperion”?
  4. After it has auto-started, what does “Remote Control” say in the webGUI i.e. active source?
  5. And are theLEDs “working” in the live preview window, even if not in real life?
  6. Where did your config come from? Was it exported from a build/install from my installer?

I used systemctl enable hyperion but I use the script app to start hyperion on boot and turn on everything but LED’s on with screensaver, which I use black or dim.

I have run into trouble with using systemctl start hyperion.service rather than using that script Kodi app to do so. I also changed it to Hyperion rather than Platform Capture, I notice different results with each. Usually all A/V sync issues. Seems to be all about how you start Hyperion.ng

I installed my current version with the argument after the ./install command. If I want to upgrade to the latest git version, just follow the instructions in your post?

I built from binaries using that argument. I would like to upgrade to current version w/o specifying a build. Was there a reason we were using that one in particular before the OSMC update?

Yes, please follow the instructions I have posted to update. That will have you at the newest version.

Previously we were hanging on at the old commit because I had determined that anything newer broke AML grabbing altogether. It was better to hang on at that point and have occasional A/V sync issues, rather than no video grabbing at all. That is all fixed now, as others have confirmed.

1 Like

V4L2 api should be used for external sources like USB grabber etc.

With V4L2 compiled in the build same problems as you mentioned in points 1, 2, but i don´t have usb grabber to confirm if after connection problems disappeared.

@nbraunstein I have installed latest OSMC june update and with @hissingshark builded binaries i can run videos smoothly except videos coded in HEVC or VP9(typically 4K videos). Whe i run these videos hyperion stops work. In webgui preview i can see distorted image. With double write mode set to 3 for HEVC i can see right captured image.

Today i made a few tests after cold boots(plug off from socket and after 10 secs plug on). HEVC videos works fine if set double write mode to 3.
VP9 videos are in webgui distorted after i set double write mode to 3 but works after set it to 0x10. I am a little bit confused, but in this configuration hyperion works, webgui and TV shows right images.

I didn´t make fresh OSMC installation it can be reason. So something is maybe messed up.
Can someone confirm with double_write_mode set to 0 can normally play HEVC and VP9 videos after June update with turned on hyperion?

1 Like