HDMI for Channels

I appreciate you two putting in all this work. :pray: It was such a struggle for me to get my setup working, and it seems stable right now, that I'm afraid to touch it to try this method. But if you ever get speed in tuning improvements (but perhaps that is streaming-device constrained), I'd go for it.

1 Like

I encountered a new issue using the traditional (go) method of doing this: - something got stale with the adb session and I saw "adb.exe: device unauthorized" - I had to do a "adb kill-server" in order to resume - here's the output of trying to run the scripts manually in this state:

already connected to 192.168.2.43:5555
already connected to 192.168.2.43:5555
already connected to 192.168.2.43:5555
adb.exe: device unauthorized.
This adb server's $ADB_VENDOR_KEYS is not set
Try 'adb kill-server' if that seems wrong.
Otherwise check for a confirmation dialog on your device.
adb.exe: device unauthorized.
This adb server's $ADB_VENDOR_KEYS is not set
Try 'adb kill-server' if that seems wrong.
Otherwise check for a confirmation dialog on your device.
adb.exe: device unauthorized.
This adb server's $ADB_VENDOR_KEYS is not set
Try 'adb kill-server' if that seems wrong.
Otherwise check for a confirmation dialog on your device.
adb.exe: device unauthorized.
This adb server's $ADB_VENDOR_KEYS is not set
Try 'adb kill-server' if that seems wrong.
Otherwise check for a confirmation dialog on your device.

C:\chdvr-hdmi>adb kill-server

C:\chdvr-hdmi>adb connect 192.168.2.43

  • daemon not running; starting now at tcp:5037
  • daemon started successfully
    connected to 192.168.2.43:5555

C:\chdvr-hdmi>stopbmitune.bat

C:\chdvr-hdmi>adb devices
List of devices attached
192.168.2.43:5555 device

Would it make sense to add 'adb kill-server' to the end of the stopbmitune.bat script? Or to the start of the prebmitune.bat script?

I have seen that as well so yeah thinking it might be a good idea. I'll test it on the stop command.

I definitely get where you're coming from -- since it was only a couple of weeks ago that I was first looking at this and wondering where to start!

What combination of streamer and app are you using? And the follow-on question, if it's not firetv/hulu or firetv/directv would you be willing to submit what you have to the base of streamer/app scripts we're building?

I just stole the scripts that others here posted, but Iā€™m happy to share when Iā€™m back at my server machine. Iā€™m doing this with YouTube TV and the Walmart Onn 4K Streaming Stick (latest model - 2023)

What is the best way to share?

Posting here would be fine, by putting each script in a code block. Or, you can open a Discussion for your particular streamer/app combo on GitHub sullrich/androidhdmi-for-channels.

EDIT: Just got some batch files from @Absenm via PM, and that works well too. So, dealer's choice.

Hulu is now randomizing the channel IDs for live streams. This is a fight I am not going to be able to keep up with. Need to find an alternate provider that is reliable and does not change around the IDs. Does one exist?

Do you mean random like this? https://tv.youtube.com/watch/OGgzNqTcHBw?onboard=1
That is how I watch NBC via YTTV - however, at least the link above hasn't changed since I set up the HDMI encoder.

Yep. But looks like I jumped the gun and copied the wrong ID's when I was updating some code. I need a nap.

I too have seen this with my MECOOL android box. It seems to work great for quite awhile but then it becomes hung.

I have now put that in my nightly maintenance script. All part of the keeping things nice and tidy process. So now in addition to rebooting all my devices and putting any devices to sleep that I am not using (honestly 99% of the time I only need one device sending a signal to the encoder) and now Im killing the adb server. So far I now run in to almost zero problems.

Thanks for mentioning this, I'm finding Haystack News to be a very cool addition to the CDVR mix, different from other HDMI streams of the typical linear channels we've been adding, due to their removal from TVE.

For those who haven't checked out Haystack News yet, I'd suggest checking out the app to see how it's different. It can be personalized to your interests and it presents a constant mix of news across assorted channels (AP news, Scripps, ABC, NewNation, local news, etc.) You can also have it display your local weather on the dashboard as well as events from a linked Google Calendar. I'm enjoying the presentation and variety as "news in the background."

In the Android app's settings you can enable auto-play on start and also pick the "auto fullscreen on idle" period. I picked 20 seconds (the other choices are 40 seconds, or Off.) I haven't played around too much but I'm wondering if it's possible to send an adb command after tuning in, in order to get it Haystack's video window to go fullscreen sooner than that? 20 seconds isn't bad, just wondering if we'd be able to override that with an adb tweak.

The Haystack News app can of course also be installed on my AppleTV for direct interaction but I'm enjoying having it alongside my other news sources inside the Channel app for quick channel surfing and browsing.

Now I'm wondering what other "auto-play" apps are out there with different content, mixes or playlists that may be a good fit for this too. The flexibility the HDMI for Channels project allows for this, has been amazing!

I'll be diving in when I am back from my travels next week. Very grateful for your brilliant work on this. The future looks quite bright indeed!

Here is a great command to clear the cache ...

adb -s 192.168.50.50 shell pm trim-caches 9999999999

I like to try new things like this, but I must be pretty stupid. Have a Uray encoder and an Onn streaming box, but I am not getting audio. I've tried swapping HDMI cables, updated firmware, changed every setting possible, rebooted countless times, nothing.

Sometimes after a reboot and I do a page refresh it will say audio "normal" and then go away.

Any suggestions? If I can't even get past this first step, forget the rest :slight_smile:

Did you try setting the Audio output to Stereo or PCM on your streaming device ?

There are three options - Automatic (Enable only the audio formats that are supported by your audio output device) - None (Never use surround sound) - Manual (Manually select audio output) and then there's Dolby Digital, Dolby Digital Plus, Dolby Atmos and DTS.

I tried automatic at first and then tried None (never use surround sound). I did not try the others because I thought never using surround sound would have worked.

What device are you using maybe others that have that Streaming device can help. I use FireSticks.

Thanks! It's the Walmart Onn streaming device that I've seen posted here. I tried to use a Firestick to test, but my stick kept crashing.

Before I used my Spare Firesticks I reset to factory settings removed any apps that are not needed.

I probably had your setup for a few days (until I switched from the URayCoder Single Channel Encoder to the URayCoder 4K 4 Channel Encoder). It worked out of the box just fine. So my first question is has the audio ever worked for you? Or did you just buy this encoder new to begin this project? Second question would be, does your Onn box send audio out to a TV if you connect it directly to the TV? If the Onn is sending properly directly to a TV then it is most likely sending properly to the encoder.

If it helps, here are some of my setting. I am using an Onn Android TV 4K UHD Streaming Device as my first device. I use Chromecast devices for the remaining devices.