From: Richard Purdie <rpurdie@rpsys.net>
To: Jan Kratochvil <honza@jikos.cz>
Cc: Pavel Machek <pavel@ucw.cz>, dtor@mail.ru, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Support for controlling leds on xbox 360 pad.
Date: Thu, 31 May 2007 17:09:26 +0100 [thread overview]
Message-ID: <1180627767.5863.80.camel@localhost.localdomain> (raw)
In-Reply-To: <alpine.LRH.0.98.0705311740520.22353@twin.jikos.cz>
Hi,
On Thu, 2007-05-31 at 17:53 +0200, Jan Kratochvil wrote:
> On Thu, 31 May 2007, Pavel Machek wrote:
> >> Led subsystem allows us to set brightness, but there is
> >> nothing like brightness on this device. So brightness is
> >> actually interpreted as the command (only values between
> >> 0 and 14 are accepted).
> >
> > Ugh, no, I do not think we want to do that.
>
> finally! I was surprised that it took so long before someone made objection to
> this.
:)
This hadn't gone unnoticed by me and I didn't like it either at first
however I had a look at the hardware specs and your summary below is
pretty accurate...
> I agree that interpreting brightness as command isn't nice. But what other
> options do I have?
> a) Do not use led subystem, and do everything on my own
> b) Do not allow user to change state of leds on this device
> c) Extend led subsystem to have something like command. But it is in
> contradiction with desired simplicity of led sybsystem.
Since the commands are so device specific and no new device will be the
same, I doubt this is worth doing (or possible) in a generic way so
you're back to a).
> d) Control leds via force feedback effect
> e) Make 4 leds available and use brightness 0 for off and 255 for on. But only
> one of them can be active at one time. And I'll give up some flashing effects.
If you expose 4 leds, you break the API badly as only one can be active.
That is worse than using the brightness parameter IMO.
> Well actually I don't like this options. Any suggestions? Thanks!
After consideration, I agree with your approach of using the brightness
and I don't have a better suggestion. Its not ideal but its a good
compromise since it doesn't really impose any limitations on your use of
the hardware but doesn't need a custom implementation which is the
alternative. The mode is still a kind of brightness setting if you twist
the definition a bit ;-).
Cheers,
Richard
prev parent reply other threads:[~2007-05-31 16:10 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-29 21:11 [PATCH] Support for controlling leds on xbox 360 pad Jan Kratochvil
2007-05-29 21:29 ` Jan Kratochvil
2007-05-29 21:41 ` Richard Purdie
2007-05-30 3:17 ` Dmitry Torokhov
2007-05-30 14:56 ` Dmitry Torokhov
2007-05-30 16:32 ` Richard Purdie
2007-05-30 21:37 ` Jan Kratochvil
2007-06-03 18:02 ` Jan Kratochvil
2007-06-03 18:07 ` Jan Kratochvil
2007-06-15 4:15 ` Dmitry Torokhov
2007-06-15 5:06 ` Dmitry Torokhov
2007-05-31 14:07 ` Pavel Machek
2007-05-31 15:53 ` Jan Kratochvil
2007-05-31 16:09 ` Richard Purdie [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=1180627767.5863.80.camel@localhost.localdomain \
--to=rpurdie@rpsys.net \
--cc=dtor@mail.ru \
--cc=honza@jikos.cz \
--cc=linux-kernel@vger.kernel.org \
--cc=pavel@ucw.cz \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox