Emard, thank your to your reply. But your patch seems not to be useful for me since it does not exit the szap running with -r option (as you wrote in december), which is my case.
I think I already found the solution usable in scripts without modding the szap: #!/bin/bash szap -r ZDF & #szap has to be running in the background $timelimit=5 read -t $timelimit signal < /dev/dvb/adapter0/dvr0 if [ -z "$signal" ] then echo "No signal!" else echo "Signal found!" fi Signal is considered having some data in /dev/dvb/adapter0/dvr0. When read finds some data in /dev/dvb/adapter0/dvr0, script continues immediately. When read cannot finds data, it tries it again for the specified timelimit. Then it continues. It works great! ----- Puvodn� zpr�va ----- Od: <[EMAIL PROTECTED]> Komu: "Jiri Netopil" <[EMAIL PROTECTED]> Kopie: <[EMAIL PROTECTED]> Odesl�no: 12. �nora 2003 11:01 Predmet: [linux-dvb] Re: How to check signal after szap? > Jiri Netopil writes: > > > I am making a bash script for tunning DVB Nova card. I am using szap for > > tunning and I would like to check if there is signal after szaping to > > desired channel (because I would like to tune to the previous used channel > > when there is no signal). Of course it can be recognised from the szap > > output to screen (FE_HAS _LOCK or somehow like this), but it cannot be > > tested in script. I have been trying several things such as redirect the > > output from szap to file, to check the data in /dev/dvb/adapter0/dvr0 and so > > on, but without any success. I am new in Linux and I already tried all my > > few ideas. > > > > Does anyone have any idea here? > > I do. szap has to be patched a bit in order that it returns > after successful tuning. I posted a patch but it should be > a bit more intelligent (it should check for 5-6 ber=0 in > succession instead of just one). > > After szap exits, FE will remain active for 3 seconds > so there can follow some short dvr read, e.g. alevt-date > or similar call with the card still active during this > 3 seconds. > > Emard > > > -- > Info: > To unsubscribe send a mail to [EMAIL PROTECTED] with "unsubscribe linux-dvb" as subject. > -- Info: To unsubscribe send a mail to [EMAIL PROTECTED] with "unsubscribe linux-dvb" as subject.
