Re: [PATCH] leds: leds-mc13783: Fix MC13892 keypad led access

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

 




On Mon, 10 Oct 2016, Jacek Anaszewski wrote:

> Hi Alexander,
> > > It should write value << 3 to the register 52.
> > > 
> > > According to the documentation [0] LEDKP0, LEDKP1 and LEDKP2
> > > are driven by bits 9,10 and 11 respectively. The calculations
> > > don't seem to be in line with that. Could you point what I
> > > am missing?
LEDKP0, LEDKP1 and LEDKP2 controlles the led current setting, but ...

> > > 
> > > [0] http://www.nxp.com/files/analog/doc/data_sheet/MC13892.pdf
> > 
> > The numbering mentioned in the DT documentation is used as offset
> > for the device specific struct mc13xxx_led_devtype.led_min
> > >                if (of_property_read_u32(child, "reg", &tmp))
> > >                        continue;
> > >                pdata->led[i].id = leds->devtype->led_min + tmp;
> > e.g. MC13892_LED_KP = MC13892_LED_MD + 2
> > 
> > Hope this clarifies your question,
> 
> Thanks but not entirely - what with the second part of question related
> to the register layout?
The LED brightness is controlled via the duty cycle bits allowing
64 brightness values, setting bits/registers like
LED  | reg | bits
-----+-----+------
main | 0   | 3..8
aux  | 0   | 15..20
kp   | 1   | 3..8
red  | 2   | 3..8
green| 2   | 15..20
blue | 3   | 3..8

hope to got your question right,
 cheers, Alexander
> 
> -- 
> Best regards,
> Jacek Anaszewski
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-leds" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux