User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the Assembly section within the Software Development category of DaniWeb, a massive community of 391,923 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,725 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our Assembly advertiser:
Views: 521 | Replies: 3
Reply
Join Date: Jul 2008
Posts: 2
Reputation: RichardBerry is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
RichardBerry RichardBerry is offline Offline
Newbie Poster

Control Many LED's PWM

  #1  
30 Days Ago
Hi

I am wanting to make a board with about 80 LED's for my son's room. The LEDs must brighten and dim. I am aiming to make it look like the stars at night with the LEDs mounted on a black perspex plate, while also acting as a sort on night light for him, thus at all time there must be a reasonable number of LEDs on at a reasonable brightness. I was thinking of using about 8 groups of 10 LEDs each, and the perhaps controlling the brightness of the groups of LED's as follows:
Group 1: Sinusoidal brightening and dimming of white LEDs
Group 2: Inverse of group1
Group 3: Sinusoidal brightning and dimming of white LED's, but at at a different rate to Group 1
Group 4: Inverse of Group3
Group 5: short flashes say 100ms or shorter
Group 6: Permanently on
Group 7: Sinusoidal brightening and dimming of orange LEDs at a very slow frequency
Group 8: Inverse of Group 7

Where do I start. I have a fair range of PIC's in the 12F and 16F series, but have no idea how to begin to implement this - I guess I could start in Excel, and trying to figure out from there which groups to turn on when.

I only write in assembler and don't have tools to write in high level languages...

PLEEEEEESE Help!!!!!
Last edited by RichardBerry : 30 Days Ago at 3:19 am. Reason: Added line about writing in assembler only
AddThis Social Bookmark Button
Reply With Quote  
Join Date: Sep 2006
Posts: 260
Reputation: Colin Mac is on a distinguished road 
Rep Power: 2
Solved Threads: 16
Colin Mac Colin Mac is offline Offline
Posting Whiz in Training

Re: Control Many LED's PWM

  #2  
29 Days Ago
There's free versions of compilers for writing in other languages like C and Basic which come with libraries. If you used a few PICs, this wouldn't be difficult I wouldn't think. PICs can come with PWM outputs you could use. You could parallel the leds and switch a mosfet to fade them on and off.
You could look into methods like Charlieplexing to control as many leds as possible with the one pic.
Last edited by Colin Mac : 29 Days Ago at 9:31 am.
Reply With Quote  
Join Date: Jul 2008
Posts: 2
Reputation: RichardBerry is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
RichardBerry RichardBerry is offline Offline
Newbie Poster

Re: Control Many LED's PWM

  #3  
29 Days Ago
Hello Colin
Thanks for your reply. Had never heard of Charliplexing but a quick Google sorted that. What I am really after is how to implement numerous PWM outputs in a single loop. In hindsight maybe I should just use a couple of 12F675's, one for each different group? From what I have read on the data sheets, the smaller pics (i.e. 16Fxxx) only have one PWM module, with straight and inverted outputs?
It would be a nice challenge to try to code multiple PWM's in one big loop, but if I can't get that right I'll use 3 or 4 12F675's

Thanks for your reply
Reply With Quote  
Join Date: Sep 2006
Posts: 260
Reputation: Colin Mac is on a distinguished road 
Rep Power: 2
Solved Threads: 16
Colin Mac Colin Mac is offline Offline
Posting Whiz in Training

Re: Control Many LED's PWM

  #4  
29 Days Ago
Some 18F's have multiple PWM outputs.

I'm sure you could also implement it in software using interrupts. If you can generate PWM on
one pin, you can do the inverse on another.
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

DaniWeb Assembly Marketplace
Thread Tools Display Modes

Other Threads in the Assembly Forum

All times are GMT -4. The time now is 8:19 am.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC