laasa schrieb:
Christian Schuld schrieb:
Hello Laasa,
On Mittwoch, 9. Mai 2007, laasa wrote:
[ ... ]
When I read this dump correct and it is my second linux dump I ever
seen, then in the function stb6100_set_frequency occures a divide by
zero exception.
There are only 2 lines in the function stb6100_set_frequency where a
division was made. In both lines the a divison by state->reference
was made.
So I think that state->reference is zero, but normaly it was
initialized before in stb6100_init.
3 ideas:
1) a printk in stb6100_init to see, if the function was called (and
leave) before stb6100_set_frequency (or exception happens).
stb6100_init never gets called.
2) there is the possibility to give state->reference via
stb6100_attach via the config-parameter refclock in budget-ci.c:
struct stb6100_config tt3200_stb6100_config = {
.tuner_address = 0x60,
.refclock = 27000000,
};
That does the trick. Thanks :-)
But now szap2 doesn't work :-(
It produces an output like that on every transponder it try to tune to:
$ szap2 -a 1 "Prosieben"
zapping to 148 'ProSieben':
sat 0, frequency = 12480 MHz V, symbolrate 27500000, vpid = 0x00ff,
apid = 0x0100 sid = 0x0382 (fec = -2147483648, mod = 2)
Querying info .. Delivery system=DVB-S
using '/dev/dvb/adapter1/frontend0' and '/dev/dvb/adapter1/demux0'
----------------------------------> Using 'STB0899 DVB-S' DVB-S
diseqc: sat_no:0 pol_vert:1 hi_band:1 cmd:e0 10 38 f1 wait:0
do_tune: API version=2, delivery system = 0
do_tune: Frequency = 1880000, Srate = 27500000 (DVB-S)
do_tune: Frequency = 1880000, Srate = 27500000 (SET_PARAMS)
status 00 | signal 0000 | snr 0004 | ber 00000000 | unc fffffffe |
status 00 | signal 0000 | snr 0004 | ber 00000000 | unc fffffffe |
[...]
Christian
_______________________________________________
linux-dvb mailing list
linux-dvb@xxxxxxxxxxx
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb
Christian,
sorry for the delay.
two things:
- For me it is not clear that stb6100_init never gets called. Normally
it is called in dvb_frontend_init (fe->ops.tuner_ops.init).
=> Can you check (e.g. with additional printk)?
=> May be it helps to call stb6100_init in stb6100_attach.
- Second is the hint in
http://www.linuxtv.org/pipermail/linux-dvb/2007-May/017921.html to
setup gpio:
case 0x1019: // TT S2-3200 PCI
// gpio2 is connected to CLB - reset it + leave it high
saa7146_setgpio(budget_ci->budget.dev, 2, SAA7146_GPIO_OUTLO);
msleep(1);
saa7146_setgpio(budget_ci->budget.dev, 2, SAA7146_GPIO_OUTHI);
msleep(1);
budget_ci->budget.dvb_frontend = dvb_attach(stb0899_attach,
...
Hope it helps.
_______________________________________________
linux-dvb mailing list
linux-dvb@xxxxxxxxxxx
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb
Another thing to get better tuning is this code patch. But this is only
a speed hack and no end solution.
I get now all DVB-S-channels :-) For DVB-S2-channels it does not help :-(
function stb0899_dvbs_algo in modul stb0899_algo.c
...
/* release stream merger RESET */
reg = stb0899_read_reg(state, STB0899_TSTRES);
STB0899_SETFIELD_VAL(FRESRS, reg, 0);
stb0899_write_reg(state, STB0899_TSTRES, reg);
/* TODO: */
if ( ((internal->freq > 1870000) && (internal->freq < 1890000))
|| ((internal->freq > 1570000) && (internal->freq < 1590000))
|| ((internal->freq > 1500000) && (internal->freq < 1520000))
)
{ /* special for ProSieben, RTL ... */
printk("%s: special for
frequency=%d\n",__func__,internal->freq);
}
else
{
/* disable carrier detector */
reg = stb0899_read_reg(state, STB0899_CFD);
STB0899_SETFIELD_VAL(CFD_ON, reg, 0);
stb0899_write_reg(state, STB0899_RTF, reg);
}
stb0899_read_regs(state, STB0899_EQUAI1, eq_const, 10);
...
----------------------------------------------------------------------------------
To get tuning more stable, it helps to have an retry in
STB6100_set_frequency:
enum stb0899_status stb0899_dvbs_algo(struct stb0899_state *state)
{
...
s32 retry = 0;
..
stb0899_first_subrange(state);
do {
retry = 0;
do
{
...
}
while ( ++retry < 5 && (internal->status != RANGEOK) );
if (internal->status != RANGEOK)
next_sub_range(state);
} while (internal->sub_range && internal->status != RANGEOK);
...
Hope it helps.
_______________________________________________
linux-dvb mailing list
linux-dvb@xxxxxxxxxxx
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb