[lkml]   [2006]   [Feb]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRE: [PATCH 0/12] LED Class, Triggers and Drivers
From: Richard Purdie []
>This is an updated version of the LED class/subsystem. The main change
>is the renamed API - I've settled on led_device -> led_classdev. Other
>minor issues like the error cases in the timer trigger were also fixed.

In the previous version 'frequency' for the timer trigger was actually
half the period of the oscillation - the time in ms between each (on/off)
state transition.

In this version 'frequency' is the frequency of the oscillation in Hz.

That creates a big problem for me because the value is parsed as an
integer and I can no longer achieve slow flash rates (<1Hz). Since I
have to be able to do this I made a fairly crude patch to store the
frequency in mHz, not Hz, and to handle a decimal point in the value.

Possible fixes:

1) Use 'period' not 'frequency' and accept a value in ms (as before,
but with the off-by-2 error corrected.)
2) Use 'mark' and 'space' or 'time_on', 'time_off' or something similar
and remove 'duty' (I *do* need flashing with duty cycle != 0.5)
3) Accept fractional frequency (as in my patch).
4) Provide both period and frequency as integers and accept that
long period flashs will come out as frequency '1' (but the period
would still need to be in ms, because periods about 1500ms are of
significant utility.)

John Bowler <>

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2006-02-05 21:12    [W:0.055 / U:3.700 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site