Skip to contentSkip to conversation

si2168/dvbsky - blind-scan for DVB-T2 with PLP fails

DISCUSSION Hurda 3 participants 9 messages May 27, 2015 – Jun 16, 2015 Media (V4L/DVB)

lore
Share & tools
lore

Hurda

author
#0 lore raw

Hello.

I think I came across a bug in either of the drivers si2168 and dvbsky regarding blind-scanning DVB-T2-frequencies.

HW: Technotrend CT2-4400v2 (afaik based on or the same as DVBSky T330)

    demod: Si2168-B40
    tuner: Si2158-A20

OS: Ubuntu 15.04 (kernel 3.19)

In Austria, the DVB-T2-service "SimpliTV" is currently airing up to four muxes, next to one or two DVB-T-muxes.
In my region, the frequencies are 490MHz, 546MHz, 690MHz, 714MHz for DVB-T2, and 498MHz for DVB-T.
These numbers might be of interest when reading the logs.

The peculiar aspect of these T2-muxes is that they're aired on PLP 1 without there being a PLP 0. I think this is also the root of my problem.

When doing a blind-scan using w_scan 20140727 on Ubuntu 15.04 (kernel 3.19), w_scan does not find any of these four DVB-T2-muxes.
It just finds the DVB-T-mux.

Logs:
media-tree_dmesg_lsusb.txt http://pastebin.com/0ixFPMSA
media-tree_w_scan.txt http://pastebin.com/yyG3jSwj

The found transponder:
initial_v3_media_build_trunk.conf http://pastebin.com/LmFQavpy
initial_v5.conf http://pastebin.com/Jx6kymVt

I also tried a fresh checkout from git.linuxtv.org as of last weekend and the most recent w_scan version (20141122).

As you can see, w_scan tries to tune(?) the DVB-T2-frequencies, but ultimately doesn't find anything on them.

Then I tried the DVBSky-linux-driver[1] (media_build-bst-20150322.tar.gz)[2] from their site, which is using a binary called sit2 for this card. Using this driver, w_scan found all four DVB-T2-muxes and the DVB-T-mux. Additionally, it found the DVB-T2-muxes during the DVB-T-scan.

Logs:
media_build-bst_dmesg_lsusb.txt http://pastebin.com/vJeDMxtu
media_build-bst_w_scan.txt http://pastebin.com/yhwAYjen

Found transponders:
initial_v3_bst.conf http://pastebin.com/ECKQvRWX
initial_v5_bst.conf http://pastebin.com/CbhY6Hpz

Of course, doing a channel-scan using dvbv5-scan on these transponders worked too:

dvbv5_sit2.conf http://pastebin.com/3W52bbhv
dvbv5_sit2.log http://pastebin.com/nc66PTkt

Afterwards, I tried to do a channel-scan with the same initial tuning-file using the opensource-driver, which also worked:

dvbv5_si2168.conf http://pastebin.com/A6FbqUL1
dvbv5_si2168.log http://pastebin.com/ewyVPJR2

This should verify that tuning PLP 1 without there being PLP 0 is not the issue.

Additionally, if you compare the two channel-lists, you find interesting differences:

The scan with si2168 has AUTO for "MODULATION" and "INVERSION" for DVB-T2-channels, and for "CODE_RATE_LP" and "INVERSION" for DVB-T-channels.

The scan with sit2 has the respective values in the channel-list.

The dvbv5-scan-logs also differ, as using sit2 also displays the signal quality during tuning.

I know that there were changes regarding DVB-T2-scanning[3], but as the blog- article specifically mentions si2168 and w_scan to be fully dvbv5-compliant and good for using with DVB-T2, I thought you should know about this particular problem.

In the attachment I've packed the previously linked logs, for archival reasons.

Thank you for your attention.

[1] http://www.dvbsky.net/Support_linux.html
[2] http://www.dvbsky.net/download/linux/media_build-bst-150322.tar.gz
[3] http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html

PS: Interesting comments regarding auto-detection for si2168:
http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427233615765#c8591459871945922951
http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427234034259#c6500661729983566638

#1 lore raw
Quoted 18 lines · Hurda

Hello.

I think I came across a bug in either of the drivers si2168 and dvbsky regarding
blind-scanning DVB-T2-frequencies.

HW: Technotrend CT2-4400v2 (afaik based on or the same as DVBSky T330)

     demod: Si2168-B40
     tuner: Si2158-A20

OS: Ubuntu 15.04 (kernel 3.19)

In Austria, the DVB-T2-service "SimpliTV" is currently airing up to four muxes, next to one or two DVB-T-muxes.
In my region, the frequencies are 490MHz, 546MHz, 690MHz, 714MHz for DVB-T2,
and 498MHz for DVB-T.
These numbers might be of interest when reading the logs.

Quoted 3 lines

The peculiar aspect of these T2-muxes is that they're aired on PLP 1 without
there being a PLP 0. I think this is also the root of my problem.

dvbv5-scan is working, but w_scan not?

Could you hack si2168.c file and test?

if (c->delivery_system == SYS_DVBT2) {
	/* select PLP */
	cmd.args[0] = 0x52;
	cmd.args[1] = c->stream_id & 0xff;
//	cmd.args[2] = c->stream_id == NO_STREAM_ID_FILTER ? 0 : 1;
	cmd.args[2] = 0;
	cmd.wlen = 3;
	cmd.rlen = 1;
	ret = si2168_cmd_execute(client, &cmd);
	if (ret)
		goto err;
}

Antti

Quoted 89 lines

When doing a blind-scan using w_scan 20140727 on Ubuntu 15.04 (kernel 3.19),
w_scan does not find any of these four DVB-T2-muxes.
It just finds the DVB-T-mux.

Logs:
media-tree_dmesg_lsusb.txt http://pastebin.com/0ixFPMSA
media-tree_w_scan.txt http://pastebin.com/yyG3jSwj

The found transponder:
initial_v3_media_build_trunk.conf http://pastebin.com/LmFQavpy
initial_v5.conf http://pastebin.com/Jx6kymVt

I also tried a fresh checkout from git.linuxtv.org as of last weekend and the
most recent w_scan version (20141122).

As you can see, w_scan tries to tune(?) the DVB-T2-frequencies, but ultimately doesn't find anything on them.

Then I tried the DVBSky-linux-driver[1] (media_build-bst-20150322.tar.gz)[2]
from their site, which is using a binary called sit2 for this card. Using this driver, w_scan found all four DVB-T2-muxes and the DVB-T-mux. Additionally, it found the DVB-T2-muxes during the DVB-T-scan.

Logs:
media_build-bst_dmesg_lsusb.txt http://pastebin.com/vJeDMxtu
media_build-bst_w_scan.txt http://pastebin.com/yhwAYjen

Found transponders:
initial_v3_bst.conf http://pastebin.com/ECKQvRWX
initial_v5_bst.conf http://pastebin.com/CbhY6Hpz

Of course, doing a channel-scan using dvbv5-scan on these transponders worked
too:

dvbv5_sit2.conf http://pastebin.com/3W52bbhv
dvbv5_sit2.log http://pastebin.com/nc66PTkt

Afterwards, I tried to do a channel-scan with the same initial tuning-file using the opensource-driver, which also worked:

dvbv5_si2168.conf http://pastebin.com/A6FbqUL1
dvbv5_si2168.log http://pastebin.com/ewyVPJR2

This should verify that tuning PLP 1 without there being PLP 0 is not the issue.

Additionally, if you compare the two channel-lists, you find interesting differences:

The scan with si2168 has AUTO for "MODULATION" and "INVERSION" for DVB-T2-channels, and for "CODE_RATE_LP" and "INVERSION" for DVB-T-channels.

The scan with sit2 has the respective values in the channel-list.

The dvbv5-scan-logs also differ, as using sit2 also displays the signal quality
during tuning.

I know that there were changes regarding DVB-T2-scanning[3], but as the blog-
article specifically mentions si2168 and w_scan to be fully dvbv5-compliant and good for using with DVB-T2, I thought you should know about this particular problem.

In the attachment I've packed the previously linked logs, for archival reasons.

Thank you for your attention.

[1] http://www.dvbsky.net/Support_linux.html
[2] http://www.dvbsky.net/download/linux/media_build-bst-150322.tar.gz
[3] http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html

PS: Interesting comments regarding auto-detection for si2168:
http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427233615765#c8591459871945922951

http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427234034259#c6500661729983566638

Signature · 1 line
http://palosaari.fi/
author
#2 lore raw
Quoted 40 lines · Antti Palosaari
Quoted 18 lines · Hurda

Hello.

I think I came across a bug in either of the drivers si2168 and dvbsky regarding
blind-scanning DVB-T2-frequencies.

HW: Technotrend CT2-4400v2 (afaik based on or the same as DVBSky T330)

     demod: Si2168-B40
     tuner: Si2158-A20

OS: Ubuntu 15.04 (kernel 3.19)

In Austria, the DVB-T2-service "SimpliTV" is currently airing up to four muxes, next to one or two DVB-T-muxes.
In my region, the frequencies are 490MHz, 546MHz, 690MHz, 714MHz for DVB-T2,
and 498MHz for DVB-T.
These numbers might be of interest when reading the logs.

Quoted 3 lines

The peculiar aspect of these T2-muxes is that they're aired on PLP 1 without
there being a PLP 0. I think this is also the root of my problem.

dvbv5-scan is working, but w_scan not?

Could you hack si2168.c file and test?

if (c->delivery_system == SYS_DVBT2) {
    /* select PLP */
    cmd.args[0] = 0x52;
    cmd.args[1] = c->stream_id & 0xff;
//    cmd.args[2] = c->stream_id == NO_STREAM_ID_FILTER ? 0 : 1;
    cmd.args[2] = 0;
    cmd.wlen = 3;
    cmd.rlen = 1;
    ret = si2168_cmd_execute(client, &cmd);
    if (ret)
        goto err;
}
Quoted 1 line

Antti

si2168_0.log http://pastebin.com/wPjZ82uc

The scan only finds one of the four transponders (714MHz), but it doesn't end up in the tuning-file. The other three are tuned, but not locked.

Quoted 82 lines
Quoted 82 lines

When doing a blind-scan using w_scan 20140727 on Ubuntu 15.04 (kernel 3.19),
w_scan does not find any of these four DVB-T2-muxes.
It just finds the DVB-T-mux.

Logs:
media-tree_dmesg_lsusb.txt http://pastebin.com/0ixFPMSA
media-tree_w_scan.txt http://pastebin.com/yyG3jSwj

The found transponder:
initial_v3_media_build_trunk.conf http://pastebin.com/LmFQavpy
initial_v5.conf http://pastebin.com/Jx6kymVt

I also tried a fresh checkout from git.linuxtv.org as of last weekend and the
most recent w_scan version (20141122).

As you can see, w_scan tries to tune(?) the DVB-T2-frequencies, but ultimately doesn't find anything on them.

Then I tried the DVBSky-linux-driver[1] (media_build-bst-20150322.tar.gz)[2]
from their site, which is using a binary called sit2 for this card. Using this driver, w_scan found all four DVB-T2-muxes and the DVB-T-mux. Additionally, it found the DVB-T2-muxes during the DVB-T-scan.

Logs:
media_build-bst_dmesg_lsusb.txt http://pastebin.com/vJeDMxtu
media_build-bst_w_scan.txt http://pastebin.com/yhwAYjen

Found transponders:
initial_v3_bst.conf http://pastebin.com/ECKQvRWX
initial_v5_bst.conf http://pastebin.com/CbhY6Hpz

Of course, doing a channel-scan using dvbv5-scan on these transponders worked
too:

dvbv5_sit2.conf http://pastebin.com/3W52bbhv
dvbv5_sit2.log http://pastebin.com/nc66PTkt

Afterwards, I tried to do a channel-scan with the same initial tuning-file using the opensource-driver, which also worked:

dvbv5_si2168.conf http://pastebin.com/A6FbqUL1
dvbv5_si2168.log http://pastebin.com/ewyVPJR2

This should verify that tuning PLP 1 without there being PLP 0 is not the issue.

Additionally, if you compare the two channel-lists, you find interesting differences:

The scan with si2168 has AUTO for "MODULATION" and "INVERSION" for DVB-T2-channels, and for "CODE_RATE_LP" and "INVERSION" for DVB-T-channels.

The scan with sit2 has the respective values in the channel-list.

The dvbv5-scan-logs also differ, as using sit2 also displays the signal quality
during tuning.

I know that there were changes regarding DVB-T2-scanning[3], but as the blog-
article specifically mentions si2168 and w_scan to be fully dvbv5-compliant and good for using with DVB-T2, I thought you should know about this particular problem.

In the attachment I've packed the previously linked logs, for archival reasons.

Thank you for your attention.

[1] http://www.dvbsky.net/Support_linux.html
[2] http://www.dvbsky.net/download/linux/media_build-bst-150322.tar.gz
[3] http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html

Quoted 8 lines
Quoted 7 lines

PS: Interesting comments regarding auto-detection for si2168:
http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427233615765#c8591459871945922951

http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427234034259#c6500661729983566638

blah@blah:~$ w_scan -ft -cat -vvv -F -x > si2168_0.conf
w_scan -ft -cat -vvv -F -x 
w_scan version 20141122 (compiled for DVB API 5.10)
using settings for AUSTRIA
DVB aerial
DVB-T Europe
scan type TERRESTRIAL, channellist 4
output format initial tuning data
WARNING: could not guess your codepage. Falling back to 'UTF-8'
output charset 'UTF-8', use -C <charset> to override
Info: using DVB adapter auto detection.
   check Silicon Labs Si2168:
           DVB-C ann.A
           DVB-T2
           DVB-T
	/dev/dvb/adapter0/frontend0 -> TERRESTRIAL "Silicon Labs Si2168": very good :-))

Using TERRESTRIAL frontend (adapter /dev/dvb/adapter0/frontend0) -_-_-_-_ Getting frontend capabilities-_-_-_-_
Using DVB API 5.10
frontend 'Silicon Labs Si2168' supports
DVB-T2
INVERSION_AUTO
QAM_AUTO
TRANSMISSION_MODE_AUTO
GUARD_INTERVAL_AUTO
HIERARCHY_AUTO
FEC_AUTO
FREQ (55.00MHz ... 862.00MHz)
-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
check Silicon Labs Si2168:

           DVB-C ann.A
           DVB-T2
           DVB-T

Scanning DVB-T...
Scanning 7MHz frequencies...
177500: (time: 00:00.015)
184500: (time: 00:02.047)
191500: (time: 00:04.075)
198500: (time: 00:06.107)
205500: (time: 00:08.131)
212500: (time: 00:10.159)
219500: (time: 00:12.187)
226500: (time: 00:14.219)
Scanning 8MHz frequencies...
474000: (time: 00:16.243)
482000: (time: 00:18.271)
490000: (time: 00:20.303)
498000: (time: 00:22.331)

        (0.360sec): SCL (0x1F)
        (0.360sec) signal
        (0.360sec) lock
        signal ok:	QAM_AUTO f = 498000 kHz I999B8C999D999T999G999Y999 (0:0:0)
        initial PAT lookup..
PAT (xxxx:xxxx:600)
	===================== parse_pat ========================================
	len = 16
	0x00: 27 75 E2 59 27 84 E2 5A 27 98 E2 5B 27 A6 E2 5F : 'u Y'  Z'  ['  _
	========================================================================
        QAM_AUTO f = 498000 kHz I999B8C999D999T999G999Y999 (0:0:0) : updating transport_stream_id: -> (0:0:600)
          check_duplicate_transponders()
          ================= list_transponders() =======================
          new_transponders(000): QAM_AUTO f = 498000 kHz I999B8C999D999T999G999Y999 (0:0:600)
          =============================================================
        initial NIT lookup..
NIT(act): (xxxx:13200:xxxx)
	===================== parse_nit ========================================
	len = 77
	0x00: F0 0E 40 0C 4F 52 53 20 44 56 42 2D 54 20 4B 54 :   @ ORS DVB-T KT
	0x10: F0 3B 02 58 20 28 F0 35 5A 0B 05 1D 34 40 1F 42 :  ; X ( 5Z   4@ B
	0x20: 5B FF FF FF FF 5A 0B 03 7E 2A 40 1F 42 5B FF FF : [    Z  ~*@ B[  
	0x30: FF FF 5A 0B 02 F7 E3 40 1F 42 5B FF FF FF FF 8B :   Z    @ B[     
	0x40: 0C 27 75 C0 32 27 84 C0 3A 27 98 C0 38          :  'u 2'  :'  8
	========================================================================
        QAM_AUTO f = 498000 kHz I999B8C999D999T999G999Y999 (0:0:600) : updating network_id -> (0:13200:600)
          check_duplicate_transponders()
          ================= list_transponders() =======================
          new_transponders(000): QAM_AUTO f = 498000 kHz I999B8C999D999T999G999Y999 (0:13200:600)
          =============================================================
        ----------------------------------------------------------
        NIT(act): (8232:13200:600)
	find_transponder(0:13200:600):          -> found 'new_transponders(000)'  QAM_AUTO f = 498000 kHz I999B8C999D999T999G999Y999 (0:13200:600)
        QAM_AUTO f = 498000 kHz I999B8C999D999T999G999Y999 (0:13200:600) : updating original_network_id -> (8232:13200:600)
          ================= list_transponders() =======================
          new_transponders(000): QAM_AUTO f = 498000 kHz I999B8C999D999T999G999Y999 (8232:13200:600)
          =============================================================
	===================== parse_terrestrial_delivery_system_descriptor =====
	len = 11
	0x00: 05 1D 34 40 1F 42 5B FF FF FF FF                :   4@ B[    
	========================================================================
          F498000 B8 M16 C34 D999 G4 T8 other_frequency=1 (858000000)
          1 frequencies
             858000000
	===================== parse_terrestrial_delivery_system_descriptor =====
	len = 11
	0x00: 03 7E 2A 40 1F 42 5B FF FF FF FF                :  ~*@ B[    
	========================================================================
          F498000 B8 M16 C34 D999 G4 T8 other_frequency=1 (586000000)
          2 frequencies
             858000000
             586000000
	===================== parse_terrestrial_delivery_system_descriptor =====
	len = 11
	0x00: 02 F7 E3 40 1F 42 5B FF FF FF FF                :    @ B[    
	========================================================================
          F498000 B8 M16 C34 D999 G4 T8 other_frequency=1 (498000000)
          3 frequencies
             858000000
             586000000
             498000000
	find_transponder(8232:13200:600):          -> found 'new_transponders(000)'  QAM_AUTO f = 498000 kHz I999B8C999D999T999G999Y999 (8232:13200:600)
        updating transponder:
           (QAM_AUTO f = 498000 kHz I999B8C999D999T999G999Y999 (8232:13200:600)) 0x0000
        to (QAM_16   f = 498000 kHz I999B8C34D0T8G4Y0 (8232:13200:600)) 0x405A
           cell id 0, freq = 858000000
           cell id 0, freq = 586000000
           cell id 0, freq = 498000000
          ================= list_transponders() =======================
          new_transponders(000): QAM_16   f = 498000 kHz I999B8C34D0T8G4Y0 (8232:13200:600)
          =============================================================
506000: (time: 00:32.359) 
514000: (time: 00:34.387) 
522000: (time: 00:36.415) 
        (0.360sec): SC (0x3)
        (0.360sec) signal
530000: (time: 00:36.827) 
        (0.368sec): SC (0x3)
        (0.368sec) signal

538000: (time: 00:37.251)
546000: (time: 00:39.271)
554000: (time: 00:41.303)
562000: (time: 00:43.335)
570000: (time: 00:45.359)
578000: (time: 00:47.391)
586000: (time: 00:49.415)
594000: (time: 00:51.447)
602000: (time: 00:53.475)

        (0.364sec): SC (0x3)
        (0.364sec) signal

610000: (time: 00:53.887)
618000: (time: 00:55.919)
626000: (time: 00:57.947)
634000: (time: 00:59.971)
642000: (time: 01:01.995)
650000: (time: 01:04.019)

        (0.368sec): SC (0x3)
        (0.368sec) signal
        (0.472sec):  (0x0)
        (0.844sec): SC (0x3)
        (0.984sec):  (0x0)
        (1.296sec): SC (0x3)
        (1.404sec):  (0x0)
        (1.720sec): SC (0x3)
        (1.824sec):  (0x0)
        (2.244sec): SC (0x3)
        (2.352sec):  (0x0)
        (2.612sec): SC (0x3)
        (2.720sec):  (0x0)
        (3.172sec): SC (0x3)
        (3.272sec):  (0x0)
        (3.540sec): SC (0x3)
        (3.640sec):  (0x0)
        (4.116sec): SC (0x3)
        (4.224sec):  (0x0)

658000: (time: 01:08.451)
666000: (time: 01:10.471)
674000: (time: 01:12.503)
682000: (time: 01:14.535)
690000: (time: 01:16.559)
698000: (time: 01:18.587)
706000: (time: 01:20.615)
714000: (time: 01:22.639)
722000: (time: 01:24.667)

        (0.468sec): SC (0x3)
        (0.468sec) signal

730000: (time: 01:25.187)
738000: (time: 01:27.219)
746000: (time: 01:29.243)
754000: (time: 01:31.271)
762000: (time: 01:33.299)
770000: (time: 01:35.323)
778000: (time: 01:37.355)
786000: (time: 01:39.383)
794000: (time: 01:41.407)
802000: (time: 01:43.435)
810000: (time: 01:45.467)
818000: (time: 01:47.495)
826000: (time: 01:49.519)
834000: (time: 01:51.547)
842000: (time: 01:53.579)
850000: (time: 01:55.603)
858000: (time: 01:57.631)
Scanning DVB-T2...
Scanning 7MHz frequencies...
177500: (time: 01:59.663)
184500: (time: 02:01.695)
191500: (time: 02:03.719)
198500: (time: 02:05.747)
205500: (time: 02:07.783)
212500: (time: 02:09.811)
219500: (time: 02:11.839)
226500: (time: 02:13.875)
Scanning 8MHz frequencies...
474000: (time: 02:15.899)
482000: (time: 02:17.931)
490000: (time: 02:19.967)

        (0.208sec): SC (0x3)
        (0.208sec) signal

498000: skipped (already known transponder)
506000: (time: 02:20.227)
514000: (time: 02:22.259)
522000: (time: 02:24.295)
530000: (time: 02:26.323)
538000: (time: 02:28.355)
546000: (time: 02:30.383)

        (0.316sec): SC (0x3)
        (0.316sec) signal
554000: (time: 02:30.755) 
        (0.260sec): SC (0x3)
        (0.260sec) signal

562000: (time: 02:31.063)
570000: (time: 02:33.099)
578000: (time: 02:35.127)
586000: (time: 02:37.159)
594000: (time: 02:39.191)
602000: (time: 02:41.227)
610000: (time: 02:43.259)
618000: (time: 02:45.295)
626000: (time: 02:47.327)
634000: (time: 02:49.359)
642000: (time: 02:51.387)
650000: (time: 02:53.419)
658000: (time: 02:55.459)
666000: (time: 02:57.487)
674000: (time: 02:59.519)

        (0.208sec): SC (0x3)
        (0.208sec) signal
682000: (time: 02:59.779) 
690000: (time: 03:01.807) 
        (0.212sec): SC (0x3)
        (0.212sec) signal
698000: (time: 03:02.071) 
706000: (time: 03:04.107) 
714000: (time: 03:06.135) 
        (0.260sec): SC (0x3)
        (0.260sec) signal
        (0.472sec): SCL (0x1F)
        (0.472sec) lock
        signal ok:	QAM_AUTO f = 714000 kHz I999B8C999D999T999G999Y999P0 (0:0:0)
        initial PAT lookup..
PAT (xxxx:xxxx:2003)
	===================== parse_pat ========================================
	len = 44
	0x00: 00 00 E0 10 30 0D E1 4B 30 0E E1 4C 30 0F E1 4D :     0  K0  L0  M
	0x10: 30 10 E1 4E 30 11 E1 4F 30 12 E1 50 30 13 E1 51 : 0  N0  O0  P0  Q
	0x20: 30 14 E1 52 30 16 E1 54 30 17 E1 55             : 0  R0  T0  U
	========================================================================
        QAM_AUTO f = 714000 kHz I999B8C999D999T999G999Y999P0 (0:0:0) : updating transport_stream_id: -> (0:0:2003)
          check_duplicate_transponders()
          ================= list_transponders() =======================
          new_transponders(000): QAM_16   f = 498000 kHz I999B8C34D0T8G4Y0 (8232:13200:600)
          new_transponders(001): QAM_AUTO f = 714000 kHz I999B8C999D999T999G999Y999P0 (0:0:2003)
          =============================================================
        initial NIT lookup..
NIT(act): (xxxx:12003:xxxx)
	===================== parse_nit ========================================
	len = 161
	0x00: F0 0E 40 0C 44 56 42 2D 54 32 20 4D 55 58 20 46 :   @ DVB-T2 MUX F
	0x10: F0 8F 07 D3 20 28 F0 89 7F 06 04 01 20 28 03 36 :      (       ( 6
	0x20: 62 21 FF 04 35 45 40 02 DF 79 40 02 F7 E3 40 04 : b!  5E@  y@   @ 
	0x30: 72 4E 40 04 59 E4 40 04 41 7A 40 03 D3 9D 40 04 : rN@ Y @ Az@   @ 
	0x40: 96 ED 40 83 20 30 0D C0 6E 30 0E C0 78 30 0F C0 :   @  0  n0  x0  
	0x50: 6F 30 10 C0 79 30 12 C0 89 30 13 C0 8D 30 14 C0 : o0  y0   0   0  
	0x60: 8C 30 11 C0 72 8B 20 30 0D C0 0A 30 0E C0 14 30 :  0  r  0   0   0
	0x70: 0F C0 0B 30 10 C0 15 30 11 C0 0E 30 12 C0 25 30 :    0   0   0  %0
	0x80: 13 C0 29 30 14 C0 28 41 18 30 0D 19 30 0E 19 30 :   )0  (A 0  0  0
	0x90: 0F 19 30 10 19 30 12 16 30 13 16 30 14 16 30 18 :   0  0  0  0  0 
	0xA0: 0C                                              :  
	========================================================================
        QAM_AUTO f = 714000 kHz I999B8C999D999T999G999Y999P0 (0:0:2003) : updating network_id -> (0:12003:2003)
          check_duplicate_transponders()
          ================= list_transponders() =======================
          new_transponders(000): QAM_16   f = 498000 kHz I999B8C34D0T8G4Y0 (8232:13200:600)
          new_transponders(001): QAM_AUTO f = 714000 kHz I999B8C999D999T999G999Y999P0 (0:12003:2003)
          =============================================================
        ----------------------------------------------------------
        NIT(act): (8232:12003:2003)
	find_transponder(0:12003:2003):          -> found 'new_transponders(001)'  QAM_AUTO f = 714000 kHz I999B8C999D999T999G999Y999P0 (0:12003:2003)
        QAM_AUTO f = 714000 kHz I999B8C999D999T999G999Y999P0 (0:12003:2003) : updating original_network_id -> (8232:12003:2003)
          ================= list_transponders() =======================
          new_transponders(000): QAM_16   f = 498000 kHz I999B8C34D0T8G4Y0 (8232:13200:600)
          new_transponders(001): QAM_AUTO f = 714000 kHz I999B8C999D999T999G999Y999P0 (8232:12003:2003)
          =============================================================
	===================== parse_T2_delivery_system_descriptor ==============
	len = 6
	0x00: 04 01 20 28 03 36                               :    ( 6
	========================================================================
parse_T2_delivery_system_descriptor f714000 system_id8232 plp_id1 SISO/MISO=SISO B8.0 G16 T32 other_frequency1 TFS0
          00 frequencies:
	===================== parse_frequency_list_descriptor ==================
	len = 33
	0x00: FF 04 35 45 40 02 DF 79 40 02 F7 E3 40 04 72 4E :   5E@  y@   @ rN
	0x10: 40 04 59 E4 40 04 41 7A 40 03 D3 9D 40 04 96 ED : @ Y @ Az@   @   
	0x20: 40                                              : @
	========================================================================
          08 frequencies
             706000000
             482000000
             498000000
             746000000
             730000000
             714000000
             642000000
             770000000
	===================== parse_logical_channel_descriptor =================
	len = 32
	0x00: 30 0D C0 6E 30 0E C0 78 30 0F C0 6F 30 10 C0 79 : 0  n0  x0  o0  y
	0x10: 30 12 C0 89 30 13 C0 8D 30 14 C0 8C 30 11 C0 72 : 0   0   0   0  r
	========================================================================
	find_transponder(8232:12003:2003):          -> found 'new_transponders(001)'  QAM_AUTO f = 714000 kHz I999B8C999D999T999G999Y999P0 (8232:12003:2003)
        updating transponder:
           (QAM_AUTO f = 714000 kHz I999B8C999D999T999G999Y999P0 (8232:12003:2003)) 0x0000
        to (QAM_AUTO f = 714000 kHz I999B8C999D999T32G16Y999P1 (8232:12003:2003)) 0x4004
           cell id 0, freq = 706000000
           cell id 0, freq = 482000000
           cell id 0, freq = 498000000
           cell id 0, freq = 746000000
           cell id 0, freq = 730000000
           cell id 0, freq = 714000000
           cell id 0, freq = 642000000
           cell id 0, freq = 770000000
          ================= list_transponders() =======================
          new_transponders(000): QAM_16   f = 498000 kHz I999B8C34D0T8G4Y0 (8232:13200:600)
          new_transponders(001): QAM_AUTO f = 714000 kHz I999B8C999D999T32G16Y999P1 (8232:12003:2003)
          =============================================================

722000: (time: 03:08.635)
730000: (time: 03:10.667)
738000: (time: 03:12.703)
746000: (time: 03:14.727)
754000: (time: 03:16.763)
762000: (time: 03:18.795)
770000: (time: 03:20.827)
778000: (time: 03:22.863)
786000: (time: 03:24.891)
794000: (time: 03:26.923)
802000: (time: 03:28.951)
810000: (time: 03:30.987)
818000: (time: 03:33.011)
826000: (time: 03:35.039)
834000: (time: 03:37.071)
842000: (time: 03:39.099)
850000: (time: 03:41.131)
858000: (time: 03:43.167)
tune to: QAM_16 f = 498000 kHz I999B8C34D0T8G4Y0 (8232:13200:600) (time: 03:45.195)
(0.312sec): SCL
PAT (xxxx:xxxx:600)

	===================== parse_pat ========================================
	len = 16
	0x00: 27 75 E2 59 27 84 E2 5A 27 98 E2 5B 27 A6 E2 5F : 'u Y'  Z'  ['  _
	========================================================================
PAT (xxxx:xxxx:600)
	===================== parse_pat ========================================
	len = 16
	0x00: 27 75 E2 59 27 84 E2 5A 27 98 E2 5B 27 A6 E2 5F : 'u Y'  Z'  ['  _
	========================================================================
PMT 601 (0x0259) for service 10101 (0x2775)
	===================== parse_pmt ========================================
	len = 114
	0x00: F7 7A F0 00 02 F7 7A F0 03 52 01 01 03 F7 7B F0 :  z    z  R    { 
	0x10: 09 52 01 02 0A 04 67 65 72 01 06 F7 7D F0 0C 6A :  R    ger   }  j
	0x20: 01 00 52 01 05 0A 04 67 65 72 01 06 F7 7F F0 0A :   R    ger      
	0x30: 56 05 67 65 72 09 00 52 01 04 06 F7 7E F0 13 52 : V ger  R    ~  R
	0x40: 01 06 45 06 04 01 F0 05 01 F7 C3 06 04 01 F0 05 :   E             
	0x50: 01 F7 05 FC F2 F0 08 6F 03 00 10 E1 52 01 15 0B :        o    R   
	0x60: FC F3 F0 0E 66 02 01 23 13 05 00 00 1C F3 00 52 :     f  #       R
	0x70: 01 16                                           :   
	========================================================================
  VIDEO     : PID 6010 (stream type 0x2)
  AUDIO     : PID 6011 (stream type 0x3)
  AC3       : PID 6013 (stream type 0x6)
  TELETEXT  : PID 6015

unknown private data: PID 0x177e
unknown private data: PID 0x1cf2
DSM-CC U-N Messages : PID 7411
parse_pmt:1219: tsid=0 sid=10101: (null) -- (null), pmt_pid 0x0259, vpid 0x177a, apid 6011 (ger) PMT 603 (0x025b) for service 10136 (0x2798)

	===================== parse_pmt ========================================
	len = 114
	0x00: F7 84 F0 00 02 F7 84 F0 03 52 01 03 03 F7 85 F0 :          R      
	0x10: 09 52 01 04 0A 04 67 65 72 01 06 F7 87 F0 0C 6A :  R    ger      j
	0x20: 01 00 52 01 07 0A 04 67 65 72 01 06 F7 89 F0 0A :   R    ger      
	0x30: 56 05 67 65 72 09 00 52 01 05 06 F7 88 F0 13 52 : V ger  R       R
	0x40: 01 08 45 06 04 01 F0 05 01 F7 C3 06 04 01 F0 05 :   E             
	0x50: 01 F7 05 FC F2 F0 08 6F 03 00 10 E1 52 01 15 0B :        o    R   
	0x60: FC F3 F0 0E 66 02 01 23 13 05 00 00 1C F3 00 52 :     f  #       R
	0x70: 01 16                                           :   
	========================================================================
  VIDEO     : PID 6020 (stream type 0x2)
  AUDIO     : PID 6021 (stream type 0x3)
  AC3       : PID 6023 (stream type 0x6)
  TELETEXT  : PID 6025

unknown private data: PID 0x1788
unknown private data: PID 0x1cf2
DSM-CC U-N Messages : PID 7411
parse_pmt:1219: tsid=0 sid=10136: (null) -- (null), pmt_pid 0x025b, vpid 0x1784, apid 6021 (ger) PMT 602 (0x025a) for service 10116 (0x2784)

	===================== parse_pmt ========================================
	len = 114
	0x00: F7 84 F0 00 02 F7 84 F0 03 52 01 03 03 F7 85 F0 :          R      
	0x10: 09 52 01 04 0A 04 67 65 72 01 06 F7 87 F0 0C 6A :  R    ger      j
	0x20: 01 00 52 01 07 0A 04 67 65 72 01 06 F7 89 F0 0A :   R    ger      
	0x30: 56 05 67 65 72 09 00 52 01 05 06 F7 88 F0 13 52 : V ger  R       R
	0x40: 01 08 45 06 04 01 F0 05 01 F7 C3 06 04 01 F0 05 :   E             
	0x50: 01 F7 05 FC F2 F0 08 6F 03 00 10 E1 52 01 15 0B :        o    R   
	0x60: FC F3 F0 0E 66 02 01 23 13 05 00 00 1C F3 00 52 :     f  #       R
	0x70: 01 16                                           :   
	========================================================================
  VIDEO     : PID 6020 (stream type 0x2)
  AUDIO     : PID 6021 (stream type 0x3)
  AC3       : PID 6023 (stream type 0x6)
  TELETEXT  : PID 6025

unknown private data: PID 0x1788
unknown private data: PID 0x1cf2
DSM-CC U-N Messages : PID 7411
parse_pmt:1219: tsid=0 sid=10116: (null) -- (null), pmt_pid 0x025a, vpid 0x1784, apid 6021 (ger) PMT 607 (0x025f) for service 10150 (0x27a6)

	===================== parse_pmt ========================================
	len = 59
	0x00: F8 06 F0 00 1B F8 06 F0 03 52 01 01 06 F7 89 F0 :          R      
	0x10: 0A 52 01 04 56 05 67 65 72 09 00 05 FC F2 F0 08 :  R  V ger       
	0x20: 6F 03 00 10 E1 52 01 15 0B FC F3 F0 0E 66 02 01 : o    R       f  
	0x30: 23 13 05 00 00 1C F3 00 52 01 16                : #       R  
	========================================================================

AVC Video stream, ITU-T Rec. H.264 | ISO/IEC 14496-10 : PID 6150 (stream type 0x1b) TELETEXT : PID 6025
unknown private data: PID 0x1cf2
DSM-CC U-N Messages : PID 7411
parse_pmt:1219: tsid=0 sid=10150: (null) -- (null), pmt_pid 0x025f, vpid 0x1806, apid 0 () SDT(actual TS, transport_stream_id 600 (0x0258) )

	===================== parse_sdt ========================================
	len = 79
	0x00: 20 28 FF 27 75 FF 80 0C 48 0A 01 03 4F 52 46 04 :  ( 'u   H   ORF 
	0x10: 4F 52 46 31 27 84 FF 80 0E 48 0C 01 03 4F 52 46 : ORF1'    H   ORF
	0x20: 06 4F 52 46 32 20 4B 27 98 FF 80 0E 48 0C 01 03 :  ORF2 K'    H   
	0x30: 4F 52 46 06 4F 52 46 32 20 54 27 A6 FF 80 10 48 : ORF ORF2 T'    H
	0x40: 0E 19 03 4F 52 46 08 4F 52 46 32 54 20 48 44    :    ORF ORF2T HD
	========================================================================
	===================== parse_service_descriptor =========================
	len = 10
	0x00: 01 03 4F 52 46 04 4F 52 46 31                   :   ORF ORF1
	========================================================================
	service = ORF1 (ORF)
	===================== parse_service_descriptor =========================
	len = 12
	0x00: 01 03 4F 52 46 06 4F 52 46 32 20 4B             :   ORF ORF2 K
	========================================================================
	service = ORF2 K (ORF)
	===================== parse_service_descriptor =========================
	len = 12
	0x00: 01 03 4F 52 46 06 4F 52 46 32 20 54             :   ORF ORF2 T
	========================================================================
	service = ORF2 T (ORF)
	===================== parse_service_descriptor =========================
	len = 14
	0x00: 19 03 4F 52 46 08 4F 52 46 32 54 20 48 44       :   ORF ORF2T HD
	========================================================================
	service = ORF2T HD (ORF)
NIT(act): (xxxx:13200:xxxx)
	===================== parse_nit ========================================
	len = 77
	0x00: F0 0E 40 0C 4F 52 53 20 44 56 42 2D 54 20 4B 54 :   @ ORS DVB-T KT
	0x10: F0 3B 02 58 20 28 F0 35 5A 0B 05 1D 34 40 1F 42 :  ; X ( 5Z   4@ B
	0x20: 5B FF FF FF FF 5A 0B 03 7E 2A 40 1F 42 5B FF FF : [    Z  ~*@ B[  
	0x30: FF FF 5A 0B 02 F7 E3 40 1F 42 5B FF FF FF FF 8B :   Z    @ B[     
	0x40: 0C 27 75 C0 32 27 84 C0 3A 27 98 C0 38          :  'u 2'  :'  8
	========================================================================
        ----------------------------------------------------------
        NIT(act): (8232:13200:600)
	find_transponder(0:13200:600):          -> found 'scanned_transponders(000)'  QAM_16   f = 498000 kHz I999B8C34D0T8G4Y0 (8232:13200:600)
	===================== parse_terrestrial_delivery_system_descriptor =====
	len = 11
	0x00: 05 1D 34 40 1F 42 5B FF FF FF FF                :   4@ B[    
	========================================================================
          F498000 B8 M16 C34 D999 G4 T8 other_frequency=1 (858000000)
          1 frequencies
             858000000
	===================== parse_terrestrial_delivery_system_descriptor =====
	len = 11
	0x00: 03 7E 2A 40 1F 42 5B FF FF FF FF                :  ~*@ B[    
	========================================================================
          F498000 B8 M16 C34 D999 G4 T8 other_frequency=1 (586000000)
          2 frequencies
             858000000
             586000000
	===================== parse_terrestrial_delivery_system_descriptor =====
	len = 11
	0x00: 02 F7 E3 40 1F 42 5B FF FF FF FF                :    @ B[    
	========================================================================
          F498000 B8 M16 C34 D999 G4 T8 other_frequency=1 (498000000)
          3 frequencies
             858000000
             586000000
             498000000
	find_transponder(8232:13200:600):          -> found 'scanned_transponders(000)'  QAM_16   f = 498000 kHz I999B8C34D0T8G4Y0 (8232:13200:600)
        Info: no data from NIT(other) after 61 seconds

tune to: QAM_AUTO f = 714000 kHz I999B8C999D999T32G16Y999P1 (8232:12003:2003) (time: 04:47.407)
(0.264sec): SC
----------no signal----------
tune to: QAM_AUTO f = 714000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003) (time: 04:47.723) (no signal)
(0.420sec): SC
----------no signal----------

        find_transponder_by_freq(QAM_AUTO f = 706000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003))          -> found 'scanned_transponders(001)'  QAM_AUTO f = 706000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003)
        find_transponder_by_freq(QAM_AUTO f = 482000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003))          -> found 'scanned_transponders(001)'  QAM_AUTO f = 482000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003)
        find_transponder_by_freq(QAM_AUTO f = 498000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003))          -> found 'scanned_transponders(000)'  QAM_AUTO f = 498000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003)
        find_transponder_by_freq(QAM_AUTO f = 746000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003))          -> found 'scanned_transponders(001)'  QAM_AUTO f = 746000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003)
        find_transponder_by_freq(QAM_AUTO f = 730000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003))          -> found 'scanned_transponders(001)'  QAM_AUTO f = 730000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003)
        find_transponder_by_freq(QAM_AUTO f = 714000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003))          -> found 'scanned_transponders(001)'  QAM_AUTO f = 714000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003)
        find_transponder_by_freq(QAM_AUTO f = 642000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003))          -> found 'scanned_transponders(001)'  QAM_AUTO f = 642000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003)
        find_transponder_by_freq(QAM_AUTO f = 770000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003))          -> found 'scanned_transponders(001)'  QAM_AUTO f = 770000 kHz I999B8C999D999T999G999Y999P1 (8232:12003:2003)

(time: 04:48.195) dumping lists (4 services)
..
Done, scan time: 04:48.195
blah@blah:~$

author
#3 lore raw
In reply to Antti Palosaari

How can I enable debug-output to get the log-messages like http://git.linuxtv.org/cgit.cgi/media_tree.git/tree/drivers/media/dvb-frontends/si2168.c#n164 ?

Am 28.05.2015 07:26, schrieb Antti Palosaari:

Quoted 134 lines · Hurda
Quoted 18 lines

Hello.

I think I came across a bug in either of the drivers si2168 and dvbsky regarding
blind-scanning DVB-T2-frequencies.

HW: Technotrend CT2-4400v2 (afaik based on or the same as DVBSky T330)

     demod: Si2168-B40
     tuner: Si2158-A20

OS: Ubuntu 15.04 (kernel 3.19)

In Austria, the DVB-T2-service "SimpliTV" is currently airing up to four muxes, next to one or two DVB-T-muxes.
In my region, the frequencies are 490MHz, 546MHz, 690MHz, 714MHz for DVB-T2,
and 498MHz for DVB-T.
These numbers might be of interest when reading the logs.

Quoted 3 lines

The peculiar aspect of these T2-muxes is that they're aired on PLP 1 without
there being a PLP 0. I think this is also the root of my problem.

dvbv5-scan is working, but w_scan not?

Could you hack si2168.c file and test?

if (c->delivery_system == SYS_DVBT2) {
    /* select PLP */
    cmd.args[0] = 0x52;
    cmd.args[1] = c->stream_id & 0xff;
//    cmd.args[2] = c->stream_id == NO_STREAM_ID_FILTER ? 0 : 1;
    cmd.args[2] = 0;
    cmd.wlen = 3;
    cmd.rlen = 1;
    ret = si2168_cmd_execute(client, &cmd);
    if (ret)
        goto err;
}

Antti

Quoted 91 lines

When doing a blind-scan using w_scan 20140727 on Ubuntu 15.04 (kernel 3.19),
w_scan does not find any of these four DVB-T2-muxes.
It just finds the DVB-T-mux.

Logs:
media-tree_dmesg_lsusb.txt http://pastebin.com/0ixFPMSA
media-tree_w_scan.txt http://pastebin.com/yyG3jSwj

The found transponder:
initial_v3_media_build_trunk.conf http://pastebin.com/LmFQavpy
initial_v5.conf http://pastebin.com/Jx6kymVt

I also tried a fresh checkout from git.linuxtv.org as of last weekend and the
most recent w_scan version (20141122).

As you can see, w_scan tries to tune(?) the DVB-T2-frequencies, but ultimately doesn't find anything on them.

Then I tried the DVBSky-linux-driver[1] (media_build-bst-20150322.tar.gz)[2]
from their site, which is using a binary called sit2 for this card. Using this driver, w_scan found all four DVB-T2-muxes and the DVB-T-mux. Additionally, it found the DVB-T2-muxes during the DVB-T-scan.

Logs:
media_build-bst_dmesg_lsusb.txt http://pastebin.com/vJeDMxtu
media_build-bst_w_scan.txt http://pastebin.com/yhwAYjen

Found transponders:
initial_v3_bst.conf http://pastebin.com/ECKQvRWX
initial_v5_bst.conf http://pastebin.com/CbhY6Hpz

Of course, doing a channel-scan using dvbv5-scan on these transponders worked
too:

dvbv5_sit2.conf http://pastebin.com/3W52bbhv
dvbv5_sit2.log http://pastebin.com/nc66PTkt

Afterwards, I tried to do a channel-scan with the same initial tuning-file using the opensource-driver, which also worked:

dvbv5_si2168.conf http://pastebin.com/A6FbqUL1
dvbv5_si2168.log http://pastebin.com/ewyVPJR2

This should verify that tuning PLP 1 without there being PLP 0 is not the issue.

Additionally, if you compare the two channel-lists, you find interesting differences:

The scan with si2168 has AUTO for "MODULATION" and "INVERSION" for DVB-T2-channels, and for "CODE_RATE_LP" and "INVERSION" for DVB-T-channels.

The scan with sit2 has the respective values in the channel-list.

The dvbv5-scan-logs also differ, as using sit2 also displays the signal quality
during tuning.

I know that there were changes regarding DVB-T2-scanning[3], but as the blog-
article specifically mentions si2168 and w_scan to be fully dvbv5-compliant and good for using with DVB-T2, I thought you should know about this particular problem.

In the attachment I've packed the previously linked logs, for archival reasons.

Thank you for your attention.

[1] http://www.dvbsky.net/Support_linux.html
[2] http://www.dvbsky.net/download/linux/media_build-bst-150322.tar.gz
[3] http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html

PS: Interesting comments regarding auto-detection for si2168:
http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427233615765#c8591459871945922951

http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427234034259#c6500661729983566638

#4 lore raw
Quoted 3 lines · Hurda

How can I enable debug-output to get the log-messages like
http://git.linuxtv.org/cgit.cgi/media_tree.git/tree/drivers/media/dvb-frontends/si2168.c#n164
?

Compile kernel with dynamic debugs. After that you could enable debugs:
modprobe si2168; echo -n 'module si2168 =pft' > /sys/kernel/debug/dynamic_debug/control

Antti

Quoted 140 lines

Am 28.05.2015 07:26, schrieb Antti Palosaari:

Quoted 137 lines · Hurda
Quoted 18 lines

Hello.

I think I came across a bug in either of the drivers si2168 and dvbsky regarding
blind-scanning DVB-T2-frequencies.

HW: Technotrend CT2-4400v2 (afaik based on or the same as DVBSky T330)

     demod: Si2168-B40
     tuner: Si2158-A20

OS: Ubuntu 15.04 (kernel 3.19)

In Austria, the DVB-T2-service "SimpliTV" is currently airing up to four muxes, next to one or two DVB-T-muxes.
In my region, the frequencies are 490MHz, 546MHz, 690MHz, 714MHz for DVB-T2,
and 498MHz for DVB-T.
These numbers might be of interest when reading the logs.

Quoted 3 lines

The peculiar aspect of these T2-muxes is that they're aired on PLP 1 without
there being a PLP 0. I think this is also the root of my problem.

dvbv5-scan is working, but w_scan not?

Could you hack si2168.c file and test?

if (c->delivery_system == SYS_DVBT2) {
    /* select PLP */
    cmd.args[0] = 0x52;
    cmd.args[1] = c->stream_id & 0xff;
//    cmd.args[2] = c->stream_id == NO_STREAM_ID_FILTER ? 0 : 1;
    cmd.args[2] = 0;
    cmd.wlen = 3;
    cmd.rlen = 1;
    ret = si2168_cmd_execute(client, &cmd);
    if (ret)
        goto err;
}

Antti

Quoted 94 lines

When doing a blind-scan using w_scan 20140727 on Ubuntu 15.04 (kernel 3.19),
w_scan does not find any of these four DVB-T2-muxes.
It just finds the DVB-T-mux.

Logs:
media-tree_dmesg_lsusb.txt http://pastebin.com/0ixFPMSA
media-tree_w_scan.txt http://pastebin.com/yyG3jSwj

The found transponder:
initial_v3_media_build_trunk.conf http://pastebin.com/LmFQavpy
initial_v5.conf http://pastebin.com/Jx6kymVt

I also tried a fresh checkout from git.linuxtv.org as of last weekend and the
most recent w_scan version (20141122).

As you can see, w_scan tries to tune(?) the DVB-T2-frequencies, but ultimately doesn't find anything on them.

Then I tried the DVBSky-linux-driver[1] (media_build-bst-20150322.tar.gz)[2]
from their site, which is using a binary called sit2 for this card. Using this driver, w_scan found all four DVB-T2-muxes and the DVB-T-mux. Additionally, it found the DVB-T2-muxes during the DVB-T-scan.

Logs:
media_build-bst_dmesg_lsusb.txt http://pastebin.com/vJeDMxtu
media_build-bst_w_scan.txt http://pastebin.com/yhwAYjen

Found transponders:
initial_v3_bst.conf http://pastebin.com/ECKQvRWX
initial_v5_bst.conf http://pastebin.com/CbhY6Hpz

Of course, doing a channel-scan using dvbv5-scan on these transponders worked
too:

dvbv5_sit2.conf http://pastebin.com/3W52bbhv
dvbv5_sit2.log http://pastebin.com/nc66PTkt

Afterwards, I tried to do a channel-scan with the same initial tuning-file
using the opensource-driver, which also worked:

dvbv5_si2168.conf http://pastebin.com/A6FbqUL1
dvbv5_si2168.log http://pastebin.com/ewyVPJR2

This should verify that tuning PLP 1 without there being PLP 0 is not the issue.

Additionally, if you compare the two channel-lists, you find interesting differences:

The scan with si2168 has AUTO for "MODULATION" and "INVERSION" for DVB-T2-channels, and for "CODE_RATE_LP" and "INVERSION" for DVB-T-channels.

The scan with sit2 has the respective values in the channel-list.

The dvbv5-scan-logs also differ, as using sit2 also displays the signal quality
during tuning.

I know that there were changes regarding DVB-T2-scanning[3], but as the blog-
article specifically mentions si2168 and w_scan to be fully dvbv5-compliant
and good for using with DVB-T2, I thought you should know about this particular problem.

In the attachment I've packed the previously linked logs, for archival reasons.

Thank you for your attention.

[1] http://www.dvbsky.net/Support_linux.html
[2] http://www.dvbsky.net/download/linux/media_build-bst-150322.tar.gz
[3] http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html

PS: Interesting comments regarding auto-detection for si2168:
http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427233615765#c8591459871945922951

http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427234034259#c6500661729983566638

Signature · 1 line
http://palosaari.fi/
#5 lore raw

Even easier way to activate dynamic debugging at module load time (assuming your kernel has dynamic debugging enabled):

modprobe si2168 dyndbg==pmf

Cheers,
-olli

Quoted 169 lines · Antti Palosaari
Quoted 5 lines · Hurda

How can I enable debug-output to get the log-messages like

http://git.linuxtv.org/cgit.cgi/media_tree.git/tree/drivers/media/dvb-frontends/si2168.c#n164
?

Compile kernel with dynamic debugs. After that you could enable debugs:
modprobe si2168; echo -n 'module si2168 =pft' > /sys/kernel/debug/dynamic_debug/control

Antti

Quoted 145 lines

Am 28.05.2015 07:26, schrieb Antti Palosaari:

Quoted 142 lines · Hurda
Quoted 19 lines

Hello.

I think I came across a bug in either of the drivers si2168 and dvbsky regarding
blind-scanning DVB-T2-frequencies.

HW: Technotrend CT2-4400v2 (afaik based on or the same as DVBSky T330)

     demod: Si2168-B40
     tuner: Si2158-A20

OS: Ubuntu 15.04 (kernel 3.19)

In Austria, the DVB-T2-service "SimpliTV" is currently airing up to four muxes, next to one or two DVB-T-muxes.
In my region, the frequencies are 490MHz, 546MHz, 690MHz, 714MHz for DVB-T2,
and 498MHz for DVB-T.
These numbers might be of interest when reading the logs.

Quoted 3 lines

The peculiar aspect of these T2-muxes is that they're aired on PLP 1 without
there being a PLP 0. I think this is also the root of my problem.

dvbv5-scan is working, but w_scan not?

Could you hack si2168.c file and test?

if (c->delivery_system == SYS_DVBT2) {
    /* select PLP */
    cmd.args[0] = 0x52;
    cmd.args[1] = c->stream_id & 0xff;
//    cmd.args[2] = c->stream_id == NO_STREAM_ID_FILTER ? 0 : 1;
    cmd.args[2] = 0;
    cmd.wlen = 3;
    cmd.rlen = 1;
    ret = si2168_cmd_execute(client, &cmd);
    if (ret)
        goto err;
}

Antti

Quoted 96 lines

When doing a blind-scan using w_scan 20140727 on Ubuntu 15.04 (kernel 3.19),
w_scan does not find any of these four DVB-T2-muxes.
It just finds the DVB-T-mux.

Logs:
media-tree_dmesg_lsusb.txt http://pastebin.com/0ixFPMSA
media-tree_w_scan.txt http://pastebin.com/yyG3jSwj

The found transponder:
initial_v3_media_build_trunk.conf http://pastebin.com/LmFQavpy
initial_v5.conf http://pastebin.com/Jx6kymVt

I also tried a fresh checkout from git.linuxtv.org as of last weekend and the
most recent w_scan version (20141122).

As you can see, w_scan tries to tune(?) the DVB-T2-frequencies, but ultimately doesn't find anything on them.

Then I tried the DVBSky-linux-driver[1] (media_build-bst-20150322.tar.gz)[2]
from their site, which is using a binary called sit2 for this card. Using this driver, w_scan found all four DVB-T2-muxes and the DVB-T-mux. Additionally, it found the DVB-T2-muxes during the DVB-T-scan.

Logs:
media_build-bst_dmesg_lsusb.txt http://pastebin.com/vJeDMxtu
media_build-bst_w_scan.txt http://pastebin.com/yhwAYjen

Found transponders:
initial_v3_bst.conf http://pastebin.com/ECKQvRWX
initial_v5_bst.conf http://pastebin.com/CbhY6Hpz

Of course, doing a channel-scan using dvbv5-scan on these transponders worked
too:

dvbv5_sit2.conf http://pastebin.com/3W52bbhv
dvbv5_sit2.log http://pastebin.com/nc66PTkt

Afterwards, I tried to do a channel-scan with the same initial tuning-file
using the opensource-driver, which also worked:

dvbv5_si2168.conf http://pastebin.com/A6FbqUL1
dvbv5_si2168.log http://pastebin.com/ewyVPJR2

This should verify that tuning PLP 1 without there being PLP 0 is not the issue.

Additionally, if you compare the two channel-lists, you find interesting differences:

The scan with si2168 has AUTO for "MODULATION" and "INVERSION" for DVB-T2-channels, and for "CODE_RATE_LP" and "INVERSION" for DVB-T-channels.

The scan with sit2 has the respective values in the channel-list.

The dvbv5-scan-logs also differ, as using sit2 also displays the signal quality
during tuning.

I know that there were changes regarding DVB-T2-scanning[3], but as the blog-
article specifically mentions si2168 and w_scan to be fully dvbv5-compliant
and good for using with DVB-T2, I thought you should know about this particular problem.

In the attachment I've packed the previously linked logs, for archival reasons.

Thank you for your attention.

[1] http://www.dvbsky.net/Support_linux.html
[2] http://www.dvbsky.net/download/linux/media_build-bst-150322.tar.gz
[3] http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html

PS: Interesting comments regarding auto-detection for si2168:

http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427233615765#c8591459871945922951

http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427234034259#c6500661729983566638

--
http://palosaari.fi/
--
To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

author
#6 lore raw
In reply to Antti Palosaari

Thanks, this worked.
The kernel of Ubuntu 15.04 already was compiled with dynamic debug, which saved me a lot of time.
The driver is properly setting stream_id to 1 when needed.

I tried again with the vanilla source and "cmd.args[2] = 0;". With the vanilla source, it doesn't find any T2-transponders.

With the modified source, the number of found transponders changes every time I'm scanning.
I did four runs: twice it found one mux, once it found two and once it found three, but never all four.
I even tried with w_scan-options for longer tuner- and demux-timeouts.

Without changing the position of the antenna or the stick, after reinstalling the dvbsky-driver, it found all four T2-muxes on the first try.

Quoted 157 lines · Antti Palosaari
Quoted 4 lines · Hurda

How can I enable debug-output to get the log-messages like
http://git.linuxtv.org/cgit.cgi/media_tree.git/tree/drivers/media/dvb-frontends/si2168.c#n164

?

Compile kernel with dynamic debugs. After that you could enable debugs:
modprobe si2168; echo -n 'module si2168 =pft' > /sys/kernel/debug/dynamic_debug/control

Antti

Quoted 142 lines

Am 28.05.2015 07:26, schrieb Antti Palosaari:

Quoted 139 lines · Hurda
Quoted 18 lines

Hello.

I think I came across a bug in either of the drivers si2168 and dvbsky regarding
blind-scanning DVB-T2-frequencies.

HW: Technotrend CT2-4400v2 (afaik based on or the same as DVBSky T330)

     demod: Si2168-B40
     tuner: Si2158-A20

OS: Ubuntu 15.04 (kernel 3.19)

In Austria, the DVB-T2-service "SimpliTV" is currently airing up to four muxes, next to one or two DVB-T-muxes.
In my region, the frequencies are 490MHz, 546MHz, 690MHz, 714MHz for DVB-T2,
and 498MHz for DVB-T.
These numbers might be of interest when reading the logs.

Quoted 3 lines

The peculiar aspect of these T2-muxes is that they're aired on PLP 1 without
there being a PLP 0. I think this is also the root of my problem.

dvbv5-scan is working, but w_scan not?

Could you hack si2168.c file and test?

if (c->delivery_system == SYS_DVBT2) {
    /* select PLP */
    cmd.args[0] = 0x52;
    cmd.args[1] = c->stream_id & 0xff;
//    cmd.args[2] = c->stream_id == NO_STREAM_ID_FILTER ? 0 : 1;
    cmd.args[2] = 0;
    cmd.wlen = 3;
    cmd.rlen = 1;
    ret = si2168_cmd_execute(client, &cmd);
    if (ret)
        goto err;
}

Antti

Quoted 96 lines

When doing a blind-scan using w_scan 20140727 on Ubuntu 15.04 (kernel 3.19),
w_scan does not find any of these four DVB-T2-muxes.
It just finds the DVB-T-mux.

Logs:
media-tree_dmesg_lsusb.txt http://pastebin.com/0ixFPMSA
media-tree_w_scan.txt http://pastebin.com/yyG3jSwj

The found transponder:
initial_v3_media_build_trunk.conf http://pastebin.com/LmFQavpy
initial_v5.conf http://pastebin.com/Jx6kymVt

I also tried a fresh checkout from git.linuxtv.org as of last weekend and the
most recent w_scan version (20141122).

As you can see, w_scan tries to tune(?) the DVB-T2-frequencies, but ultimately doesn't find anything on them.

Then I tried the DVBSky-linux-driver[1] (media_build-bst-20150322.tar.gz)[2]
from their site, which is using a binary called sit2 for this card. Using this driver, w_scan found all four DVB-T2-muxes and the DVB-T-mux. Additionally, it found the DVB-T2-muxes during the DVB-T-scan.

Logs:
media_build-bst_dmesg_lsusb.txt http://pastebin.com/vJeDMxtu
media_build-bst_w_scan.txt http://pastebin.com/yhwAYjen

Found transponders:
initial_v3_bst.conf http://pastebin.com/ECKQvRWX
initial_v5_bst.conf http://pastebin.com/CbhY6Hpz

Of course, doing a channel-scan using dvbv5-scan on these transponders worked
too:

dvbv5_sit2.conf http://pastebin.com/3W52bbhv
dvbv5_sit2.log http://pastebin.com/nc66PTkt

Afterwards, I tried to do a channel-scan with the same initial tuning-file
using the opensource-driver, which also worked:

dvbv5_si2168.conf http://pastebin.com/A6FbqUL1
dvbv5_si2168.log http://pastebin.com/ewyVPJR2

This should verify that tuning PLP 1 without there being PLP 0 is not the issue.

Additionally, if you compare the two channel-lists, you find interesting differences:

The scan with si2168 has AUTO for "MODULATION" and "INVERSION" for DVB-T2-channels, and for "CODE_RATE_LP" and "INVERSION" for DVB-T-channels.

The scan with sit2 has the respective values in the channel-list.

The dvbv5-scan-logs also differ, as using sit2 also displays the signal quality
during tuning.

I know that there were changes regarding DVB-T2-scanning[3], but as the blog-
article specifically mentions si2168 and w_scan to be fully dvbv5-compliant
and good for using with DVB-T2, I thought you should know about this particular problem.

In the attachment I've packed the previously linked logs, for archival reasons.

Thank you for your attention.

[1] http://www.dvbsky.net/Support_linux.html
[2] http://www.dvbsky.net/download/linux/media_build-bst-150322.tar.gz
[3] http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html

PS: Interesting comments regarding auto-detection for si2168:
http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427233615765#c8591459871945922951

http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427234034259#c6500661729983566638

#7 lore raw
Quoted 8 lines · Hurda

Thanks, this worked.
The kernel of Ubuntu 15.04 already was compiled with dynamic debug, which saved
me a lot of time.
The driver is properly setting stream_id to 1 when needed.

I tried again with the vanilla source and "cmd.args[2] = 0;". With the vanilla source, it doesn't find any T2-transponders.

You mean with vanilla source, but without that "cmd.args[2] = 0;" hack it does not find any transponders?

Quoted 2 lines

With the modified source, the number of found transponders changes every time

You mean with source, modified with that "cmd.args[2] = 0;" hack it finds transponders, but not always?

If that is difference, then it sounds just like application is requesting some PLP, probably 0, and it will not work as your network delivers channels using PLP 1.

"cmd.args[2] = 0;" disables PLP filtering - it sets auto mode. Why it likely does not find all channels is too short timeout.

Increase timeout value to 3 second, 900 => 3000, in funtion si2168_get_tune_settings()

You didn't provide any debugs to see what PLP ID your application is requesting. It is the most important thing I would like to know, as I suspect it is wrong.

regards
Antti

Quoted 180 lines

I'm scanning.
I did four runs: twice it found one mux, once it found two and once it found
three, but never all four.
I even tried with w_scan-options for longer tuner- and demux-timeouts.

Without changing the position of the antenna or the stick, after reinstalling
the dvbsky-driver, it found all four T2-muxes on the first try.

Quoted 6 lines · Antti Palosaari
Quoted 3 lines · Hurda

How can I enable debug-output to get the log-messages like
http://git.linuxtv.org/cgit.cgi/media_tree.git/tree/drivers/media/dvb-frontends/si2168.c#n164

Quoted 157 lines
Quoted 1 line

?

Compile kernel with dynamic debugs. After that you could enable debugs:
modprobe si2168; echo -n 'module si2168 =pft' > /sys/kernel/debug/dynamic_debug/control

Antti

Quoted 147 lines

Am 28.05.2015 07:26, schrieb Antti Palosaari:

Quoted 144 lines · Hurda
Quoted 19 lines

Hello.

I think I came across a bug in either of the drivers si2168 and dvbsky regarding
blind-scanning DVB-T2-frequencies.

HW: Technotrend CT2-4400v2 (afaik based on or the same as DVBSky T330)

     demod: Si2168-B40
     tuner: Si2158-A20

OS: Ubuntu 15.04 (kernel 3.19)

In Austria, the DVB-T2-service "SimpliTV" is currently airing up to four
muxes, next to one or two DVB-T-muxes.
In my region, the frequencies are 490MHz, 546MHz, 690MHz, 714MHz for DVB-T2,
and 498MHz for DVB-T.
These numbers might be of interest when reading the logs.

Quoted 3 lines

The peculiar aspect of these T2-muxes is that they're aired on PLP 1 without
there being a PLP 0. I think this is also the root of my problem.

dvbv5-scan is working, but w_scan not?

Could you hack si2168.c file and test?

if (c->delivery_system == SYS_DVBT2) {
    /* select PLP */
    cmd.args[0] = 0x52;
    cmd.args[1] = c->stream_id & 0xff;
//    cmd.args[2] = c->stream_id == NO_STREAM_ID_FILTER ? 0 : 1;
    cmd.args[2] = 0;
    cmd.wlen = 3;
    cmd.rlen = 1;
    ret = si2168_cmd_execute(client, &cmd);
    if (ret)
        goto err;
}

Antti

Quoted 100 lines

When doing a blind-scan using w_scan 20140727 on Ubuntu 15.04 (kernel 3.19),
w_scan does not find any of these four DVB-T2-muxes.
It just finds the DVB-T-mux.

Logs:
media-tree_dmesg_lsusb.txt http://pastebin.com/0ixFPMSA
media-tree_w_scan.txt http://pastebin.com/yyG3jSwj

The found transponder:
initial_v3_media_build_trunk.conf http://pastebin.com/LmFQavpy
initial_v5.conf http://pastebin.com/Jx6kymVt

I also tried a fresh checkout from git.linuxtv.org as of last weekend and the
most recent w_scan version (20141122).

As you can see, w_scan tries to tune(?) the DVB-T2-frequencies, but ultimately doesn't find anything on them.

Then I tried the DVBSky-linux-driver[1] (media_build-bst-20150322.tar.gz)[2]
from their site, which is using a binary called sit2 for this card. Using this driver, w_scan found all four DVB-T2-muxes and the DVB-T-mux.
Additionally, it found the DVB-T2-muxes during the DVB-T-scan.

Logs:
media_build-bst_dmesg_lsusb.txt http://pastebin.com/vJeDMxtu
media_build-bst_w_scan.txt http://pastebin.com/yhwAYjen

Found transponders:
initial_v3_bst.conf http://pastebin.com/ECKQvRWX
initial_v5_bst.conf http://pastebin.com/CbhY6Hpz

Of course, doing a channel-scan using dvbv5-scan on these transponders worked
too:

dvbv5_sit2.conf http://pastebin.com/3W52bbhv
dvbv5_sit2.log http://pastebin.com/nc66PTkt

Afterwards, I tried to do a channel-scan with the same initial tuning-file
using the opensource-driver, which also worked:

dvbv5_si2168.conf http://pastebin.com/A6FbqUL1
dvbv5_si2168.log http://pastebin.com/ewyVPJR2

This should verify that tuning PLP 1 without there being PLP 0 is not the issue.

Additionally, if you compare the two channel-lists, you find interesting
differences:

The scan with si2168 has AUTO for "MODULATION" and "INVERSION" for DVB-T2-channels, and for "CODE_RATE_LP" and "INVERSION" for DVB-T-channels.

The scan with sit2 has the respective values in the channel-list.

The dvbv5-scan-logs also differ, as using sit2 also displays the signal
quality
during tuning.

I know that there were changes regarding DVB-T2-scanning[3], but as the
blog-
article specifically mentions si2168 and w_scan to be fully dvbv5-compliant
and good for using with DVB-T2, I thought you should know about this particular problem.

In the attachment I've packed the previously linked logs, for archival reasons.

Thank you for your attention.

[1] http://www.dvbsky.net/Support_linux.html
[2] http://www.dvbsky.net/download/linux/media_build-bst-150322.tar.gz
[3] http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html

PS: Interesting comments regarding auto-detection for si2168:
http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427233615765#c8591459871945922951

http://blog.palosaari.fi/2014/09/linux-dvb-t2-tuning-problems.html?showComment=1427234034259#c6500661729983566638

--
To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

Signature · 1 line
http://palosaari.fi/
author
#8 lore raw

(Resending as the first try apparently hasn't made it onto the mailing-list)

Quoted 7 lines · Antti Palosaari
Quoted 6 lines · Hurda

Thanks, this worked.
The kernel of Ubuntu 15.04 already was compiled with dynamic debug, which saved
me a lot of time.
The driver is properly setting stream_id to 1 when needed.

Quoted 6 lines
Quoted 2 lines

I tried again with the vanilla source and "cmd.args[2] = 0;". With the vanilla source, it doesn't find any T2-transponders.

You mean with vanilla source, but without that "cmd.args[2] = 0;" hack it does not find any transponders?

No T2-transponders, no.
With "cmd.args[2] = 0;" the number of found T2-transponders is changing with every scan. Using the dvbsky-driver, the scan always finds all four T2-transponders.

Quoted 11 lines
Quoted 3 lines

With the modified source, the number of found transponders changes every time

You mean with source, modified with that "cmd.args[2] = 0;" hack it finds transponders, but not always?

If that is difference, then it sounds just like application is requesting some PLP, probably 0, and it will not work as your network delivers channels using PLP 1.

Quoted 5 lines

"cmd.args[2] = 0;" disables PLP filtering - it sets auto mode. Why it likely does not find all channels is too short timeout.

Increase timeout value to 3 second, 900 => 3000, in funtion si2168_get_tune_settings()

No difference, even with 10000. Tried that timeout with "cmd.args[2] = 0;" and "cmd.args[2] = c->stream_id == NO_STREAM_ID_FILTER ? 0 : 1;"

Quoted 7 lines

You didn't provide any debugs to see what PLP ID your application is requesting. It is the most important thing I would like to know, as I suspect it is wrong.

regards
Antti

Debug-logs:
http://www.mediafire.com/download/8j4s9oytsfv9s40/si2168-dvbsky_debug_logs.zip
Made with the vanilla tree and "cmd.args[2] = 0;", and timeout 900 (default) and 3000msec.