I am finding this experimental project exceptionally fun and also a little reassuring looking toward possible future TVE and even future Broadcast roadblocks. I started out with just a single channel URayCoder HEVC H.265 H.264 Live HDMI Video Encoder with a Chromecast with Google TV (HD) Streaming Stick.
But decided right away I would kick myself constantly if I didn't get the 4 channel URayCoder 4K 4 Channels H.265 H.264 HDMI IP Video Streaming Encoder (so I am using one of those now). I added a second Chromecast and my primary main tuner is now an onn Android TV 4K. I am keeping my 4th available HDMI port open because frankly I think my current usage will only kick in the second tuner occasionally and the third rarely. Though who knows, maybe I'll play around with one of my old FireTV 4k Max sticks.
I have to offer my profound thanks to everyone here who have been posting their research and development. In particular @tmm1 for the original files. But also to @JT-DFW and @Fofer whose constant reports and updates and scripts I have Frankensteined into something that is working very well for me. BTW: I am doing a Windows setup for androidhdmi-for-channels, so I am using .bat files instead of .sh.
One thing I would like to see is maybe a modification/addition to the androidhdmi-for-channels program file to optionally run a maintenance script if it detects that all tuners have been inactive for a period of time. Currently I am running a nightly scheduled task to reboot the "tuners" and then put them to sleep. I would like to find a way to detect if all the tuners have been inactive for an hour and just simply do a cleanup reboot and put them to sleep till they are needed next.
In the interest of fair sharing, here is my current script batch files. There are three of each script, with only differences being the ip addresss of the 2 chromecast and 1 onn. These batch files of course need coding optimization and cleanup. They are a work in progress for me.
bmitune.bat script
@echo off
set "p1=%1"
set link=""
if "%p1%"=="nbc" set link=https://tv.youtube.com/watch/vsHPIz9ZC-4?onboard=1
if "%p1%"=="fox" set link=https://tv.youtube.com/watch/yVKpCICuh-A?onboard=1
if "%p1%"=="msnbc" set link=https://tv.youtube.com/watch/q6bWEVqhP8o?onboard=1
if "%p1%"=="e" set link=https://tv.youtube.com/watch/4XA2gdEOngg?onboard=1
if "%p1%"=="bravo" set link=https://tv.youtube.com/watch/P12seiJcdYo?onboard=1
if "%p1%"=="oxygen" set link=https://tv.youtube.com/watch/_XptfCraPjM?onboard=1
if "%p1%"=="usa" set link=https://tv.youtube.com/watch/8xN3o2PSL5s?onboard=1
if "%p1%"=="syfy" set link=https://tv.youtube.com/watch/uSfozGAsGMk?onboard=1
if "%p1%"=="cnbc" set link=https://tv.youtube.com/watch/GIBoX-XF5i0?onboard=1
if "%p1%"=="golf" set link=https://tv.youtube.com/watch/XK34g7QRvGk?onboard=1
if "%p1%"=="nfl" set link=https://tv.youtube.com/watch/_pYg9qMKKIA?onboard=1
if "%p1%"=="newsnation" set link=https://tv.youtube.com/watch/ZIzM3eNrylg?onboard=1
if "%p1%"=="mtvclassic" set link=https://tv.youtube.com/watch/YPB9f0dageg?onboard=1
if "%p1%"=="bbcnews" set link=https://tv.youtube.com/watch/g5BmB1qXulc?onboard=1
if "%p1%"=="smithsonian" set link=https://tv.youtube.com/watch/E7D0KRZIUso?onboard=1
if "%p1%"=="magn" set link=https://tv.youtube.com/watch/9dTo5rwwTjU?onboard=1
if "%p1%"=="nik" set link=https://tv.youtube.com/watch/cN5V1eeO3E4?onboard=1
if "%p1%"=="just" set link=https://tv.youtube.com/watch/EBdQc7HoF_E?onboard=1
if "%p1%"=="twcyt" set link=https://tv.youtube.com/watch/P_w3HTppc6E?onboard=1
if "%p1%"=="twc" (
adb -s 192.168.1.135:5555 shell monkey -p com.weathergroup.twc 1
waitfor ClearOutSpecialWeatherStatement /t 20
adb -s 192.168.1.135:5555 shell input keyevent 20 66
goto END
)
if "%link%"=="" goto END
c:\platform-tools\adb -s 192.168.1.135:5555 shell am start -a android.intent.action.VIEW -d %link% -n com.google.android.youtube.tvunplugged/com.google.android.apps.youtube.tvunplugged.activity.MainActivity
:end
The prebmitune scripts are
@echo off
set CONNECT=connect 192.168.1.135:5555
set WAKE=input keyevent KEYCODE_WAKEUP
set HOME=input keyevent KEYCODE_HOME
adb %CONNECT%
adb %CONNECT%
adb %CONNECT%
adb -s 192.168.1.135:5555 shell %WAKE%
adb -s 192.168.1.135:5555 shell %WAKE%
And the stopbmitune scripts are
@echo off
rem c:\platform-tools\adb -s 192.168.1.135:5555 shell am force-stop com.google.android.youtube.tvunplugged
c:\platform-tools\adb -s 192.168.1.135:5555 shell am force-stop com.weathergroup.twc
c:\platform-tools\adb -s 192.168.1.135:5555 shell input keyevent KEYCODE_HOME
rem c:\platform-tools\adb -s 192.168.1.135:5555 shell input keyevent KEYCODE_SLEEP
Oh, and the nightly maintenance batch file is
@echo off
c:\platform-tools\adb connect 192.168.1.194:5555
c:\platform-tools\adb -s 192.168.1.194:5555 shell input keyevent KEYCODE_WAKEUP
c:\platform-tools\adb -s 192.168.1.194:5555 shell am force-stop com.google.android.youtube.tvunplugged
c:\platform-tools\adb -s 192.168.1.194:5555 shell am force-stop com.weathergroup.twc
c:\platform-tools\adb -s 192.168.1.194:5555 shell input keyevent KEYCODE_HOME
c:\platform-tools\adb -s 192.168.1.194:5555 reboot
c:\platform-tools\adb connect 192.168.1.137:5555
c:\platform-tools\adb -s 192.168.1.137:5555 shell input keyevent KEYCODE_WAKEUP
c:\platform-tools\adb -s 192.168.1.137:5555 shell am force-stop com.google.android.youtube.tvunplugged
c:\platform-tools\adb -s 192.168.1.137:5555 shell am force-stop com.weathergroup.twc
c:\platform-tools\adb -s 192.168.1.137:5555 shell input keyevent KEYCODE_HOME
c:\platform-tools\adb -s 192.168.1.137:5555 reboot
c:\platform-tools\adb connect 192.168.1.135:5555
c:\platform-tools\adb -s 192.168.1.135:5555 shell input keyevent KEYCODE_WAKEUP
c:\platform-tools\adb -s 192.168.1.135:5555 shell am force-stop com.google.android.youtube.tvunplugged
c:\platform-tools\adb -s 192.168.1.135:5555 shell am force-stop com.weathergroup.twc
c:\platform-tools\adb -s 192.168.1.135:5555 shell input keyevent KEYCODE_HOME
c:\platform-tools\adb -s 192.168.1.135:5555 reboot
waitfor GiveTimeToFullyReboot /t 90
c:\platform-tools\adb connect 192.168.1.194:5555
c:\platform-tools\adb -s 192.168.1.194:5555 shell input keyevent KEYCODE_WAKEUP
c:\platform-tools\adb -s 192.168.1.194:5555 shell input keyevent KEYCODE_SLEEP
c:\platform-tools\adb connect 192.168.1.137:5555
c:\platform-tools\adb -s 192.168.1.137:5555 shell input keyevent KEYCODE_WAKEUP
c:\platform-tools\adb -s 192.168.1.137:5555 shell input keyevent KEYCODE_SLEEP
c:\platform-tools\adb connect 192.168.1.135:5555
c:\platform-tools\adb -s 192.168.1.135:5555 shell input keyevent KEYCODE_WAKEUP
c:\platform-tools\adb -s 192.168.1.135:5555 shell input keyevent KEYCODE_SLEEP