Simulated Lighthouse Light

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 5.
To post in this forum you must have a registered copy of Flowcode 5 or higher.

Moderator: Benj

Post Reply
JDR04
Posts: 271
Joined: Tue Mar 05, 2013 10:49 pm
Has thanked: 111 times
Been thanked: 13 times
Contact:

Simulated Lighthouse Light

Post by JDR04 »

Hi folks. Could somebody please show me how to "ramp up" a white led and then FLASH at the end. I've attached a waveform incase my explanation is somewhat confusing. I'm building a small light house for our village to raise some funds for christmas lights for the kids.The software side has got me completely stumped.

Is it possible to ramp up and ramp down an led with FLOWCODE 5?? Thanks a lot....John
Attachments
Lighthouse LED.png
(1.75 KiB) Downloaded 3203 times

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: Simulated Lighthouse Light

Post by Benj »

Hi John,

It certainly is possible. I would use either hardware PWM or create my own software PWM using a timer interrupt.

Once you have the PWM up and running it should just be a case up ramping up the duty from say 0 to 100 and then jumping directly to max brightness at 255, wait a short amount of time and then reduce back to 100 and ramp back down to 0.

This article may help with creating software PWM.
http://www.matrixtsl.com/article.php?a=52

Let us know how your getting on.

JDR04
Posts: 271
Joined: Tue Mar 05, 2013 10:49 pm
Has thanked: 111 times
Been thanked: 13 times
Contact:

Re: Simulated Lighthouse Light

Post by JDR04 »

Thanks Benj, I'll go through it tonight and let you know how I get on.

Post Reply