Go to Post Every single person on the team, read the manual, cover to cover, NO skimming. Do not give the task of knowing the rules to a few people. Do not pass go, do not collect $200, READ THE MANUAL. - RoboChair [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Spotlight this post!  
Unread 04-02-2011, 21:28
RyanN's Avatar
RyanN RyanN is offline
RyanN
AKA: Ryan Nazaretian
FRC #4901 (Garnet Squadron)
Team Role: Mentor
 
Join Date: Jun 2006
Rookie Year: 2005
Location: Columbia, SC
Posts: 1,126
RyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond repute
Underglow LED Control using WPI_DigitalOutputGeneratePWM.vi

Well, I've been busy tonight. See, I purchased some nice LED strips from SuperBrightLEDs.com (If you're an LED nerd, you probably should go look at it if you haven't already. I've had 3 or 4 orders from them and have been overly pleased by their service.)

Anyway, enough promoting them.

I purchased two of the RLBN-RGB30SMD RGB Narrow Rigid Light Bar that can be found on this page along with some other LED goodies. (Hmm... what else could we be doing with LEDs?).

Well, over the past two days at robotics, I've been making a PWM based control box to control each individual color channel, 6 in all (3/strip x 2 strips = 6). I finished building the control box just a few minutes before that session was over, so I never really got to go in deep with any programming with our programmer. We did verify that my box was working well with some simple on and off switches in LabVIEW.

Here are the VIs that just came in hot off of my mouse.

Underglow_Begin.vi (placed in the Begin.vi)
Click image for larger version

Name:	Underglow Begin.PNG
Views:	68
Size:	29.3 KB
ID:	9966

Underglow_Control.vi (placed in the 100ms loop in Periodic Tasks.vi)
Click image for larger version

Name:	Underglow Control.PNG
Views:	39
Size:	41.2 KB
ID:	9967

Underglow_Close.vi (placed in Finish.vi)
Click image for larger version

Name:	Underglow Close.PNG
Views:	23
Size:	20.4 KB
ID:	9968

If anyone wants the source code, here it is.
Underglow LED VIs.zip

Anyway, so what's the point of this thread? Well I have a question regarding the WPI_DigitalOutputGeneratePWM.vi
Click image for larger version

Name:	WPI_DigitalOutputGeneratePWM.PNG
Views:	22
Size:	15.8 KB
ID:	9970

It says that this VI will allocate 1 of 4 PWM generators. I'm guessing that means I can only have 4 of these in my Underglow_Control.vi? Maybe someone here who has used this control before can spread a little light on it?

Now I would use that handy WPI_PWMSetValue.vi, except that we only have 4 PWM channels free, plus the spacing and such between the PWM headers would make it more of a wiring hassle rather than just using the signal pins that I already have and using 1 PWM cable for each LED strip. Plus... we're using up 6 of the 10 PWM outputs, and we would rather not add an additional sidecar.

My only other idea is to combine both LED strips into 1 using a Y-cable and using 3 of the WPI_PWMSetValue.vi's unless I can truly use 6 of them (which I hope).

Let me know your thoughts, or if you have any questions about my project, just ask.
__________________
Garnet Squadron
FRC 4901
Controls Mentor
@rnazaretian

Previous mentor and student from Team Fusion, FRC 364

Last edited by RyanN : 04-02-2011 at 21:54.
 


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 23:46.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi