tbsdtv / linux_media

TBS linux open source drivers
https://github.com/tbsdtv/linux_media/wiki
Other
170 stars 79 forks source link

TBS 5990 does not work on kernel 4.19 when both tuners enabled #161

Open JurajNyiri opened 5 years ago

JurajNyiri commented 5 years ago

Hello, first let me thank you for awesome work here.

Since I started using Unraid 6.7.0 RC6, RC7 and RC8 my TBS 5990 stopped working after switching 7-8 channels. This also only happens, if I am using both tuners on TBS 5990. If I only use 1 tuner, it seems to work well (so far, I will update if I see any issues). I also tried a combination of TBS QBOX-S2 enabled while 1 tuner enabled on TBS 5990 which also works fine. It does not matter which tuner on TBS 5990 is enabled, as far as only 1 is, it works fine.

Unraid 6.7.0 started using kernel 4.19. Tuner works fine on Unraid 6.6.7 which uses kernel 4.18.

Tuners:

TBS 5990 -> Stops working after a while when using both tuners TBS QBOX S2 -> Works

Tuners configuration:

Tune before DiseqC: YES DiseqC repeats:0 Full DiseqC: YES Turn off LNB when idle: NO Higher LNB voltage: Do not set

Enabled: YES Name: name of the tuner Over-the-air EPG: YES Power save: NO Satellite config: 4-Port switch (universal LNB) Master tuner: This tuner Priority: Different priorities per tuner Streaming priority: 0 Initial scan: YES Idle scan: YES Free subscription weight: 10 Linked input: Not linked Maximum PIDs: 32 Allow all PIDs: YES tune repeats: 0 Skip initial bytes: 0 Input buffer (bytes): 188000 Status period (ms): 1000 Signal multiplier: 100 SNR multiplier: 100 Force old status: NO

Sys specs:

CPU: AMD Ryzen 5 2600 Six-Core @ 3400 MHz, 2 cores dedicated to docker RAM: 24 GiB DDR4, 22GB free while testing HDD: 4TB free

How to replicate: Enable both tuners on TBS 5990 with the same settings (as stated above). Switching around 8 channels randomly, waiting around 2-3 sec between a switch - it does not matter which in which order and what channels.

uname -a: root@Tower:~# uname -a Linux Tower 4.19.37-Unraid #1 SMP Tue May 7 20:44:39 BST 2019 x86_64 AMD Ryzen 5 2600 Six-Core Processor AuthenticAMD GNU/Linux

Tried:

SYS LOG 1:

May 10 22:50:48 Tower kernel: cx231xx 1-14:1.1: DVB: adapter 3 frontend 0 frequency 0 out of range (950000..2150000)
May 10 22:50:50 Tower kernel: cx231xx 1-14:1.1: DVB: adapter 2 frontend 0 frequency 0 out of range (950000..2150000)
May 10 22:50:50 Tower kernel: usb 1-11: DVB: adapter 1 frontend 0 frequency 0 out of range (950000..2150000)
May 10 22:50:50 Tower kernel: tbsqboxs2: tbsqboxs2_set_voltage 2
May 10 22:50:51 Tower kernel: usb 3-1: DVB: adapter 0 frontend 0 frequency 0 out of range (174000000..862000000)
May 10 22:51:20 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 22:51:32 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 22:51:45 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 22:52:08 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 22:52:31 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 22:52:39 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 22:52:48 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 22:52:56 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 22:53:05 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 22:53:17 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 22:53:17 Tower kernel: cx231xx 1-14:1.1: submit of urb 4 failed (error=-11) <<<--- I think here it stopped working

SYSLOG 2, lines which contains cx231xx:

May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: New device Turbosight Technolog  @ 480 Mbps (734c:5990) with 8 interfaces
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: Identified as TurboSight TBS 5990 (card=27)
May 10 23:28:22 Tower kernel: cx25840 0-0044: cx23102 A/V decoder found @ 0x88 (cx231xx #0-0)
May 10 23:28:22 Tower kernel: cx25840 0-0044: loaded v4l-cx231xx-avcore-01.fw firmware (16382 bytes)
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: v4l2 driver version 0.0.3
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: Registered video device video0 [v4l2]
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: Registered VBI device vbi0
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: video EndPoint Addr 0x84, Alternate settings: 5
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: VBI EndPoint Addr 0x85, Alternate settings: 2
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: sliced CC EndPoint Addr 0x86, Alternate settings: 2
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: TS EndPoint Addr 0x81, Alternate settings: 6
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: TS EndPoint Addr 0x82, Alternate settings: 6
May 10 23:28:22 Tower kernel: usbcore: registered new interface driver cx231xx
May 10 23:28:22 Tower kernel: dvbdev: DVB: registering new adapter (cx231xx #0)
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: DVB: registering adapter 2 frontend 0 (TurboSight TBS 5990)...
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: TurboSight TBS5s990 MAC Addresse bas: ff:ff:ff:ff:ff:ff
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: TurboSight TBS5990 MAC Addresse bas: ff:ff:ff:ff:ff:00
May 10 23:28:22 Tower kernel: dvbdev: DVB: registering new adapter (cx231xx #0)
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: DVB: registering adapter 3 frontend 0 (TurboSight TBS 5990)...
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: Successfully loaded cx231xx-dvb
May 10 23:28:22 Tower kernel: cx231xx 1-14:1.1: Cx231xx dvb Extension initialized
May 10 23:34:46 Tower kernel: cx231xx 1-14:1.1: DVB: adapter 3 frontend 0 frequency 0 out of range (950000..2150000)
May 10 23:34:48 Tower kernel: cx231xx 1-14:1.1: DVB: adapter 2 frontend 0 frequency 0 out of range (950000..2150000)
May 10 23:35:31 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 23:35:43 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 23:35:51 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 23:36:08 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 23:36:31 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 23:36:37 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 23:36:45 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 23:36:55 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 23:37:03 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 23:37:12 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 23:37:12 Tower kernel: cx231xx 1-14:1.1: unable to allocate 32768 bytes for transfer buffer 1 <<<--- I think here it stopped working
May 10 23:40:32 Tower kernel: cx231xx 1-14:1.1: Unknown tuner type configuring SIF
May 10 23:40:32 Tower kernel: cx231xx 1-14:1.1: unable to allocate 32768 bytes for transfer buffer 0

TVHEADEND LOG 1:

2019-05-10 22:52:07.396 mpegts: 11973V in 23.5E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 22:52:07.860 subscription: 000B: "HTTP" subscribing on channel "Markiza", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", mux: "11973V", provider: "M7 Group", service: "Markiza HD", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 22:52:21.163 subscription: 0012: "HTTP" subscribing on channel "Markiza +1", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", mux: "11973V", provider: "M7 Group", service: "Markiza +1 HD", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 22:52:30.021 mpegts: 11973V in 23.5E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 22:52:30.710 subscription: 0013: "HTTP" subscribing on channel "Markiza International", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", mux: "11973V", provider: "M7 Group", service: "Markiza International", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 22:52:38.402 mpegts: 11919V in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 22:52:39.321 subscription: 0017: "HTTP" subscribing on channel "Megamax", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "11919V", provider: "UPC Direct", service: "Megamax", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 22:52:47.498 mpegts: 11785H in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 22:52:47.960 subscription: 001B: "HTTP" subscribing on channel "Minimax", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "11785H", provider: "DigiTV", service: "Minimax", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 22:52:55.348 mpegts: 11958V in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 22:52:55.795 subscription: 001F: "HTTP" subscribing on channel "Minimax 2", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "11958V", provider: "UPC Direct", service: "Minimax Cz", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 22:53:04.298 mpegts: 11973V in 23.5E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 22:53:04.728 subscription: 0023: "HTTP" subscribing on channel "Mnam TV", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", mux: "11973V", provider: "M7 Group", service: "Mnam TV", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 22:53:15.965 mpegts: 12090V in 23.5E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 22:53:16.618 subscription: 0027: "HTTP" subscribing on channel "National Geographic", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", mux: "12090V", provider: "M7 Group", service: "Nat Geo HD CZ", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 22:53:17.233 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - failed to config dmx for pid 1501 [e=Resource temporarily unavailable]
2019-05-10 22:53:17.985 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - poll TIMEOUT
2019-05-10 22:53:18.667 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - retune nodata
2019-05-10 22:53:25.649 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - poll TIMEOUT
2019-05-10 22:53:25.718 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - retune nodata
...

LOG 2:

2019-05-10 23:06:29.836 mpegts: 11977H in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:06:30.842 subscription: 0002: "epggrab" subscribing to mux "11977H", weight: 4, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", service: "Raw PID Subscription"
2019-05-10 23:06:40.964 mpegts: 11973V in 23.5E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:06:41.689 subscription: 0008: "HTTP" subscribing on channel "Markiza", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", mux: "11973V", provider: "M7 Group", service: "Markiza HD", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:07:01.264 subscription: 000D: "HTTP" subscribing on channel "Markiza +1", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", mux: "11973V", provider: "M7 Group", service: "Markiza +1 HD", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:07:08.421 mpegts: 11973V in 23.5E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:07:08.858 subscription: 000F: "HTTP" subscribing on channel "Markiza International", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", mux: "11973V", provider: "M7 Group", service: "Markiza International", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:07:21.048 mpegts: 11919V in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:07:21.467 subscription: 0014: "HTTP" subscribing on channel "Megamax", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "11919V", provider: "UPC Direct", service: "Megamax", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:07:27.831 mpegts: 11785H in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:07:28.276 subscription: 0019: "HTTP" subscribing on channel "Minimax", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "11785H", provider: "DigiTV", service: "Minimax", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:07:35.253 mpegts: 11958V in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:07:36.196 subscription: 0022: "HTTP" subscribing on channel "Minimax 2", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "11958V", provider: "UPC Direct", service: "Minimax Cz", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:07:43.525 mpegts: 11973V in 23.5E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:07:44.438 subscription: 0027: "HTTP" subscribing on channel "Mnam TV", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", mux: "11973V", provider: "M7 Group", service: "Mnam TV", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:07:52.479 mpegts: 12090V in 23.5E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:07:53.175 subscription: 002C: "HTTP" subscribing on channel "National Geographic", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", mux: "12090V", provider: "M7 Group", service: "Nat Geo HD CZ", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:07:53.794 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - failed to config dmx for pid 1501 [e=Out of memory]
2019-05-10 23:07:54.546 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - poll TIMEOUT
2019-05-10 23:07:58.183 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - retune nodata
2019-05-10 23:08:02.207 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - poll TIMEOUT
2019-05-10 23:08:03.239 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - retune nodata
...

LOG 3:

2019-05-10 23:21:26.494 mpegts: 11973V in 19.2E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:21:27.410 subscription: 0003: "epggrab" subscribing to mux "11973V", weight: 4, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "19.2E", service: "Raw PID Subscription"
2019-05-10 23:21:39.531 mpegts: 10716H in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:21:39.949 subscription: 0007: "epggrab" subscribing to mux "10716H", weight: 4, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", service: "Raw PID Subscription"
2019-05-10 23:21:43.706 mpegts: 11919V in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:21:44.179 subscription: 000B: "HTTP" subscribing on channel "AMC", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "11919V", provider: "UPC Direct", service: "AMC CE", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:22:02.877 mpegts: 12092H in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:22:03.829 subscription: 0010: "HTTP" subscribing on channel "AXN Black", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "12092H", provider: "ESS", service: "AXN Black SVK", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:22:13.196 subscription: 0017: "HTTP" subscribing on channel "AXN Czech", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "12092H", provider: "ESS", service: "AXN Czech", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:22:19.534 mpegts: 12092H in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:22:20.199 subscription: 0018: "HTTP" subscribing on channel "AXN White", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "12092H", provider: "ESS", service: "AXN White SVK", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:22:28.369 mpegts: 11842.56V in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:22:28.815 subscription: 001C: "HTTP" subscribing on channel "Animal Planet", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "11842.56V", provider: "UPC Direct", service: "Animal Planet HD", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:22:41.318 mpegts: 12363V in 23.5E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:22:42.221 subscription: 0020: "HTTP" subscribing on channel "Antena Rock", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", mux: "12363V", provider: "Towercom", service: "Antena Rock", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:22:49.783 mpegts: 12034.36V in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:22:50.684 subscription: 0024: "HTTP" subscribing on channel "Arena Sport", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "12034.36V", provider: "UPC Direct", service: "Arena Sport 1 HD", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:22:51.316 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - failed to config dmx for pid 350 [e=Resource temporarily unavailable]
2019-05-10 23:22:52.068 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - poll TIMEOUT
2019-05-10 23:22:52.740 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - retune nodata
2019-05-10 23:22:59.726 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - poll TIMEOUT
2019-05-10 23:22:59.790 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - retune nodata
...

LOG 4:

2019-05-10 23:35:42.411 mpegts: 11973V in 19.2E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:35:43.342 subscription: 0003: "epggrab" subscribing to mux "11973V", weight: 4, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "19.2E", service: "Raw PID Subscription"
2019-05-10 23:35:50.075 mpegts: 12034.36V in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:35:50.510 subscription: 0007: "HTTP" subscribing on channel "Arena Sport", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "12034.36V", provider: "UPC Direct", service: "Arena Sport 1 HD", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:36:06.958 mpegts: 12090V in 23.5E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:36:07.887 subscription: 000C: "HTTP" subscribing on channel "National Geographic", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", mux: "12090V", provider: "M7 Group", service: "Nat Geo HD CZ", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:36:30.400 mpegts: 11973V in 23.5E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:36:30.823 subscription: 0015: "HTTP" subscribing on channel "Markiza", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", mux: "11973V", provider: "M7 Group", service: "Markiza HD", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:36:36.824 mpegts: 11973V in 23.5E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:36:37.251 subscription: 001A: "HTTP" subscribing on channel "Markiza +1", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", mux: "11973V", provider: "M7 Group", service: "Markiza +1 HD", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:36:44.328 mpegts: 11973V in 23.5E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:36:45.016 subscription: 001F: "HTTP" subscribing on channel "Markiza International", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", mux: "11973V", provider: "M7 Group", service: "Markiza International", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:36:54.866 mpegts: 11919V in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:36:55.285 subscription: 0024: "HTTP" subscribing on channel "Megamax", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "11919V", provider: "UPC Direct", service: "Megamax", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:37:02.111 mpegts: 11785H in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:37:03.063 subscription: 0029: "HTTP" subscribing on channel "Minimax", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "11785H", provider: "DigiTV", service: "Minimax", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:37:10.557 mpegts: 11958V in 0.8W - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-10 23:37:11.512 subscription: 002E: "HTTP" subscribing on channel "Minimax 2", weight: 100, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "0.8W", mux: "11958V", provider: "UPC Direct", service: "Minimax Cz", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-10 23:37:12.118 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - failed to config dmx for pid 500 [e=Out of memory]
2019-05-10 23:37:12.869 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - poll TIMEOUT
2019-05-10 23:37:13.548 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - retune nodata
2019-05-10 23:37:20.527 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - poll TIMEOUT
2019-05-10 23:37:20.589 linuxdvb: TurboSight TBS 5990 #3 : DVB-S #0 - retune nodata
...

LOG 5:

2019-05-11 00:06:02.280 linuxdvb: TurboSight TBS 5990 #2 : DVB-S #0 - failed to config dmx for pid 18 [e=Out of memory]
2019-05-11 00:06:02.280 mpegts: 12090V in 23.5E - tuning on TurboSight TBS 5990 #3 : DVB-S #0
2019-05-11 00:06:02.951 subscription: 0052: "epggrab" subscribing to mux "12090V", weight: 4, adapter: "TurboSight TBS 5990 #3 : DVB-S #0", network: "23.5E", service: "Raw PID Subscription"
2019-05-11 00:06:03.031 linuxdvb: TurboSight TBS 5990 #2 : DVB-S #0 - poll TIMEOUT
2019-05-11 00:06:03.969 linuxdvb: TurboSight TBS 5990 #2 : DVB-S #0 - retune nodata
2019-05-11 00:06:10.689 linuxdvb: TurboSight TBS 5990 #2 : DVB-S #0 - poll TIMEOUT
2019-05-11 00:06:11.050 linuxdvb: TurboSight TBS 5990 #2 : DVB-S #0 - retune nodata
2019-05-11 00:06:12.981 subscription: 0051: service instance is bad, reason: No input detected
2019-05-11 00:06:12.982 mpegts: 12054H in 0.8W - tuning on TurboSight TBS 5990 #2 : DVB-S #0
2019-05-11 00:06:13.502 subscription: 0051: "HTTP" subscribing on channel "Markiza", weight: 100, adapter: "TurboSight TBS 5990 #2 : DVB-S #0", network: "0.8W", mux: "12054H", provider: "Slovak Telekom", service: "Markiza HD", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-11 00:06:14.655 linuxdvb: TurboSight TBS 5990 #2 : DVB-S #0 - poll TIMEOUT
2019-05-11 00:06:15.556 linuxdvb: TurboSight TBS 5990 #2 : DVB-S #0 - retune nodata
2019-05-11 00:06:21.953 webui: Stop streaming /stream/channel/411aad88e3579050300041f8c8142192?ticket=74660ab27248b798ea4e288e992be3d9af29b945, timeout waiting for packets
2019-05-11 00:06:21.953 subscription: 0051: "HTTP" unsubscribing from "Markiza", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-11 00:06:21.970 http: 192.168.100.238: using ticket 74660ab27248b798ea4e288e992be3d9af29b945 for /stream/channel/411aad88e3579050300041f8c8142192
2019-05-11 00:06:21.970 mpegts: 11973V in 23.5E - tuning on TurboSight TBS 5990 #2 : DVB-S #0
2019-05-11 00:06:22.480 subscription: 0057: "HTTP" subscribing on channel "Markiza", weight: 100, adapter: "TurboSight TBS 5990 #2 : DVB-S #0", network: "23.5E", mux: "11973V", provider: "M7 Group", service: "Markiza HD", profile="pass", hostname="192.168.100.238", username="username", client="VLC/3.0.4 LibVLC/3.0.4"
2019-05-11 00:06:23.623 linuxdvb: TurboSight TBS 5990 #2 : DVB-S #0 - poll TIMEOUT
2019-05-11 00:06:24.498 linuxdvb: TurboSight TBS 5990 #2 : DVB-S #0 - retune nodata

...

Please let me know how can I help debug the issue further and thank you for any help.

crazycat69 commented 5 years ago

This some related to usb host driver or cx231xx core part.

JurajNyiri commented 5 years ago

Thank you for quick response, if I understand correctly you are saying this is not related to drivers? Who should I then please report this to?

JurajNyiri commented 4 years ago

Hello,

has there been any progress on this? Can I help to debug this further? How can I help?

Thank you very much

smallint commented 4 years ago

I just want to jump in here as I am now also trying to get my TBS5990 up and running on Arch with a Raspberry Pi4. Lets say, it works to some extent. Let me give some historic background:

Some years ago I started with the TBS5900 connected to an iMX6 device and Linux support for ARM devices was zero at that time. I discovered the Github repo from @crazycat69 and started to use that code which worked OK but did not support the 2nd adapter at all and wasn't pretty stable. So we discussed that issues in a very long thread (which is lost unfortunately because the old repo was deleted) and figured out how to enable the second adapter. in my personal setup I got two adapter working reliably. They have been running for several year now with kernel 3.14 (I know).

As the current code does not run with the 2nd adapter (no chance at all) and produces burst sending timeout I ported my old working code to the new kernel (4.19.) just to see if it is related to some updates in this repo. And it did not work with respect to the 2nd adapter. That leads me to the conclusion that things must have changed on the kernel side (probably i2c or Pi4 usb subsystem).

The good thing is I know that it is possible to run both adapters on an ARM device. It is still working in my setup. I will test the current driver on an x86 just to know if it is possible at all to get the second adapter working.

Btw, bulk transfer is pretty unstable also with the first adapter. I enabled ISO and although I get some artifacts while switching channels, everything works stable and without tuning timeouts.

And to come back to your issue: it is hard to say what the underlying issue is without testing. And even testing is difficult as I don't know what to test actually. I am neither a kernel dev nor a hardware expert so I can't tell you where to continue digging. As I understood this driver development it is more of a reverse engineering effort than implementing a spec. Maybe switching to ISO transfer helps in your case. Bulk transfer has shown similar symptoms as yours.

P.S. Why did I write so much? Because I am going to keep working on the ARM issue (more trial and error) and maybe @crazycat69 has some idea what I could test or try to get the 2nd adapter working. It is an update of my current findings and the expression of the desire to solve the issue and to get some help ;)

smallint commented 4 years ago

I did some further checks and maybe that helps in your case as well. Enabling bulk transfer results in those debug messages from time to time:

cx231xx #0 cx231xx_bulk_irq_callback :urb completion error - device is stalled.

After some time it recovers and works again for a while. You can enable the debug output as module option for cx231xx:

options cx231xx core_debug=1
JurajNyiri commented 4 years ago

Thank you @smallint for your advice

I would try it but I am not sure how I would add this into Unraid since changes are not persistent between reboots. I would probably have to build it somehow on my own and I haven't yet looked into it.

smallint commented 4 years ago

I have finally solved the issue for my installation with ArchLinux and a RPi4. Rather than compiling the whole V4L tree with this repo I extracted the affected source changes and created a standalone package with just builds the required modules for the host kernel to support the TBS 5990. Now both tuners are working nicely. All the code is in my repository at https://github.com/smallint/tbs-usb.

I tested a lot and at some point the drivers even did not work anymore on my x86 box. After some time I just restarted the TBS box and forced a cold start to reload the firmware. Then it worked again and also the RPi4 worked with both tuners. The nice thing about the stripped down repository is that is takes just a couple of seconds to build after a kernel update. And replacing the entire V4L tree prevented some RPi4 modules to load. This is also resolved. So far I am glad that it works finally. There is still an open issue with USB bulk transfer but that is independent of the TBS drivers. It seems to be a RPi4 kernel issue. I tested the modules with kernel 4.19 and 5.2.

@JurajNyiri maybe a cold boot of the TBS device might also help in your situation.

JurajNyiri commented 4 years ago

A bit of update. I am trying to migrate to RPI3B+ with latest libreleec with tbs drivers.

  1. Installed libreelec
  2. Enabled TBS drivers
  3. Enabled tvheadend
  4. Tuner is found

When trying to use both tuners at the same time, the other one always drops with retune nodata/poll TIMEOUT and the Unknown tuner type configuring SIF.

This is almost resolved by putting

options cx231xx transfer_mode=1
options disable infrared remote support

into the /storage/.config/modprobe.d/cx231xx.conf . (Second line probably not needed)

Now, when I stream from both tuners, both streams start artifacting with the Continuity counter error in tvheadend and no errors in dmesg (even with debug enabled), but they do not drop.