ADBTuner: A "channel tuning" application for networked Google TV / Android TV devices

Yeah I really would not like to have to edit the M3U to get correct guide data ...

#EXTINF:-1 channel-id="175843821434038601238833585820720759399" channel-number="2",ABC
http://192.168.50.68:5594/stream/12

Iā€™m sorry. Iā€™m not sure I understand. What issue are you seeing as a result of having the channel number in ADBTuner not match the OTA channel number?

It is not getting the Channel number from the target ... Target Channel Number (ex 11.1) ... It is getting it from "Channel Number" which you cannot include the period.

So the M3U looks like this not 2.1 .. It tunes correctly but the M3U is wrong.

#EXTINF:-1 channel-id="175843821434038601238833585820720759399" channel-number="2",ABC
http://192.168.50.68:5594/stream/12

Is the channel not working? Are you having trouble mapping it to guide data?

You.can map it fine but you have to abandon the traditional channel numbers 11.1 11.2 11.3 etc

The Problem is that We cannot use the M3U directly ... I have to copy to text then Change my OTA channels to include the Period.

For example 106.1 OTA on the M3U comes out as 106 but I already have a Chanels 106 in my Primes CSPAN ... The period is needed for correct mapping.

I'm really sorry. I'm just confused.

From my perspective it's ADBTuner channel 106 because ADBTuner is the source. We don't really assume those numbers match numbers from another provider (Cable, OTA, etc.). And as you are seeing, when you have multiple sources those numbers can conflict with each other.

For example, my local 6.1 is configured in ADBTuner as 6001 so it doesn't conflict with my HDHomeRun OTA source. It maps nicely to the guide data based on channel name alone, but I also add the Gracenote Station ID to ADBTuner to make sure it does.

I guess you would just like the have the traditional channel numbers in the guide? I will make this change when I get a chance to accommodate that. Edit: experimental build has this change now.

The workaround isnt bad honestly. You just download the m3u from the browser then make your edits, then paste into the channel config. If you make changes to adbtuner, you just have to remember to re-download the m3u and append any changes directly to the channel config.

But if the HDHomerun app ever does ATSC 3.0 DRM channels more channels will have to be edited etc ... I have no problems but some of my clients are not technical. ..... using the M3U direct with no edits is much easier.

image

I guess my thought was that there was no reason it needs to be 106.1. It could be 1006, or 500, or 50000. Or you can hide the ATSC 1 version and just have "6" in the guide. They are functionally equivalent. It's just a display thing.

Regardless, I just pushed an update to the experimental version to allow one decimal place in that field. Hopefully this solves things for your use case.

Working Great thanks ....

#EXTM3U

#EXTINF:-1 channel-id="175843821434038601238833585820720759399" channel-number="2.1",ABC
http://192.168.50.68:5594/stream/12

1 Like

I like this change. I use ADB as a failover if TVE acts up. Channels will handle it as a duplicate if I set them with the same number.

UPDATE
@tmm1 disregard. This was an issue with me having multiple NIC's on my docker server. packets were going in one interface and being answered out of another. I ended up putting my adbtuner on a macvlan ip and that solved it

Having an issue with the streams dying after 20-30 second after I tune the channel via channels/adbtuner.

TLDR:
Tune via channels/adbtuner/linkpi (any client) stream dies after 20-30 seconds
Tune via channels/linkpi (bypass adbtuner & stream direct as a custom channel) - works perfect
Tune via VLC/adbtuner/linkpi (bypass channels) - works perfect

As a test I created a custom channel outside of adbtuner and made the source a direct http link to the linkpi (bypassing adbtuner). this works perfectly with no issues.

Then I bypassed Channels and used the adbtuner link to tune the channel (http://172.16.0.38:5592/stream/26) in VLC. This works perfectly. So this is definitely a channels server issue. @tmm1 could you check out my logs? You will see several instances in the logs like
"Cancelling stream M3U-LinkPi"

390a6145-6814-462f-a9d3-b3bbaa494c0c

2024/04/29 17:08:53.970630 [TNR] Opened connection to M3U-LinkPi for ch5863 mlb Network
2024/04/29 17:11:19.900217 [TNR] Cancelling stream M3U-LinkPi ch5863 after no data was received for 2m0s
2024/04/29 17:11:19.900559 [TNR] Closed connection to M3U-LinkPi for ch5863 mlb Network
2024/04/29 17:11:19.901364 [SNR] Buffer statistics for 192.168.12.20 (Seth's Office ATV) for ch5863 mlb Network: buf=0% drop=0%

I used to be able to use ADBTuner with my Paramount+ app to not only connect to the local CBS channel, but also access each of the Showtime channels. The Showtime channels have not worked for a while now. Anyone else trying to do this and having a similar experience? I of course am using the experimental build and compatibility mode, as the Paramount+ app has a "Who's watching?" screen.

I believe the current deep links for each of the Showtime channels, at least studying them through the browser are:

https://www.paramountplus.com/live-tv/stream/showtime-east/
https://www.paramountplus.com/live-tv/stream/showtime-west/

These links no longer seem to find their way through the app on my chrome cast with google TV.

They do seem to work on my phone however.

Anyone else have a similar experience? Anyone else have a better solution?

Hi all,

I purchased a Exvist encoder. I have everything setup. No matter what I do when I tune a channel in ChannelsDVR it constantly switches back and forth between the channel and the YTTV home screen. The video does not appear in Channels but I can see it in the direct feed. Thanks for any help anyone can provide.

I don't have a showtime subscription, but my local CBS channel loads just fine using ADBTuner and a Chromecast with Google TV. The "who's watching" dialog is also cleared automatically. I have to enable "compatibility mode" because the deep links won't work if the app is already open.

It may be helpful to try with ?adb-debug=1 added to the end of the URL (https://www.paramountplus.com/live-tv/?adb-debug=1). With this added you can watch what's happening during the tuning process to see if anything sticks out as problematic.

Can you share the docker logs from when the stream dies after 30 seconds?

This is what I see in Docker when Channels tries to tune a channel:

2024-05-02 20:37:50.365 - server - Tuner: Tuning to ANIMAL-PLANET on Onn 1

983

2024-05-02 20:37:50.367 - lib.adb - ADB: Connecting to device (attempt 1).

984

2024-05-02 20:37:55.372 - lib.adb - ADB: Connection error. Device may be waking up. Trying again.

985

2024-05-02 20:37:56.373 - lib.adb - ADB: Connecting to device (attempt 2).

986

2024-05-02 20:38:01.378 - lib.adb - ADB: Connection error. Device may be waking up. Trying again.

987

2024-05-02 20:38:02.379 - lib.adb - ADB: Connecting to device (attempt 3).

988

2024-05-02 20:38:07.384 - lib.adb - ADB: Connection error. Device may be waking up. Trying again.

989

2024-05-02 20:38:08.384 - lib.adb - ADB: Connecting to device (attempt 4).

990

2024-05-02 20:38:13.390 - lib.adb - ADB: Connection error. Device may be waking up. Trying again.

991

2024-05-02 20:38:14.390 - lib.adb - ADB: Connecting to device (attempt 5).

992

2024-05-02 20:38:19.396 - lib.adb - ADB: Connection error. Device may be waking up. Trying again.

993

2024-05-02 20:38:20.396 - lib.adb - ADB: 192.168.50.238 - dumpsys display

994

2024-05-02 20:38:20.396 - lib.adb - ADB: Error while running command. Check for approval popup on device.

995

2024-05-02 20:38:20.396 - lib.adb - ADB: 192.168.50.238 - getprop ro.build.version.release

996

2024-05-02 20:38:20.396 - lib.adb - ADB: Error while running command. Check for approval popup on devi

ADBTuner is failing to control the android device. Does the device status indicate that it is connected properly in the ADBTuner interface?

Hi,

Yes. Endpoint Connection Successful

Android 12

Available

When ChannelsDVR tunes a channel, if I watch the live stream, I can see YTTV switching back and forth between the YTTV and the tuned channel. The tuned channel will play for about 2 or 3 seconds and then switch back to the YTTV home screen. It will do this 4 or 5 times in a row. It appears that adbtuner is definitely able to tune the channel. It just does not realize that it has done so if that makes sense. Thanks

Always just goes to CBS station instead...

2024-05-02 18:15:33 2024-05-03 01:15:33.454 - server - Available Tuners:
2024-05-02 18:15:33 2024-05-03 01:15:33.454 - server - Name: Chromecast 1 Priority: 0
2024-05-02 18:15:33 2024-05-03 01:15:33.455 - server - Name: Chromecast 2 Priority:
2024-05-02 18:15:33 2024-05-03 01:15:33.455 - server - Name: Chromecast 3 Priority:
2024-05-02 18:15:33 2024-05-03 01:15:33.455 - server - Using first available tuner (by priority).
2024-05-02 18:15:33 2024-05-03 01:15:33.455 - server - Reserved Tuner: Name: Chromecast 1 Priority: 0
2024-05-02 18:15:33 2024-05-03 01:15:33.455 - server - Using tuner id: 1 for stream.
2024-05-02 18:15:33 2024-05-03 01:15:33.455 - uvicorn.access - 192.168.65.1:26715 - "GET /stream/3 HTTP/1.1" 307
2024-05-02 18:15:33 2024-05-03 01:15:33.462 - server - Tuner: Tuning to Showtime East on Chromecast 1
2024-05-02 18:15:33 2024-05-03 01:15:33.464 - lib.adb - ADB: Connecting to device (attempt 1).
2024-05-02 18:15:33 2024-05-03 01:15:33.509 - lib.adb - ADB: Connected.
2024-05-02 18:15:33 2024-05-03 01:15:33.509 - lib.adb - ADB: 192.168.50.236 - dumpsys display
2024-05-02 18:15:33 2024-05-03 01:15:33.562 - lib.adb - ADB: 192.168.50.236 - getprop ro.build.version.release
2024-05-02 18:15:33 2024-05-03 01:15:33.596 - lib.adb - ADB: Android Version: 12.0.
2024-05-02 18:15:33 2024-05-03 01:15:33.596 - lib.adb - ADB: 192.168.50.236 - pm list packages -3
2024-05-02 18:15:33 2024-05-03 01:15:33.662 - lib.adb - ADB: 192.168.50.236 - pidof com.cbs.ott
2024-05-02 18:15:33 2024-05-03 01:15:33.718 - lib.adb - ADB: Stopping media playback.
2024-05-02 18:15:33 2024-05-03 01:15:33.719 - lib.adb - ADB: 192.168.50.236 - input keyevent KEYCODE_MEDIA_STOP
2024-05-02 18:15:33 2024-05-03 01:15:33.790 - root - Using https://www.paramountplus.com/live-tv/stream/showtime-east/ to load channel.
2024-05-02 18:15:33 2024-05-03 01:15:33.791 - lib.adb - ADB: 192.168.50.236 - am start -a android.intent.action.VIEW -d "https://www.paramountplus.com/live-tv/stream/showtime-east/" com.cbs.ott
2024-05-02 18:15:33 2024-05-03 01:15:33.876 - server - Stream debug is enabled. Immediately starting playback for testing purposes.
2024-05-02 18:15:33 Checking for profile screen in background.
2024-05-02 18:15:33 2024-05-03 01:15:33.877 - lib.adb - ADB: Closing connection - 192.168.50.236
2024-05-02 18:15:33 2024-05-03 01:15:33.880 - lib.adb - ADB: Connecting to device (attempt 1).
2024-05-02 18:15:33 2024-05-03 01:15:33.880 - uvicorn.access - 192.168.65.1:26715 - "GET /stream/1/3 HTTP/1.1" 200
2024-05-02 18:15:33 2024-05-03 01:15:33.927 - root - Tuner: Stream open (attempt 1).
2024-05-02 18:15:33 2024-05-03 01:15:33.930 - lib.adb - ADB: Connected.
2024-05-02 18:15:33 2024-05-03 01:15:33.930 - lib.adb - ADB: 192.168.50.236 - dumpsys display
2024-05-02 18:15:33 2024-05-03 01:15:33.988 - httpx - HTTP Request: GET http://192.168.50.207/0.ts "HTTP/1.1 200 OK"
2024-05-02 18:15:33 2024-05-03 01:15:33.990 - lib.adb - ADB: 192.168.50.236 - getprop ro.build.version.release
2024-05-02 18:15:34 2024-05-03 01:15:34.025 - lib.adb - ADB: Android Version: 12.0.
2024-05-02 18:15:34 2024-05-03 01:15:34.070 - lib.adb - Failed to get status from media_session.
2024-05-02 18:15:40 2024-05-03 01:15:40.438 - lib.adb - Checking for profile screen
2024-05-02 18:15:46 2024-05-03 01:15:46.231 - lib.adb - Failed to get status from media_session.
2024-05-02 18:15:47 2024-05-03 01:15:47.342 - lib.adb - Checking for profile screen
2024-05-02 18:15:48 2024-05-03 01:15:48.094 - lib.adb - On screen text: "who's watching? select or create a profile. have kids? keep them safe with kids mode! add profile edit profiles".
2024-05-02 18:15:48 2024-05-03 01:15:48.094 - lib.adb - Matched "who's watching".
2024-05-02 18:15:48 2024-05-03 01:15:48.095 - server - Tuner: Profile screen detected.
2024-05-02 18:15:48 2024-05-03 01:15:48.095 - lib.adb - ADB: 192.168.50.236 - input keyevent KEYCODE_DPAD_CENTER