I was switching those around as I was flailing about trying to get it working. I was able at one point to see in Channels a snippet of a video by using the http://192.168.0.116/ts/1_0 that they list as the TS Preview URL.
"Chromecast with Google TV" ($29 for HD, $49 for 4K) is a good device choice for this. It's available just about everywhere. The HD version should be fine for this application.
With the few HDMI encoders I tested, I found that h265 significantly increased cpu load and latency. As such, it might not be worth it. Especially on a local network where the bitrate reduction won't have much value. Depending on the playback device it might also trigger a transcode to h264 on playback. IMO, it's worth at least playing around with both options when you get to a point where you are optimizing things.
It might be helpful to first get the HDMI encoder running outside of Channels DVR.
In VLC Media Player click file, open network, paste that "TS Preview URL" into the URL box, and then click "open". If the video output from your streaming device appears here then the streaming box is working correctly and you can move on to the Channels config.
You should change the frame rate (FPS) to 60 in the encoder config though.
On the main 'system setting page' change system mode to '1*1080p@50/60'; this will allow 60fps under the 'video' tab.
As others have mentioned, test with vlc:
Thanks @turtletank and @jad3675. Made that change and got it working in VLC. It now works in a custom channel selecting Stream Format-->MPEG-TS and using the preview URL which in my case is http://192.168.0.116/ts/1_0.
I found that issue as well with H.265. Especially for commercial skipping took way too long. I ended up using H.264.
Does the referenced encoder bypass/strip HDCP? Or is another device required?
So I've been testing settings and different scenarios. Manually selecting a channel from the Guide or On Now to play live works, most of the time. Not always though, and when channel surfing I'll either get "503" or a "connection to the HDHomeRun was lost. Press play to try again" error. And pressing play to try again, even multiple times, doesn't work. Exiting back to the Guide or On Now, and manually selecting a channel though, eventually does work. I've put these channels in a Collection of their own so I know to interface with them differently.
And thankfully, recordings thus far, tuned into by the server, seem to be proceeding without a hitch. I did change from H.265 back to H.264 on Encoder #1 due to the comskip speed advice, mentioned above, thanks! The PQ actually looks a bit sharper to me, H.265 looked a little soft, but that could be just my imagination.
All things considered though, things are working pretty well in CDVR as I get it dialed in... enough that I've started to add more than just the NBCU channels to the mix. YouTube TV has some other channels that never had TVE compatibility, channels like MTV Classic, NewsNation, and BBC News, so I've started adding some of them in too.
What other TVE holdouts (or externally launchable apps, with exclusive streaming content, specifically with mappable guide data) have you all found worth integrating via these HDMI encoders?
FWIW here's my current Custom Channel text:
#EXTM3U
#EXTINF:-1 channel-id="NBC",NBC
http://10.0.1.21:7654/play/tuner/nbc
#EXTINF:-1 channel-id="MSNBC",MSNBC
http://10.0.1.21:7654/play/tuner/msnbc
#EXTINF:-1 channel-id=E!" tvc-guide-stationid="61812" tvg-shift="+3",E!
http://10.0.1.21:7654/play/tuner/e!
#EXTINF:-1 channel-id="Bravo" tvc-guide-stationid="58625",Bravo
http://10.0.1.21:7654/play/tuner/bravo
#EXTINF:-1 channel-id="Oxygen",Oxygen
http://10.0.1.21:7654/play/tuner/oxygen
#EXTINF:-1 channel-id="USA", tvc-guide-stationid="58452" tvg-shift="+3",USA
http://10.0.1.21:7654/play/tuner/usa
#EXTINF:-1 channel-id="SyFy" tvg-shift="+3",SyFy
http://10.0.1.21:7654/play/tuner/syfy
#EXTINF:-1 channel-id="CNBC",CNBC
http://10.0.1.21:7654/play/tuner/cnbc
#EXTINF:-1 channel-id="Golf",Golf
http://10.0.1.21:7654/play/tuner/golf
#EXTINF:-1 channel-id="NFL",NFL Network
http://10.0.1.21:7654/play/tuner/nfl
#EXTINF:-1 channel-id="NewsNation",NewsNation
http://10.0.1.21:7654/play/tuner/newsnation
#EXTINF:-1 channel-id="MTV Classic" tvg-shift="+9",MTV Classic
http://10.0.1.21:7654/play/tuner/mtvclassic
#EXTINF:-1 channel-id="BBC News",BBC News
http://10.0.1.21:7654/play/tuner/bbcnews
#EXTINF:-1 channel-id="Smithsonian" tvc-guide-stationid="65799", Smithsonian Channel
http://10.0.1.21:7654/play/tuner/smithsonian
And here is my current bmitune.sh config:
#!/bin/bash
HOME="input keyevent KEYCODE_HOME; sleep 1"
PRIME1="input keyevent 19 19 19 19; sleep 1; input keyevent 21 21 21; sleep 1; input keyevent 22; sleep 1; input keyevent 23; sleep 1"
PRIME2="input keyevent 19; sleep 1"
PRIME3="input keyevent --longpress 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67"
SEARCH1="input keyevent 66; sleep 2"
SEARCH2="input keyevent 66"
#NBC
if [ $1 = "nbc" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/9iwfkw-dMAw?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#MSNBC
if [ $1 = "msnbc" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/q6bWEVqhP8o?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#E!
if [ $1 = "e!" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/ILTrUfLFrHI?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#Bravo
if [ $1 = "bravo" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/xNk2Sv4t4Tc?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#Oxygen
if [ $1 = "oxygen" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/v4upAc0UExk?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#USA
if [ $1 = "usa" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/DJ7m0fdLKEY?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#SYFY
if [ $1 = "syfy" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/2_WogcoZ1cY?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#CNBC
if [ $1 = "cnbc" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/GIBoX-XF5i0?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#Golf
if [ $1 = "golf" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/XK34g7QRvGk?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#NFL Network
if [ $1 = "nfl" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/_pYg9qMKKIA?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#NFL Network
if [ $1 = "newsnation" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/ZIzM3eNrylg?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#MTV Classic
if [ $1 = "mtvclassic" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/isxl2N52bUQ?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#AMC+
if [ $1 = "bbcnews" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/g5BmB1qXulc?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
It takes the input and presents it as a ts stream that can be used in VLC or channels.
So you're not using an HDMI "splitter" in between your streaming box and the IP Encoder?
I'm not, and HDCP doesn't appear to interfering with anything.
I will be adding a splitter soon to have simultaneous output though, which should bring back native output from, and control of, the same dongle to my TV's 4th HDMI input, where it was originally: https://amzn.to/3WtDRfy
As to be expected, I think the "tuner" management in this proof-of-concept is nowhere near as robust as it is for real HDHomerun hardware.
Even though a tuning request is coming from the same device the "tuner" cannot be used until the lock from the original stream is released. I think this is what causes the errors when quickly surfing though channels. As you noticed, for now it's best to just be patient and wait a bit before launching a new "hdmi" channel.
Agreed, just sharing real-world experience with this experiment so far, so others know what to expect, before buying hardware and diving in.
I'm having some problems with the channel guide mappings though. I handled them all manually. I'm unsure why some have numbers to the left of their logo (70, 106, 91, 24, 49, 108) and others don't.
Most work fine, but E!, Bravo and USA are off by 3 hours from the original guide that I see on YTTV, and I can't figure out how to fix or adjust them. When I search for a zip code and assign a local cable company, and then refresh, I notice later that added provider is removed.
I tried different matches for the same channel, and then refresh and wait a while, but none seem to stick or ever display with the proper guide data for what's playing now. Also, searching for "E" or "E!" on "Search All Lineups" just spins and spins, no selections offered.`
I then tried adding tvg-shift="+3" (and also tvg-shift="-3") to the M3U for these channels, refreshed and waited for guide data to fully repopulate but it didn't make any changes.
#EXTINF:-1 channel-id="Bravo" tvc-guide-placeholders="86402", tvg-shift="+3, Bravo
http://10.0.1.21:7654/play/tuner/bravo
What am I doing wrong? And do I need "tvc-guide-placeholders" at all? This tag just has successive numbers that start at 86400, but I'm not sure why or if that's actually necessary in this context.
Any feedback or ideas appreciated.
Shouldn't that be tvg-shift="+3" ?
can't have a comma in here
this is normal and harmless
this is confusing but normal. you don't need to add more providers any more now that there's a Search All
here are the station ids for for those three est vs pst
// "usa", "58452",
// "usap", "74030",
// "e", "61812",
// "ep", "91579",
// "bravo", "58625",
// "bravop", "73994",
Great, thanks!
I also found the answer to this question:
Answered fully here:
When your custom channel has no guide data, Channels will create airings for your channel. This way you can record them. It will even create special titles, series IDs, and program IDs based on the time slot so that you can make a Series Pass for them. By default it creates them with 1 hour durations. But you can control this yourself by providing their duration in seconds.
tvc-guide-placeholders: Duration of the placeholder. comma delimited. example (2 hours): "7200"
You can set the value to "false" to tell Channels to not make any placeholder airings at all. Setting the value to 24 hours or longer ("86400") will create 24 hour airings, but will drop the extra titles it creates for these airings.
Yep, I've been using the HD version of the CwGTV and it's been fine. As a general streaming device I was disappointed by it a couple of years ago given how limited the storage is. This bit of good news notwithstanding: Chromecast with Google TV HD has extra storage available
I was just tinkering with it, installed a bunch of core apps, and filled it up in no time! But for HDMI-IPTV streaming, this dongle seems like a perfect fit. And the price is right. As far as performance goes, the length of time from clicking the channel -- which sends the adb commands on my server to wake the dongle, go to its home page, launch the YouTube TV app directly to the desired channel and start streaming... is about 5-6 seconds on my setup. Not too bad, and I'm grateful to be able to get these channels integrated back into the DVR. And PQ is great, too! Not sure what I expected, but I'm impressed. Most of all, I really appreciate the flexibility this project inserts into the mix.
For anyone following along, or who might have the same ingredients, this is the M3U that's working for me with the channels I've added from YouTube TV, working with proper guide data on the west coast:
#EXTM3U
#EXTINF:-1 channel-id="NBC",NBC
http://10.0.1.21:7654/play/tuner/nbc
#EXTINF:-1 channel-id="MSNBC",MSNBC
http://10.0.1.21:7654/play/tuner/msnbc
#EXTINF:-1 channel-id=E!" tvc-guide-stationid="61812" tvg-shift="+3",E!
http://10.0.1.21:7654/play/tuner/e!
#EXTINF:-1 channel-id="Bravo" tvc-guide-stationid="58625",Bravo
http://10.0.1.21:7654/play/tuner/bravo
#EXTINF:-1 channel-id="Oxygen",Oxygen
http://10.0.1.21:7654/play/tuner/oxygen
#EXTINF:-1 channel-id="USA", tvc-guide-stationid="58452" tvg-shift="+3",USA
http://10.0.1.21:7654/play/tuner/usa
#EXTINF:-1 channel-id="SyFy" tvg-shift="+3",SyFy
http://10.0.1.21:7654/play/tuner/syfy
#EXTINF:-1 channel-id="CNBC",CNBC
http://10.0.1.21:7654/play/tuner/cnbc
#EXTINF:-1 channel-id="Golf",Golf
http://10.0.1.21:7654/play/tuner/golf
#EXTINF:-1 channel-id="NFL",NFL Network
http://10.0.1.21:7654/play/tuner/nfl
#EXTINF:-1 channel-id="NewsNation",NewsNation
http://10.0.1.21:7654/play/tuner/newsnation
#EXTINF:-1 channel-id="MTV Classic" tvg-shift="+9",MTV Classic
http://10.0.1.21:7654/play/tuner/mtvclassic
#EXTINF:-1 channel-id="BBC News",BBC News
http://10.0.1.21:7654/play/tuner/bbcnews
#EXTINF:-1 channel-id="Smithsonian" tvc-guide-stationid="65799", Smithsonian Channel
http://10.0.1.21:7654/play/tuner/smithsonian
FWIW I did try the PST station IDs first for E!, USA, SyFy, etc. but the guide data wasn't lining up. Only when I used the EST station IDs with the 3 hour shift, was I able to get them to line up 
I also just received the ONN 4K box, so will set it up later this week with the same channels as a "second tuner" via the 2nd IPTV encoder I got off eBay. I'm curious to see if the adb commands work the same. It'll also be interesting to see how it compares, performance wise, to the first tuner. Stay tuned! 
The Smithsonian Channel is another great candidate for this, I've added it to the HDMI mix:
Here is my working bmitune.sh file:
#!/bin/bash
HOME="input keyevent KEYCODE_HOME; sleep 1"
PRIME1="input keyevent 19 19 19 19; sleep 1; input keyevent 21 21 21; sleep 1; input keyevent 22; sleep 1; input keyevent 23; sleep 1"
PRIME2="input keyevent 19; sleep 1"
PRIME3="input keyevent --longpress 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67 67"
SEARCH1="input keyevent 66; sleep 2"
SEARCH2="input keyevent 66"
#NBC
if [ $1 = "nbc" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/9iwfkw-dMAw?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#MSNBC
if [ $1 = "msnbc" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/q6bWEVqhP8o?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#E!
if [ $1 = "e!" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/ILTrUfLFrHI?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#Bravo
if [ $1 = "bravo" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/xNk2Sv4t4Tc?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#Oxygen
if [ $1 = "oxygen" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/v4upAc0UExk?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#USA
if [ $1 = "usa" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/DJ7m0fdLKEY?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#SYFY
if [ $1 = "syfy" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/2_WogcoZ1cY?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#CNBC
if [ $1 = "cnbc" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/GIBoX-XF5i0?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#Golf
if [ $1 = "golf" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/XK34g7QRvGk?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#NFL Network
if [ $1 = "nfl" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/_pYg9qMKKIA?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#NFL Network
if [ $1 = "newsnation" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/ZIzM3eNrylg?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#MTV Classic
if [ $1 = "mtvclassic" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/isxl2N52bUQ?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#BBC News
if [ $1 = "bbcnews" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/g5BmB1qXulc?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
#Smithsonian Channel
if [ $1 = "smithsonian" ];then
HOME="input keyevent KEYCODE_HOME; sleep 1"
adb shell am start -a android.intent.action.VIEW -d https://tv.youtube.com/watch/c05ACdzJxiE?onboard=1 -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
fi
So how does this integrate with streamlinks to start and record the NBC channels directly, i.e. not with YTTV but directly on specific apps? You have to run both containers?
To clarify, I’m not actually recording with YTTV. (And those other NBC apps don’t have cloud recording functionality either, their content is “on demand” instead and often with commercials.)
So the way this is working is, the stream that’s launched on the Android dongle is fed through the HDMI>IPTV encoder, and Channels DVR is then recording it like all of its other custom sources. This setup doesn't exit the Channels app, your interactions on the client remain there and you still use the Channels interface to pause, skip back, etc. The IPTV feed simply acts like a live channel you're tuned into.
All things considered, it's a clever and effective workaround for the DRM turd that NBCU dropped in our punchbowl last month. And as I've also discovered, a great way to pull in live streams that were previously unavailable to my CDVR setup too, such as MTV Classic, NewsNation, The Smithsonian Channel, BBC World News, etc.
Anyway, back to your question. Your own bmitune.sh file could launch different streamlinks for whatever you channels you choose instead, and it could work similarly. You'd just need to code it so your adb key sequence gets to the intended playing video, as not all apps begin streaming automatically, by default, upon launch.
These lists for “launching apps” and “live TV” may help get you started: Stream Link URLs


