Re: ipw srcipts for hal

On 6/25/07, yelo_3 <yelo_3 yahoo it> wrote:
> already added in the cleaned up version I sended in my second mail.
sorry, I sent the email before receiving the new version

ok, np

> this check wouldn't work. when you write a value to the file it can be 0,1,2 or 3 depending on the hwkillswitch and if it worked at all.
this check is important because:
you can only write 0 or 1 to that file
if you have hardware killed your card, you cannot enable it using software, as documented in README
sometimes the write could fail for other reasons

So if we need a more complex check we should do it:
if you wrote 0 and the file content is different than 0 the method failed
if you wrote 1 and the file content is 0 the mehod failed

that not what I meant...
this is not a "real file" the values that you write to it must not be the same when you read them again.
try this:
echo 1 to the file while the card is killed by the hw kill switch
it will contain 3 not 1.
we have to check for this cases too.

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]