From: Michel Verbraak <michel@verbraak.org>
To: linux-dvb@linuxtv.org
Subject: Re: [linux-dvb] How to find which command generates error in FE_SET_PROPERTY
Date: Sat, 08 Nov 2008 19:23:35 +0100 [thread overview]
Message-ID: <4915D927.1000806@verbraak.org> (raw)
In-Reply-To: <18991.1226167267@kewl.org>
[-- Attachment #1.1: Type: text/plain, Size: 1847 bytes --]
Darron Broad schreef:
> In message <4915C608.9000709@verbraak.org>, Michel Verbraak wrote:
>
> LO
>
>
>> I'm trying to modify one of my applications to use the new S2API. With
>> this application I control my dvb-t and dvb-s/s2 receivers.
>>
>> I'm using szap-s2 as an example but I run into a problem that the ioctl
>> FE_SET_PROPERTY always returns -1 and variable errno is set to 14.
>>
>> My question is. How do I determine which of the commands in the command
>> queue given to FE_SET_PROPERTY is producing this error. I did not try
>> yet to devide my command queue up into one command queue per command.
>>
>
> The only commands as such as CLEAR and TUNE, the rest are tuning
> parameters. The way this works is that the TUNE command informs
> the kernel to retune using the parameters specified. This occurs
> outside of the IOCTL call itself and you don't directly know
> if a paramater was wrong, it just doesn't work.
>
> The error you have:
>
>> grep 14 /usr/include/asm-generic/errno-base.h
>>
> #define EFAULT 14 /* Bad address */
>
> Suggests a problem in your code...
>
>
>> Regards,
>>
>> Michel.
>>
>> Part of source code for dvb-s/s2:
>>
>> #ifdef S2API
>> int TDVBDevice::SetProperty(struct dtv_property *cmdseq)
>>
>
> This should something like SetProperties(struct dtv_properties cmdseq[])
> and then call ioctl(fefd, FE_SET_PROPERTY, cmdseq)
> This sends of your args at the same time.
>
>
>> if (SetProperty(&p[0]) == 0)
>>
>
> That needs to be more like:
> SetProperties(&cmdseq)
>
> I hope that helps.
>
> cya!
>
> --
>
> // /
> {:)==={ Darron Broad <darron@kewl.org>
> \\ \
>
>
Darron,
You were right. The error I had to solve was to change
SetProperty(&p[0]) into SetProperty(&cmdseq).
I have been coding all day and missed this one.
Thanks,
Michel.
[-- Attachment #1.2: Type: text/html, Size: 2621 bytes --]
[-- Attachment #2: Type: text/plain, Size: 150 bytes --]
_______________________________________________
linux-dvb mailing list
linux-dvb@linuxtv.org
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb
prev parent reply other threads:[~2008-11-08 18:24 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-08 17:02 [linux-dvb] How to find which command generates error in FE_SET_PROPERTY Michel Verbraak
2008-11-08 18:01 ` Darron Broad
2008-11-08 18:23 ` Michel Verbraak [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4915D927.1000806@verbraak.org \
--to=michel@verbraak.org \
--cc=linux-dvb@linuxtv.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.