scan from dvb-apps fails when using diseqc commands

Bug #430595 reported by Steven Ellis
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linuxtv-dvb-apps (Ubuntu)
New
Undecided
Unassigned

Bug Description

Platform is Ubuntu Jaunty or Mythbuntu Jaunty

dvb-apps - 1.1.1+rev1207-4

When using the scan command to interrogate multiple LNBs connected via a diseqc switch the scan fails.

A clean copy of the source from linuxtv.org works as expected - linuxtv-dvb-apps-1.1.1.tar.gz

Usind the following scan file D2.aurora
# Optus Aurora Transponder on Optus D2 satellite
# freq pol sr fec
S 12407000 V 30000000 AUTO
S 12448000 V 27800000 AUTO

The Optus D2 LNB is connected via port 4 on the LNB which is selected via "-s 3"

/usr/bin/scan -5 -l 11300 -s 3 D2.aurora
scanning D2.aurora
using '/dev/dvb/adapter0/frontend0' and '/dev/dvb/adapter0/demux0'
initial transponder 12407000 V 30000000 9
initial transponder 12448000 V 27800000 9
>>> tune to: 12407:v:3:30000
DVB-S IF freq is 1107000
WARNING: >>> tuning failed!!!
>>> tune to: 12407:v:3:30000 (tuning failed)
DVB-S IF freq is 1107000
WARNING: >>> tuning failed!!!
>>> tune to: 12448:v:3:27800
DVB-S IF freq is 1148000
WARNING: >>> tuning failed!!!
>>> tune to: 12448:v:3:27800 (tuning failed)
DVB-S IF freq is 1148000
WARNING: >>> tuning failed!!!
ERROR: initial tuning failed
dumping lists (0 services)
Done.

Running the same scan via a clean build off the vanilla source works as expected

~/src/linuxtv-dvb-apps-1.1.1/util/scan/scan -5 -l 11300 -s 3 D2.aurora
scanning D2.aurora
using '/dev/dvb/adapter0/frontend0' and '/dev/dvb/adapter0/demux0'
initial transponder 12407000 V 30000000 9
initial transponder 12448000 V 27800000 9
>>> tune to: 12407:v:3:30000
0x0000 0x012d: pmt_pid 0x0020 OP -- INFO 156�E (running)
0x0000 0x012e: pmt_pid 0x0020 OP -- SBS SE (running, scrambled)
0x0000 0x012f: pmt_pid 0x0020 OP -- SBS WA (running, scrambled)
0x0000 0x0130: pmt_pid 0x0020 OP -- BTV1 (running, scrambled)
0x0000 0x0131: pmt_pid 0x0020 OP -- . (running)
0x0000 0x0132: pmt_pid 0x0020 OP -- . (running)
0x0000 0x0133: pmt_pid 0x0020 OP -- 7 Central (running, scrambled)
0x0000 0x0134: pmt_pid 0x0020 OP -- . (running)
0x0000 0x0135: pmt_pid 0x0020 OP -- SBS QLD (running, scrambled)
0x0000 0x0136: pmt_pid 0x0020 OP -- . (running)
0x0000 0x0137: pmt_pid 0x0020 OP -- . (running)
0x0000 0x0138: pmt_pid 0x0020 OP -- . (running)

Revision history for this message
Steven Ellis (steven-openmedia) wrote :

Re-running with verbose output

 /usr/bin/scan -5 -verbose -l 11300 -s 3 D2.aurora
scanning D2.aurora
using '/dev/dvb/adapter0/frontend0' and '/dev/dvb/adapter0/demux0'
initial transponder 12407000 V 30000000 9
initial transponder 12448000 V 27800000 9
>>> tune to: 12407:v:3:30000
DVB-S IF freq is 1107000
>>> tuning status == 0x00
>>> tuning status == 0x00
>>> tuning status == 0x00
>>> tuning status == 0x00

~/src/linuxtv-dvb-apps-1.1.1/util/scan/scan -5 -verbose -l 11300 -s 3 D2.aurora 2>&1
scanning D2.aurora
using '/dev/dvb/adapter0/frontend0' and '/dev/dvb/adapter0/demux0'
initial transponder 12407000 V 30000000 9
initial transponder 12448000 V 27800000 9
>>> tune to: 12407:v:3:30000
DiSEqC: switch pos 3, 13V, loband (index 12)
>>> tuning status == 0x1f
PAT
PMT 0x0020 for service 0x0130
PMT 0x0020 for service 0x0138
PMT 0x0020 for service 0x0140
PMT 0x0020 for service 0x0143
PMT 0x0020 for service 0x0146
PMT 0x0020 for service 0x012d

Looks like the DiSEqC command hasn't been sent.

Revision history for this message
Steven Ellis (steven-openmedia) wrote :

Issue relates to changes in util/scan.c that won't allow a diseqc change unless high and switch values are provided when using a custom LNB type

The following command will work with a diseqc

/usr/bin/scan -5 -l 11300,11300,11300 -s 3 D2.aurora

The following logic is incorrect as it is possible to use a monopoint LNB via a DiSEqc

  if (lnb_type.high_val) {
   if (lnb_type.switch_val) {
    /* Voltage-controlled switch */
    int hiband = 0;

    if (p.frequency >= lnb_type.switch_val)
     hiband = 1;

    setup_switch (frontend_fd,
           switch_pos,
           t->polarisation == POLARISATION_VERTICAL ? 0 : 1,
           hiband);
    usleep(50000);
    if (hiband)
     p.frequency = abs(p.frequency - lnb_type.high_val);
    else
     p.frequency = abs(p.frequency - lnb_type.low_val);
   } else {
    /* C-Band Multipoint LNBf */
    p.frequency = abs(p.frequency - (t->polarisation == POLARISATION_VERTICAL ?
      lnb_type.low_val: lnb_type.high_val));
   }
  } else {
   /* Monopoint LNBf without switch */
   p.frequency = abs(p.frequency - lnb_type.low_val);
  }

Revision history for this message
Steven Ellis (steven-openmedia) wrote :

Confirmed problem exists in upstream mercurial repository.

I'll raise a bug report upstream.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.