Posts by green-bright-eyes

    Never seen this boxkey option. Do you refer to the Tivusat reader or to srg one?


    But the my main question is: this configuration perfectly works if I delete every other readers!

    Only, I have this little problem (actually, is not so severe) that other readers intervene for the very first seconds of decrypting, after each zapping.

    Before going on, I want to precise the thread title: I manage to use both my cards Tivusat and Swiss but, after zapping to one of those channels, for a few seconds Oscam use the other readers. Only after a few seconds, I see the Server: local: 0 message.

    Why's that?

    I've tried many options, weight balance and everything. But nothing. Even if it behaves like I said, I'd like to know how to immediately have those channels decoded by their cards.

    Here are my configuration files.



    oscam.server


    [reader]

    label = tivusat

    protocol = internal

    device = /dev/sci0

    caid = 183E,183D

    rsakey = A92DA72FEEACF2947B003ED652153B189E4043B0138C368BDF6B9ED77DDAD6C0761A2198AEB3FC97A19C9D01CA769B3FFFE4F6E70FA4E0696A8980E18D8C58E11D817121346E3E66457FDD84CFA72589B25B538EFC304361B54845F39E9EFA52D805E5FD86B595B366C35716ABC91FA3DC159C9F4D8164B5

    detect = cd

    nagra_read = 2

    mhz = 450

    cardmhz = 2700

    ident = 183D:000000,005411;183E:000000,005411

    group = 1

    emmcache = 1,2,2,0

    blockemm-unknown = 1

    blockemm-g = 1

    lb_weight = 1000

    lb_force_fallback = 1

    auprovid = 005411


    [reader]

    label = SRGv6

    protocol = internal

    device = /dev/sci1

    caid = 0500

    detect = cd

    mhz = 450

    cardmhz = 2700

    ident = 0500:060200,060210

    group = 1

    emmcache = 1,3,2,0

    lb_weight = 1000

    lb_force_fallback = 1

    auprovid = 060200



    oscam.user


    [account]

    user = CARD

    group = 1,2,3,4,5

    au = 1

    I use OBH 4.3 and this is the wget output.

    GNU Wget 1.19.5, a non-interactive network retriever.


    I decided to base my check only on the existence of ecm.info, which I (wrongly) believed it was created by the wget command you showed me. Instead, it is created by the decoding itself.

    So, by this two simple lines


    FILE=/var/volatile/tmp/ecm.info

    if test -f "$FILE"

    .....


    I got to my target.

    And, also, is not based on the box IP or its username and password. This way I can pass it on some friends without having to edit anything.


    Actually, the perfect and ultimate solution would be to know if the Oscam is running only because I'm watching or streaming a channel that needs it, or because there is a recording active and which is using Oscam.

    At the moment I can only know if a recording is active (by a wget command based on active timers) and, now, if oscam is decoding.

    But it might be that the recording is on on a FTA channel and the oscam is decoding because I'm watching a channel...


    All of this is to prevent an oscam restart while I'm recording a that needs Oscam to be running (without interruption

    This script produced only the file

    ecm.info

    in /var/volatile/tmp


    but no output. And, as I said before, the file is created only if this wget command is launched while oscam is decoding and is deleted if oscam is not decoding.

    So, as an alternative to the "output method" I talked about in my previous post, I used the command TEST to simply check if this file exists or not.

    And it works ;)


    So, many many many thanks: your help was decisive, although in a different way in respect to your initial idea.

    But here, what matters is the solution!

    I was enlightened by your line

    http://192.168.x.x:8888/oscamapi.html?part=status

    (obviously with my box IP and oscam port)


    and I actually think there is a much simpler way. Using this line in my browser, it showed this output when oscam did not decode any channel


    OK OK CARDOK CARDOK CARDOK CONNECTED ERROR CONNECTED ERROR CONNECTED CONNECTED OFF ERROR ERROR CONNECTED ERROR UNKNOWN ERROR CONNECTED CONNECTED CONNECTED ERROR ERROR CONNECTED CONNECTED CONNECTED CONNECTED UNKNOWN OFF


    but this other output when oscam if it was decoding a channel


    OK OK CARDOK unknown CARDOK CARDOK CONNECTED ERROR unknown CONNECTED ERROR unknown CONNECTED CONNECTED OFF ERROR ERROR CONNECTED OFF UNKNOWN OFF unknown CONNECTED CONNECTED CONNECTED ERROR ERROR CONNECTED unknown CONNECTED unknown CONNECTED CONNECTED UNKNOWN OFF unknown OK


    where the only difference is the presence of the string "unknown OK" only in this second case.

    So I thought I could use a wget or a grep command to copy this output into a file in order to check for this string.

    But clearly my linux commands knowledge is too limited at the moment and I didn't manage to do that.


    For instance, among many other tries, I did an attempt by this command:


    Output=$(wget -q -O - "http://MY_USERNAME:MY_PASSWORD@x.y.w.z:MY_PORT" | sed -n '1,/unknown OK/ p')


    but it gets into an error. How may I get this http output into a string or a file?

    I'll check your script or examine it as soon as possible.

    I understand your point but in my case it wouldn't do what I need because there's a script running every some hours that needs to know, as its last operation, if it can also restart oscam and, at the moment, it does based on the simple fact that there is no recordings going on, regardless of the fact the recording is only from a FTA channel or not.

    If I could know if oscam is actually and actively decoding, the script would restart oscam in case of FTA, whilst now it just does not restart not to risk to ruin the recordings.

    If I simply checked if the box were in standby, I simply did not have the oscam restart even if possible.

    Here is not the oscam the main actor of the problem, but the possible ruining of a recording ;)

    I'm looking forward to get into your script ;)

    First of all I apologize for my late reply, but I couldn't examine and study your script before.

    Then, I really want to thank you for the effort you specifically did for me, editing your script, I really apreeciated it.


    I actually needed much less, because I have a script which perform a series of operation.

    So, I only needed to read if any of the readers is engaged and assign this to a variable.

    Depending on it I'll then have various commands.


    I saw that this command:

    cat /tmp/test-oscam-api.xml | sed -rn '/name="'$READER_LABEL'"/,/times/p'


    creates a file which would be useful, indeed, ecm.info which contains, above all, the reader used at the moment.

    And I thought I could use it by the sed command.

    But, the problem is that it deletes the file when no readers is used (that means Oscam is not actually used, at moment, by a channel or a recording going on).

    My knowledge of sed command is limited and I tried different options but I did not manage to avoid the deleting of ecm.info.

    Is that possible. Or is simply possible to have a way for a sort of yes/no answer to the question: is Oscam decrypting any channels at the moment?

    I've been using oscam for some years, so far, and it correctly uses either my tivusat or my SRG card, in their slot.

    In the [global] section of oscam.conf, of course, I have


    preferlocalcards = 2


    to avoid the use of the other readers for those providers.

    Then, the other day, I decided to try the new files from post #23. And, because of oscam.dvbapi, it started using readers for some of the tivusat channels (whilst RSI-SRG were always OK, by the card).

    The behaviour was odd because only some of RAI channels, like RaiNews24 HD or RaiScuola HD (and a few others) used the readers; along with them, Some Mediaset HD ones.

    Deleting some lines from oscam.dvbapi (referred to 09CD) some of those channels were "fixed" (meaning they started using the tivusat card) but some others not. To solve the problem and go back to the perfect situation, I had to delete every lines referred to Sk*Italia.


    This is not satisfactory: why the preferlocalcards = 2 has not the priority over something else in order to force tivusat decoding by the smartcard?


    The complete oscam.conf is:


    [global]

    nice = -10

    waitforcards = 1

    preferlocalcards = 2

    logfile = /var/log/oscam.log

    maxlogsize = 500

    reload_readers = 1


    [cccam]

    port = 12000

    nodeid = 6B516F3010DF147E

    version = 2.3.0

    reshare = 1

    stealth = 1


    [dvbapi]

    enabled = 1

    au = 1

    pmt_mode = 0

    user = dvbapi

    boxtype = dreambox


    Thanks.

    I have a VU+Solo4K equipped by OBH 4.3.

    Actually I had already wrote my need, in the last line of my previous post: "I simply need to reload readers after another script updates them".

    It means that I do a renew of the file oscam.server which rewrites it and changes all the [reader] sections.

    So, at the end of this process, I need to either restart Oscam or re-read ALL the cccam readers. This second options would be preferable, in my view.

    So, oscam is used only as a local reader and for only one user.


    I noticed in your line (where, obviously I put my data, that there it end by

    ...reader_sci0

    It refers to my slots, I suppose.

    My two slots for smartcards are both used but oscam is used also with ccam readers.


    Using your line actually re-reads the cccam readers but, after some minutes, oscam stops (and you can see that from the webinterface or by the fact the channels it manages stop working.

    After a few tries, where it seemed that the command wget managed to reload the readers, I must say that, although it actually does it, after a few minutes the oscam stops working.

    This happens either launching it as a script from the script panel, or by the Cron Manager.

    The idea of simply reload the readers is exactly what I need, because it's not a problem of testing if it's running or not. As you said, oscam never stops working.

    I simply need to reload readers after another script updates them ;)

    Any other solution?

    Since I installed OBH 4.1 I have some strange behaviours with the same oscam that perfectly works under OBH 1.0.x or BH.

    While zapping sometimes I can get only the audio from the channel I zapped to, something that cannot happen if there is a real issue. If so you can't see or hear anything.

    Not only: if you go on zapping and immediately go back to the channel you cannot see (but only hear from) it perfectly works.

    As the same files and configurations still perfectly works under previous OBH or current BH, It seems just a sort of "timing" issue or something like that.

    Has anyone experienced the same behaviour with OBH 4.1?

    Since I installed the new OBH 4.1 In my Solo4K, Oscam began acting a bit oddly because it happens significantly often that a channel produces only the audio, although the OpenWebIf shows all it's OK. If you just zap to whatever channel, even FTA or DTT, and then zap back, it immediately works fine. But then it can occur, absolutely randomly, for other channels. Again, whatever zapping and zapping back, gives the video, too...

    My version shows:
    OSCam r11280_733

    and, at the bottom,

    1.20-unstable_svn

    Should I use a more recent version? As I said, all began with OBH 4.1. while it still works fine with BH or OBH 1.0.x.

    Yes, my upload is now 21Mbit/sec, that's why I'd like to take advantage also of a public static IP.

    So, let's say my static IP is

    88.88.88.88

    and I create a rule in my router

    how I'll be able to access my box? Entering in a browser

    88.88.88.88:8001

    or do I need also to specify something else?

    And then, how to choose a specific service to be streamed?