From owner-freebsd-multimedia@FreeBSD.ORG Wed Mar 16 08:14:01 2011 Return-Path: Delivered-To: freebsd-multimedia@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E6353106566B for ; Wed, 16 Mar 2011 08:14:01 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe01.c2i.net [212.247.154.2]) by mx1.freebsd.org (Postfix) with ESMTP id 57AAD8FC16 for ; Wed, 16 Mar 2011 08:14:00 +0000 (UTC) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.1 cv=Vlw5OJcoxCC473z5moizI40ESYe+BpcMN2hU0iQoJwI= c=1 sm=1 a=Z3wfvi8l4dgA:10 a=IkcTkHD0fZMA:10 a=CL8lFSKtTFcA:10 a=i9M/sDlu2rpZ9XS819oYzg==:17 a=RqskG79H0WfgjqF_o3QA:9 a=ADoHyNiwQCuWYArXSBwA:7 a=6kRUgfnSSwfWw8JhDtmaKYXNYQEA:4 a=QEXdDO2ut3YA:10 a=_RhRFcbxBZMA:10 a=i9M/sDlu2rpZ9XS819oYzg==:117 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mailfe01.swip.net X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,BAYES_20 autolearn=ham version=3.3.1 X-TFF-CGPSA-Version: 1.7 X-T2-CGPSA-Filter: Scanned Received: from [188.126.198.129] (account mc467741@c2i.net HELO laptop002.hselasky.homeunix.org) by mailfe01.swip.net (CommuniGate Pro SMTP 5.2.19) with ESMTPA id 101340534; Wed, 16 Mar 2011 09:13:56 +0100 From: Hans Petter Selasky To: handygewinnspiel@gmx.de Date: Wed, 16 Mar 2011 09:13:22 +0100 User-Agent: KMail/1.13.5 (FreeBSD/8.2-PRERELEASE; KDE/4.4.5; amd64; ; ) References: <201103131605.51848.hselasky@c2i.net> <20110313170641.GA22812@triton8.kn-bremen.de> <20110315221902.173240@gmx.net> In-Reply-To: <20110315221902.173240@gmx.net> X-Face: *nPdTl_}RuAI6^PVpA02T?$%Xa^>@hE0uyUIoiha$pC:9TVgl.Oq, NwSZ4V"|LR.+tj}g5 %V,x^qOs~mnU3]Gn; cQLv&.N>TrxmSFf+p6(30a/{)KUU!s}w\IhQBj}[g}bj0I3^glmC( :AuzV9:.hESm-x4h240C`9=w MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201103160913.22501.hselasky@c2i.net> Cc: freebsd-multimedia@freebsd.org, Juergen Lock Subject: Re: [V4L-DVB] Add support for vendor specific DiSEqC switch "MAXIMUM DiSEqC 4/1 switch" X-BeenThere: freebsd-multimedia@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Multimedia discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 16 Mar 2011 08:14:02 -0000 On Tuesday 15 March 2011 23:19:02 handygewinnspiel@gmx.de wrote: > Hi Hans Petter, > > thank you for the patch, but i do have severe problems with it.. > Hi! > First of all, i have to explain that i dont have any access to sat > equipment at all - so i've to rely on understanding whats going on in even > small patches or pieces of w_scan as good as i can. What i don't > understand, i will not apply. Probably the patches needs to be applied by hand. > I cannot test anything sat related, i use terrestric and cable only. > I was trying to translate your settings for vdr diseqc.conf into human > readable things.. > LNB.A 11700 V 9750 t F W45 v W15 W45 F W45 v W15 W45 t W45 > The switch works like this that when the power is toggled, LNB.A is selected by default. > define command chain for 'LNB.A' && frequencies below 11700MHz (=lowband) > polarization vertical as follows > > 1) '9750' use LNB LO 9750MHz // OK, translate lowband > 10700MHz..11700MHz to 950MHz..1950MHz) 2) 't' 22kHz tone off // > this will select lowband on a multiband LNB. correct. 3) 'F' lnb > voltage off // why switching *off*, if we want to program the LNB? > wrong. 4) 'W45' wait 45msec // > 5) 'v' lnb voltage 13volts // vertival = 13V, correct. > 6) 'W15' wait 15msec // hmm.. > 7) 'W45' wait 45msec // ? wait again? and 45msec? 15 should > be enough by spec. 8) 'F' lnb voltage off // why again switching > LNB *off*? 9) 'W45' wait 45msec // wait again > 10) 'v' lnb voltage 13volts // vertival = 13V, correct. But that was > set before..? I'm confused. You lost me here completely.. 11) 'W15' > wait 15msec // hmm.. > 12) 'W45' wait 45msec // ? wait again? These commands where just a textual dump from the w_scan patches. I did not optimise anything. It is critical that the delay is in the range 45-50ms, else the programming does not work. > 13) 't' 22kHz tone off // if we hadnt switch off the LNB, we > wouldnt have to set it again to low band. 14) 'W45' wait 45msec > > I cannot find any diseqc switch related command here; so that means > something is intrinsic wrong on this line. As soon as a diseqc switch is > inside your equipment, it *has* to be controlled *every time* you change > satellite, low/high band or polarization. And it should be a 0x2X command > if i read the diseqc spec. That is the issue. The switch implements the diseqc signalling, but not the protocol. I did a complete protocol scan, testing all commands, and it only responded to 0x26 and 0x27. > If i compare to w_scan's patch it does.. > > 2) 22kHz tone off tone off > 3) lnb voltage off > 4) wait 45msec > 5) lnb voltage 13volts > 6) wait 15msec > 7) wait 45msec // that doesnt make sense to me. Right, this can be optimised. > 8) lnb voltage off > 9) wait 45msec > 10) lnb voltage 13volts > 11) wait 15msec > 12) wait 45msec > 13) 22kHz tone off > 14) // the wait 45msec is missing compared > to above. > > If i compare to the other switch positions, i can find two diseqc commands: > > MASTER_CMD_NO_RESPONSE, ADDR_ANY_LNB, 0x26, 0x00, 0x00, 0x00 // 0x26 -> > Select Satellite position B (or position D) MASTER_CMD_NO_RESPONSE, > ADDR_ANY_LNB, 0x27, 0x00, 0x00, 0x00 // 0x27 -> Select Switch Option B > (e.g. positions C/D) > > But what i'm actually missing is switching back to 'Option A', once you > switched to 'Option B'; in the same way i miss selecting position A/B: > > MASTER_CMD_NO_RESPONSE, ADDR_ANY_LNB, 0x22, 0x00, 0x00, 0x00 // 0x22 -> > Select Satellite position A (or position C) MASTER_CMD_NO_RESPONSE, > ADDR_ANY_LNB, 0x23, 0x00, 0x00, 0x00 // 0x23 -> Select Switch Option A > (e.g. positions A/B) The switch does not support these commands :-( Tested this pretty hard. > For me it looks like, that you try to circumvent in a wrong way using the > missing diseqc commands. If (only if..) i understand your coding > correctly, your switch looks like a 2x2 matrix. The first one selecting > A/B vs C/D, the second choosing the first or second of those preselected. > > >From a more general point of view.. > > - function name 'setup_kjaerulff1_switch' << i dislike naming which is not > self explaining. Naming should be consequently english. - a new command > line switch. I tend to remove command line switches rather than adding new > ones. Less is more. And even if a new is really necessary it should be '-D > Nx', with x a new character and N = 0..3 - the patch doesnt include the > new command line switch in the man page - function setup_switch should > handle this new kind of switch, but setup_kjaerulff1_switch should not be > called directly. - the '0x26' and '0x27' should use their already defined > macros: CMD_SET_POS_B and CMD_SET_SOB. Using this macros already gives me > hint, that you need CMD_SET_POS_A and CMD_SET_SOA also if you need the > others. Ok, should I generate a new patch for this? I'm not sure what class of switch I've got. Do you recognize the command set used? > at this point, i think i cannot integrate your current patch as it is. > Too many open questions, no datasheet and i cannot figure out by myself. Which sources must I generate a patch against? > If you could find out and answer the open questions, i would look again at > this topic. > > Thanks a lot for forwarding @ Juergen. > --HPS