linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Single gpio shared by LED and switch?
@ 2015-09-01 17:00 Geert Uytterhoeven
  2015-09-07 13:03 ` Jacek Anaszewski
  0 siblings, 1 reply; 7+ messages in thread
From: Geert Uytterhoeven @ 2015-09-01 17:00 UTC (permalink / raw)
  To: Linus Walleij; +Cc: linux-gpio@vger.kernel.org, linux-leds@vger.kernel.org

Hi,

I'm wondering if there already exists a driver for a gpio that's connected
to both an LED and an input switch.

I'd expect such a hardware configuration to be fairly common, as gpios can be
a limited resource.
Most of the time the gpio would be in output mode, driving the LED, but at
regular intervals the mode would be changed for a very short moment to input,
to monitor the state of the switch.

I had a quick look at various drivers (and of course at
Documentation/gpio/drivers-on-gpio.txt), but couldn't find any.

Does such a hybrid of "leds-gpio" and "gpio-keys(-polled)" already exists?

Thanks in advance!

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2015-09-09  7:35 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-09-01 17:00 Single gpio shared by LED and switch? Geert Uytterhoeven
2015-09-07 13:03 ` Jacek Anaszewski
2015-09-07 13:22   ` Geert Uytterhoeven
2015-09-08 10:51     ` Jacek Anaszewski
2015-09-08 14:37       ` Linus Walleij
2015-09-09  7:25         ` Jacek Anaszewski
2015-09-09  7:35           ` Geert Uytterhoeven

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).