Re: [linux-dvb] Pinnacle PCTV Sat HDTV Pro USB (PCTV452e)

2007-10-29 Thread garlicdevel
 I'm also using 64-bit kernel and system, there shouldn't be issues due to 
 this.
 
 Dominik


I've just tried the new channels in channels.conf and it works spot on on Astra 
19.2E
this is the first time I've gotten video out of the device
so thanks to everyone with the help on this

I've also tried your patch against the newer stb manu tree and this works too

the code I've been working with doesn't seem to work however, it has problems 
with i2c which I need to fix
(some differences from the original ttusb driver)
although at least I've gotten the little green light to work :)

-
Email sent from www.virginmedia.com/email
Virus-checked using McAfee(R) Software and scanned for spam


___
linux-dvb mailing list
linux-dvb@linuxtv.org
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb


Re: [linux-dvb] Pinnacle PCTV Sat HDTV Pro USB (PCTV452e)

2007-10-28 Thread garlicdevel
 You can change the GPIO1 initialisation to 0x02 instead of 0x82. 
 this will switch the led to green when the frontend gets open()'ed.
 To switch it back to orange insert
  stb0899_write_reg(state, STB0899_GPIO01CFG, 0x82);
 in the stb0899_sleep() function.
 (this should be somehow limited to the pctv452e as the GPIOs might 
 have different meanings on other devices)
 
 Dominik

I've recently updated perl script to get the correct reg names
and uploaded a typical output from the script for tuning to BBC1 as output.log
this shows the order in which the registers are being set typically under the 
win environment to give us some more clues

I just spotted the above in the log for GPIO01CFG
and tried this out in the driver and it now works :) I had the values the wrong 
way round for orange / green
which is a relief (I was worried there might have been a bigger problem 
somewhere with setting the registers)
I've now set the light to come on during tuning / device access (this is 
usually the same time when there is power for the LNB)

updated the patch for stb0899_reg.h with a couple more minor changes (probably 
makes no difference)
based on the output of the win driver / the order the registers are set in
pulled off a newer release of stb0899 as the Unlocking error seemed to be a bit 
random
but this check has been removed recently I think

for szap the one I've been using is located here
http://abraham.manu.googlepages.com/szap.c
this is the latest one mentioned by manu
I've put up a small tar.bz2 file containing a script and the needed files to 
compile, just to make this easier for anyone who wants to try this


at the moment I'm slowly working my way through the registers and manu's code
to try and work out how everything fits together
I think I've got diseqc figured out now at least from looking at the log
pulled the diseqc specs from here http://www.eutelsat.com/satellites/4_5_5.html
The win driver appears to probe for any diseqc devices attached to the Bus 
using E2 00 00
the 00 specifies all devices on the bus and the E2 requires a response from any 
slaves attached looking at the specs

when nothing is found, the LNB power is switched on then the following command 
is issued E0 10 38 f0
I think this means set the switcher to the first position based on szap / specs
this looks like it's always the same which makes me think the win driver is 
ignoring the diseqc setting at the moment and always
selecting the first switch option

Also I think that when we init the FIFO register at the beginning this doesn't 
output onto the bus
as it looks as if the precharge bit has to be set within DISCNTRL1 before 
anything is output
It also looks as if the win driver writes values in a slightly different way
I think with the current linux code we enable precharge set one byte then 
disable precharge to send one at a time
with the win driver it looks as if it's possible to send more than one byte at 
a time into FIFO
set precharge, send in all the bytes to FIFO, unset precharge
DISSTATUS then counts down to zero, I think using the first 4 bits (could be 
wrong on this)
the 5th bit is set to on when data is still being sent (0x13, 0x12, 0x11) then 
the 6th bit is set as well when the fifo is
marked as clear (0x30)

still if it isn't broke don't fix it, if it works as is at the moment in the 
linux driver then this is good enough for me :)
I haven't got a switch in place but I do have a motor
I'll need to experiment with different commands later on to see if I can get 
the thing to move and twirl around using vdr

--Richard

-
Email sent from www.virginmedia.com/email
Virus-checked using McAfee(R) Software and scanned for spam


___
linux-dvb mailing list
linux-dvb@linuxtv.org
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb


Re: [linux-dvb] Pinnacle PCTV Sat HDTV Pro USB (PCTV452e)

2007-10-28 Thread garlicdevel

 
 From: Daniel Golle [EMAIL PROTECTED]
 Date: 2007/10/28 Sun PM 03:14:15 GMT
 To: linux-dvb@linuxtv.org
 Subject: Re: [linux-dvb] Pinnacle PCTV Sat HDTV Pro USB (PCTV452e)
 
 On Sun, 28 Oct 2007 10:54:32 +0100, [EMAIL PROTECTED] wrote:
  Are you sure you have used the DVB-S2 enabled szap?
  Manu posted a link a few days/weeks ago
  Currently only the new tuning API does work. 
 Thanks! 
 That was the missing piece of the puzzle! By using szap2 I can tune in
 and receive all DVB-S channels FTA on 19.2E, 
 cat dvr0 | mplayer 
 works almost perfectly; got some glitches from time to time, but that
 was just the same with the ttpci (with budget patch) I used before.
 
 -Daniel

wow you've managed to get this working?
can you list which driver your using, and which version of stb0899
I'm still trying to get video output from mine


-
Email sent from www.virginmedia.com/email
Virus-checked using McAfee(R) Software and scanned for spam


___
linux-dvb mailing list
linux-dvb@linuxtv.org
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb


Re: [linux-dvb] Pinnacle PCTV Sat HDTV Pro USB (PCTV452e)

2007-10-28 Thread garlicdevel

 
 From: Daniel Golle [EMAIL PROTECTED]
 Date: 2007/10/28 Sun PM 09:36:53 GMT
 To: linux-dvb@linuxtv.org
 Subject: Re: [linux-dvb] Pinnacle PCTV Sat HDTV Pro USB (PCTV452e)
 
 sorry, posted with a wrong subject before... (shame on me)
 On Sun, 28 Oct 2007 17:24:55 +, [EMAIL PROTECTED] wrote:
   Thanks! 
   That was the missing piece of the puzzle! By using szap2 I can tune
  in
   and receive all DVB-S channels FTA on 19.2E, 
   cat dvr0 | mplayer 
   works almost perfectly; got some glitches from time to time, but
  that
   was just the same with the ttpci (with budget patch) I used before.
   
   -Daniel
  
  wow you've managed to get this working?
  can you list which driver your using, and which version of stb0899
  I'm still trying to get video output from mine 
 I use:
 - Linux 2.6.22-ck1 on VIA Esther processor 1200MHz
 - stb0899 from http://linuxtv.org/hg/~manu/stb0899/ (last change on
 10-10-2007)
 - enable_pctv452e_20071021.patch posted by Dominik Kuhlen
 - I changed the initial value of register STB0899_I2CRPT to 0x58 as
 suggested by Dominik some hours after publishing the patch.
 - szap2 from http://dev.kewl.org/hvr4000/utils/szap2.tgz finally did the
 trick... (again, big thanks to Dominik for this hint!)
 
 szap2 -r -c /home/daniel/channels.conf -i
 tunes successfully to every DVB-S (but not -S2!) channel I ask it for.
 I can play the stream in /dev/dvb/adapter0/dvr0 with mplayer (actually,
 I do this on my router machine, the box the pinnacle is connected to:
 cat /dev/dvb/adapter0/dvr0 | nc -l -p 12345
 and this on my workstation:
 nc 192.168.XXX.XXX 12345 | mplayer -stop-xscreensaver -v -vo xv -vf
 tfields -
 ).
 
 got to restart netcat and mplayer everytime I tune to a different
 channel. I guess, this is more a problem with mplayer not expecting the
 TS to end/die unexpectedly...
 
 Also, I tried to compile szap2 using the headers included in manu's
 stb0899 code instead of the ones included in szap2, which did NOT work
 (tuner doesn't lock to channel).
 
 Anyway, just to mention, the LED seems to stay yellow at all times after
 plugging the device, but i don't care as i cannot see it anyway ;)
 
 btw: as dvbscan doesn't work yet with the new tuner api, I need an
 up-to-date channels.conf for 19.2E. somebody, please run dvbscan 
 and send me the result by email.
 
 -Daniel

thanks for the info this could save me a lot of time
I've tried the above out but I'm still getting no output from dvr0

at this point I'm not sure if it's because I'm using an amd64 system (perhaps 
non friendly 64bit code somewhere) or if the channel I'm trying to tune to is 
wrong in channels.conf

can you let me know the channel details you've used to tune on Astra 19.2E (the 
line used in channels.conf)
this way I can re-align the dish motor using an external decoder box then give 
it another go

-
Email sent from www.virginmedia.com/email
Virus-checked using McAfee(R) Software and scanned for spam


___
linux-dvb mailing list
linux-dvb@linuxtv.org
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb


Re: [linux-dvb] Pinnacle PCTV Sat HDTV Pro USB (PCTV452e)

2007-10-25 Thread garlicdevel

 
 From: Manu Abraham [EMAIL PROTECTED]
 Date: 2007/10/25 Thu AM 04:53:28 BST
 To: [EMAIL PROTECTED]
 CC: linux-dvb@linuxtv.org
 Subject: Re: [linux-dvb] Pinnacle PCTV Sat HDTV Pro USB (PCTV452e)
 
 [EMAIL PROTECTED] wrote:
  but I think the older driver could be better at the moment as with the 
  newer 
  driver the device doesn't appear to initialize for the stb0899
  hmm, i have checked both and they don't differ.
  
  there seems to be some more checks in the newer driver to make sure the 
  device is in the right state
  also looking at one of the newer budget devices that's using it, there 
  seems to be a whole bunch of defines added into the config structure
  I'm not sure if these are being used just yet (or if so what for)
  but I'm keeping my options open by trying things against both for now just 
  to be sure
  
  
  you are initialising STB0899_DISFIFO in line 51 with 0x00.
  this byte will be sent out after frontend_init() on the first diseqc 
  command.
  
  sorry about that
  the win driver appears to fill in a default set of values when the device 
  is plugged in
  this is what I've used in the data structure
  although if the stb driver doesn't change these again afterwards in the 
  same way the win driver does, then this won't work right
  I'll need to take a closer look at the values that are being set after the 
  initial plugin of the device
  looking at the logs for this one, it seems to be going mostly from 00 to 
  e2, with 10, 38, f0 near the end of the log
 
 You are right. In fact this is a FIFO, but initially it is initialized to 
 0x00 to avoid 
 garbage in the output. You are right as well that the FIFO is modified later 
 on 
 at run time, which you can see it in the driver. The FIFO is transferred only 
 when the precharge is discharged, till then whatever you have in the FIFO is 
 of no concern.
 
 You can see the FIFO being modified at runtime here (contrary to your claim 
 that the stb0899 driver doesn't modify the FIFO, well if it wouldn't have, 
 then 
 there wouldn't have been any diseqc commands sent)
 
 http://jusst.de/hg/multiproto/file/2c1aa7b57779/linux/drivers/media/dvb/frontends/stb0899_drv.c
 line #687 before the discharge
 
 Manu
 

I'm afraid I don't know much about how FIFO's tie in with the tuning of the LNB 
/ diseqc commands at this point, everything I'm seeing is just based on 
observation of the win driver
I know diseqc is used to to send commands to move the motor and can be used to 
send / recieve data from the LNB
but I'm wondering if diseqc would have been used in the windows log, as I left 
the setting empty for the A/B/C/D diseqc switch when selecting the channel
does diseqc have to be used to tune the LNB?

Also I've just reliased some of the changes to the register I've mentioned 
above will be incorrect anyway
I remembered afterwards that the perl script isn't taking account of the 
offsets when looking at the log to work out the register name

At the moment the default values match the initial values loaded by the win 
driver on hardware plugin
But I think I need to be looking at the values set later on during the actual 
tuning instead

I'm going to update the perl script to take account of the register names with 
offsets
then I'll add something in to create the structure set (contents of the priv 
header) based on the latest values instead of the earliest ones
this might also help identify how the different settings on a per channel basis 
in the win driver
as there seems to be a lot of drop down boxes / number settings that can be 
altered on a per channel basis (like circular polarisation for example)




-
Email sent from www.virginmedia.com/email
Virus-checked using McAfee(R) Software and scanned for spam


___
linux-dvb mailing list
linux-dvb@linuxtv.org
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb


Re: [linux-dvb] Pinnacle PCTV Sat HDTV Pro USB (PCTV452e)

2007-10-24 Thread garlicdevel
 Are you sure you have changed line 405 in pctv452e.c from
 { STB0899_I2CRPT, 0x5e }, // 0x2c
 to
 { STB0899_I2CRPT, 0x58 },
 as register 0xf12a is STB0899_I2CRPT and 0x5c should not appear there.
? (this is not included in my posted patch)
? 
? 
? Dominik

The windows driver seems to set the initial value to 5c when dumping all 
registers across initially (on device plug in)
it then seems to change things later on for tuning purposes
since I'd done an identical copy from the usbsnoop log this is how it ended up 
here

from grepping the log through the perl script
it seems to alternate back and forth from 5c to dc then back again
I've tried setting it to all 3 values and the results are the same (there 
doesn't seem to be any difference at this point)

I think the stb6100 / lnbp 22 is doing it's job correctly
i.e. when correct tuning parms are given the power stays on (looking at the sat 
meter)
result is status 00 | signal  | snr 0004 | ber  | unc fffe |
with incorrect tuning parameters the power comes on briefly then goes off 
again, then repeats as szap tries to tune

what's bugging me at the moment is if the loading of the initial set of values 
is identical to the win driver
this should set the LED from Orange to Green in the same way when the device is 
plugged in under win
but this isn't happening, which makes me think some of the registers aren't 
being set right for the stb0899
this has been true for every combination of driver / tree I've tried so far

still with the newer stb driver it did mention ANALOGUE CARRIER in the dmesg 
output
so I think we're getting closer

On another note
I've been using both the old and the new stb tree's
I've noticed by uncommenting the following lines in pctv452e_frontend_attach
I'm no longer getting Unlocked PLL messages from the new stb0899 driver and 
it is now attaching which is good

if (usb_set_interface(adap-dev-udev,0,3)  0)
err(set interface to alts=3 failed);

-
Email sent from www.virginmedia.com/email
Virus-checked using McAfee(R) Software and scanned for spam


-
Email sent from www.virginmedia.com/email
Virus-checked using McAfee(R) Software and scanned for spam


___
linux-dvb mailing list
linux-dvb@linuxtv.org
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb


Re: [linux-dvb] Pinnacle PCTV Sat HDTV Pro USB (PCTV452e)

2007-10-24 Thread garlicdevel
  but I think the older driver could be better at the moment as with the 
  newer 
 driver the device doesn't appear to initialize for the stb0899
 hmm, i have checked both and they don't differ.

there seems to be some more checks in the newer driver to make sure the device 
is in the right state
also looking at one of the newer budget devices that's using it, there seems to 
be a whole bunch of defines added into the config structure
I'm not sure if these are being used just yet (or if so what for)
but I'm keeping my options open by trying things against both for now just to 
be sure


 you are initialising STB0899_DISFIFO in line 51 with 0x00.
 this byte will be sent out after frontend_init() on the first diseqc command.

sorry about that
the win driver appears to fill in a default set of values when the device is 
plugged in
this is what I've used in the data structure
although if the stb driver doesn't change these again afterwards in the same 
way the win driver does, then this won't work right
I'll need to take a closer look at the values that are being set after the 
initial plugin of the device
looking at the logs for this one, it seems to be going mostly from 00 to e2, 
with 10, 38, f0 near the end of the log

  although I've noticed the LED is staying at orange when it should be going 
  green in both cases, which suggests the GPIO register isn't being set when 
  it should
 right, the stb0899 driver has no gpio set/unset API call so i left this out.

the problem is, if I've done an identical mirror of the initial values used in 
windows (just when the device is plugged in via USB)
then in theory the LED should be changing colour orange - Green, as one of 
those registers should be the GPIO pin to control it
when stb0899 does the attachment and copies the data structures across to the 
device the same thing should happen
ether I've made a mistake in the values somewhere, or something about the 
registers isn't being set right which would be a bigger problem


-
Email sent from www.virginmedia.com/email
Virus-checked using McAfee(R) Software and scanned for spam


___
linux-dvb mailing list
linux-dvb@linuxtv.org
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb


Re: [linux-dvb] Pinnacle PCTV Sat HDTV Pro USB (PCTV452e)

2007-10-23 Thread garlicdevel
On Sunday 21 October 2007 18:00, Dominik Kuhlen wrote:
 Hi, 
 On Thursday 18 October 2007 09:54, Daniel Golle wrote:
  hi all!
  
  i finally got the pinnacle device mentioned above, willing to
  contribute whatever i can to make it work under linux. As I have to
  study USB programming as a part of lab class, I hope to combine
  pratical and educative interests... :)
  
  please send me all known information about the device and let me know
  about exiting code (Dominik? Roland? Patrick? anybody?)
 
 Here it is: 
 A new try for a driver for the pctv452e usb device.
 
 What's working:
  - Remote control
  - LNB control (14/18v, 22kHz)
  - DiSEqC
 What's not working:
  - tuning (neither DVB-S nor DVB-S2) :(
  - reading data (which probably results from failing to tune)


I've been working on one of these myself
but you've beat me to it :)
I was in the middle up updating the init registers on the Sunday when I spotted 
this mail on the list

still I might have some useful info / input
to begin with I started out by writing a perl script to decode the output from 
usbsnoop for the 452e while using the win driver
(it's the first time I've written something in perl so it's a bit crude)
I've put it up here 
http://homepage.ntlworld.com/garlicbread/Projects/452e/USBsnoop_parse.tar.bz2
you just need to unpack / copy the usbsnoop.log into the extracted directory 
and run ./452e.1.pl | less
this should give a nice colorful output on the console as to what's going on
but be aware it doesn't always name the stb0899 registers properly because it 
doesn't yet take account of offsets
still the registers are set in the same order they're seen in the data 
structures so it's easy to figure out what's being set
note I wouldn't use it with any logs over 100Mb otherwise it'll eat your memory 
:)

for the results I've had with the mentioned patch above
with the dish pointed at Astra-28.2E
using a patched version of szap
or mplayer dvb://BBC1
with kernel 2.6.23

I've got a motor and a meter hooked in line with the dish so I can check for 
power on the line
without the right tuning info the power to the LNB flicks on for half a second 
at a time repeatedly until stopped
with the correct tuning info (I'm using BBC1:10773:v:0:22000:5000:5002:6301 
in channels.conf)
the power stays on and is constant with the correct polarity setting

this suggests it is tuning
but there's no visible power output reading from szap, or mpeg output from 
mplayer
so I'm not sure what needs looking at next


Next I've noticed that you've used the old stb0899 repo hg clone 
http://linuxtv.org/hg/~manu/stb0899
For info I've spotted a newer repo over here http://jusst.de/hg/multiproto/ 
(spotted in one of manu's mails about multiproto)
but I think the older driver could be better at the moment as with the newer 
driver the device doesn't appear to initialize for the stb0899

also I hope you don't mind
but I took some of the changes and combined it with the driver I've been 
working with
http://homepage.ntlworld.com/garlicbread/Projects/452e/patches/

1. lnbp22.patch -  this is from the patch above, it's better than the one I'd 
setup so I've left this as is
2. pctv452e_initreg.patch - separate header file containing the registers to be 
sent to the device on init
I think this is more up to date because it's based off the usbsnoop logs with 
the win driver
but I need to give it one more final sanity check to be sure
3. stb0899_tstrs3.patch - minor change to one of the registers I've spotted 
while trailing through the usb logs
4. stb0899_misc.patch - changes you've made to the stb0899 driver (originally 
part of the above patch)

3. pctv452e_main.patch - a combination of the above driver and some code I've 
been working with
it's basically a slightly changed version of the more recent ttusb driver
with bits of code from the above patch (remote control especially, this does 
work with evtest)
the newer budget driver in manu's tree (another func added for the stb6100) 
with some other bits

at this point the results are the same (meter lights up but not much else)
so I can't say if this is better or worse at this point
although I've noticed the LED is staying at orange when it should be going 
green in both cases, which suggests the GPIO register isn't being set when it 
should

quick question has anyone managed to get any kind of visible video output from 
the device at this point?
I'm wondering if the mpeg stream settings (for the iso transfer) need tweaking 
(I'm not sure if the endpoint or some other setting is set correct)


-
Email sent from www.virginmedia.com/email
Virus-checked using McAfee(R) Software and scanned for spam


___
linux-dvb mailing list
linux-dvb@linuxtv.org
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb