Searching \ for '[EE]: was PIC: Non linear PWM of LEDs' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/microchip/ios.htm?key=pwm
Search entire site for: 'was PIC: Non linear PWM of LEDs'.

Exact match. Not showing close matches.
PICList Thread
'[EE]: was PIC: Non linear PWM of LEDs'
2003\02\11@125248 by Hazelwood Lyle

flavicon
face
>At 9:35 PM -0600 2/10/03, Josh Koffman wrote:
>>Second part is that the curve I'm looking for is not a straight
>>logarithmic curve. On a graph, it looks more like a stretched out "S".
>>The slope of the curve is more extreme in the center of the graph,
with
{Quote hidden}

I have been watching this thread carefully, perhaps to apply something useful to a PIC controlled light dimmer. I understand
that an exponential curve should appear smoother to the eye. I found the spreadsheet techniques quite enlightening.

This topic has been for DC control, I'm considering how phase
control of a TRIAC for AC control would complicate the issue.

If I want to control a triac for AC light bulb control, wouldn't I then need to devise a lookup table that takes into account the integral of a sine wave, with the end result (hopefully) resembling a Log curve to appear "smooth" to the human eye?

I've been consumed with this for 24 hours now, and I'll readily admit that the math is beyond my education. I have done a few hours of web research and asked a few engineering friends if they can help, too.

My goal at this point is a method for computing a table of values that would describe the delay time after each zero crossing to fire the triac, in hopes that the light output from the bulb would _appear_ to brighten at a steady rate.(Log?) In my case, for 60Hz power.

For those better educated than myself, (that should be all of you) please pardon my poor description of the problem. Given that yesterday,
I couldn't even define "integral of a sine", I'm struggling along the best I can.

Lyle Hazelwood

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads

2003\02\11@132136 by Olin Lathrop

face picon face
>>
If I want to control a triac for AC light bulb control, wouldn't
I then need to devise a lookup table that takes into account the
integral of a sine wave, with the end result (hopefully)
resembling a Log curve to appear "smooth" to the human eye?
<<

We had been talking about LEDs, not incandescent light bulbs.  Those are a
very differrent problem because the light output of an LED is linear with
current, but that is far from true about an incandescent bulb.  I should
be able to predict the response curve reasonably well from black body
radiation theory and knowing the "color temperature" at an operating
point.  However, it would probably be easier just to measure it.

I think most dimmers simply ignore the problem and advance the firing
angle linearly from the user input.


*****************************************************************
Embed Inc, embedded system specialists in Littleton Massachusetts
(978) 742-9014, http://www.embedinc.com

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads

2003\02\11@135315 by John Dammeyer

flavicon
face
Check the archives of Circuit Cellar Magazine.  There was an article
about triac dimming theatre lights that should solve your problems.

John Dammeyer



Wireless CAN with the CANRF module now available.
http://www.autoartisans.com/products
Automation Artisans Inc.
Ph. 1 250 544 4950


> {Original Message removed}

2003\02\11@135319 by Josh Koffman

flavicon
face
Comments within

Olin Lathrop wrote:
> We had been talking about LEDs, not incandescent light bulbs.  Those are a
> very differrent problem because the light output of an LED is linear with
> current, but that is far from true about an incandescent bulb.  I should
> be able to predict the response curve reasonably well from black body
> radiation theory and knowing the "color temperature" at an operating
> point.  However, it would probably be easier just to measure it.

This I wasn't exactly clear on until now. Thanks Olin. I guess I can
abandon the S curve stuff I've been thinking about. I suppose that's
what comes when I'm basing much of my research on research I did for
incandescent dimming. I still don't have a method to accomplish the log
dimming of the LEDs yet, but it will come I hope :)

> I think most dimmers simply ignore the problem and advance the firing
> angle linearly from the user input.

I would guess that most home dimmers do this. Theatrical dimmers are a
different story. The curve is deliberately modified in most (half
decent) theatrical dimmers. The idea is to give the user more control
over the light at the top and bottom ends of the curve I believe. This
helps to eliminate the phenomenon where once you get to about 70% of
control value, there doesn't seem to be much percievable change until
100%.

Well, back to trying to understand Scott's latest posting :)

Josh
--
A common mistake that people make when trying to design something
completely foolproof is to underestimate the ingenuity of complete
fools.
       -Douglas Adams

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads

2003\02\11@141139 by R. Michael O'Bannon, Ph.D.

picon face
Josh,

I think you want to take a brief foray into psychophysics.
The function is not an s-curve.  Take a look at Steven's
Power Law.  These links should get you started:

www.psychology.adelaide.edu.au/psychophysics/Library/
FD99/Contribute/Stevensetal.pdf

nersp.nerdc.ufl.edu/~ufruss/Research%20Design/magnitu
de%20scaling.htm

Best regards,
Michael

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads

2003\02\11@185843 by William Chops Westfield

face picon face
>    I think most dimmers simply ignore the problem and advance the firing
>    angle linearly from the user input.

Hmm.  So to make a credible "dimming LED", do you really need to match
the eye's response curve to brightness, or do you need to match the
brain's "learned stimulous" for dimming lights, as tought by theatre
dimmers, sunsets, and dying fires?

BillW

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads

2003\02\11@191349 by Mike Singer

picon face
Josh Koffman wrote:
> This I wasn't exactly clear on until now. Thanks Olin. I guess I can
> abandon the S curve stuff I've been thinking about. I suppose that's
> what comes when I'm basing much of my research on research I did for
> incandescent dimming. I still don't have a method to accomplish the
log
> dimming of the LEDs yet, but it will come I hope :)

Josh, the time you have spent discussing "curve" exceeded the
time you need to make simple experiment.
And you even didn't approach more ambiguous issues: "flashing
with pulsed vs varying current" from the point of eye perception,
etc. I suspect your "S curve" thoughts were in terms of constant
current, not pulsed PWM.

  Get cheapest PIC with RS-232. Program it to control LED with
two 8-bit values: one 8-bit for on-time, another 8-bit for off-time;
no interrupts.
  PC should load these values over MAX232.
  Use VBA in Excel worksheet, don't use worksheet formulae.
  Develop simple VBA code to fill two Excel columns (On,Off)
with values according to some curve. (Even Olin succeeded in
doing similar job :-)  - it was a joke :-).
  For low brightness vary off-time (200-255) at fixed on-time (1).
For high brightness vary on-time (200-255) at fixed off-time (1).
So you'll get not less then 1/255 precision in all the range.
   Develop VBA code to scan these columns and send both
values to PIC.
  Experiment with different curves. Add salty jokes and send
the result to the List. :-)
  (Kinda "The taste of honey" by Beatles must be named this
post :-)

  Best wishes.
  Mike.

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads

2003\02\11@200439 by i.tronics

face
flavicon
face
Hello John Dammeyer,

> Check the archives of Circuit Cellar Magazine.  There was an article
> about triac dimming theatre lights that should solve your problems.

    I've searched http://www.circuitcellar.com but can't find this article.

    Can you please tell me where to find it?

    Thanks,

    Brusque

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads

2003\02\12@071533 by Roman Black

flavicon
face
William Chops Westfield wrote:
>
> >    I think most dimmers simply ignore the problem and advance the firing
> >    angle linearly from the user input.
>
> Hmm.  So to make a credible "dimming LED", do you really need to match
> the eye's response curve to brightness, or do you need to match the
> brain's "learned stimulous" for dimming lights, as tought by theatre
> dimmers, sunsets, and dying fires?


And the shape of the curve changes with ambient light,
in a well lit room you will get a vastly different
"eye/led" dimming curve compared to a darkened home
theater room etc.
-Roman

--
http://www.piclist.com hint: The list server can filter out subtopics
(like ads or off topics) for you. See http://www.piclist.com/#topics

2003\02\12@081655 by John Snider

picon face
On Wed, 12 Feb 2003 23:04:59 +1100, Roman Black <spam_OUTfastvidTakeThisOuTspamEZY.NET.AU> wrote:
> And the shape of the curve changes with ambient light,
> in a well lit room you will get a vastly different
> "eye/led" dimming curve compared to a darkened home
> theater room etc.
-----------------------------------------
I think it would also change with the brightness of the surrounding LEDs -
(contrast sensitivity)?
--
John Snider

--
http://www.piclist.com hint: The list server can filter out subtopics
(like ads or off topics) for you. See http://www.piclist.com/#topics

2003\02\12@100623 by Dave Tweed

face
flavicon
face
".....c.i.tronicsKILLspamspam@spam@terra.com.br" <c.i.tronicsspamKILLspamTERRA.COM.BR> wrote:
> Hello John Dammeyer,
> > Check the archives of Circuit Cellar Magazine.  There was an article
> > about triac dimming theatre lights that should solve your problems.
>
> I've searched http://www.circuitcellar.com but can't find this article.
> Can you please tell me where to find it?

Go to my index at http://www.dtweed.com/circuitcellar/

There's a full database of all articles (including abstracts) that you can
download and search with any text editor.

I'm going to add a search feature to the web page Real Soon Now (TM).

-- Dave Tweed

--
http://www.piclist.com hint: The list server can filter out subtopics
(like ads or off topics) for you. See http://www.piclist.com/#topics

2003\02\12@124023 by Peter L. Peres

picon face
On Tue, 11 Feb 2003, William Chops Westfield wrote:

*>>    I think most dimmers simply ignore the problem and advance the firing
*>>    angle linearly from the user input.
*>
*>Hmm.  So to make a credible "dimming LED", do you really need to match
*>the eye's response curve to brightness, or do you need to match the
*>brain's "learned stimulous" for dimming lights, as tought by theatre
*>dimmers, sunsets, and dying fires?

Dimming lights are engineered to cause a linear darkening sensation.
Sunsets are something between cosine law and exponential, so are natural
lighting events (like someone receding with a candle in the dark). The eye
is perfectly adapted to the environment, the dimmers aren't. If you copy a
natural effect (e.g. inverse square law) you will probably please the eye
of the onlooker.

Peter

--
http://www.piclist.com hint: The list server can filter out subtopics
(like ads or off topics) for you. See http://www.piclist.com/#topics

More... (looser matching)
- Last day of these posts
- In 2003 , 2004 only
- Today
- New search...