0

Beauty & the Beast Rose for school play
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Beauty & the Beast Rose for school play

by tactus72 on Sun Dec 29, 2013 2:44 am

I am a novice maker with some experience soldering kits like the BlinkyPOV, and coding a little javascript. I am also a the father of a son who plays a villager in a middle school production of Beauty & the Beast Jr. I would like to construct a prop for the play, particularly the iconic glowing rose in the bell jar which parallels the beast's life span. I have already been to Michaels, etc., and gotten a couple of synthetic roses to experiment with, a 3-liter clear soda bottle (to make the bell jar with). Now, I just need perhaps some NeoPixels and a GEMMA or something, to make the rose petals appear to glow solidly, then dim to off one by one at separate time intervals to represent the enchantment dying away throughout the show.

I figure I could probably sew the NeoPixels into some of the synthetic petals and mount some into the foam base of the bell jar for more luminescence. Then using some micro controller to pre-program the dimming sequence so some kid theater-tech can sit literally behind the scenes and push a single button for the dimming to occur.

Thank you Adafruit community for any ideas and insight for hardware and coding, that you may offer.
tactus72
 
Posts: 6
Joined: Sun Dec 29, 2013 12:26 am

Up and running...

by tactus72 on Fri Feb 14, 2014 9:09 am

Well, tried to do it myself, and I think it came out pretty good. However, if it is possible to get some guidance in the code portion, I would love to code in a timer for the Neopixels to black out one-by-one based on a schedule. Although I think the Gemma may not sophisticated enough for timed events, and maybe it would have been better to get Flora instead.
Attachments
Photo Feb 12, 8 48 02 PM.jpg
with room lights off
Photo Feb 12, 8 48 02 PM.jpg (49.59 KiB) Viewed 838 times
Photo Feb 12, 8 47 06 PM.jpg
with room lights on
Photo Feb 12, 8 47 06 PM.jpg (51.65 KiB) Viewed 838 times
tactus72
 
Posts: 6
Joined: Sun Dec 29, 2013 12:26 am

Re: Beauty & the Beast Rose for school play

by adafruit_support_bill on Fri Feb 14, 2014 9:18 am

Nice looking rose!

I'm going to move this thread to General Project Help where is should get more visibility. It might help if you posted the code that you have for it now.

The millis() function is probably the best way to approach the schedule timing. Make a list of intervals with millisecond resolution over the expected run-time of the show. The millisecond timer will start at 0 when the processor is reset. You can start will all leds on, then turn them off one at a time as the result of the millis() function exceeds the value of one of your pre-defined intervals.

adafruit_support_bill
 
Posts: 81581
Joined: Sat Feb 07, 2009 10:11 am

Re: Beauty & the Beast Rose for school play

by tactus72 on Sat Feb 15, 2014 3:38 am

Thank you so much replying, and thanks for correcting my category! Wasn't sure what to pick.

I used the "Space Face LED Galaxy Makeup" http://learn.adafruit.com/space-face-led-galaxy-makeup/overview as a template for hardware and code, only modifying the RGB values to (255,0,50) for something a little more "rose color".

Code: Select all | TOGGLE FULL SIZE
#include <Adafruit_NeoPixel.h>
 
#define PIN 1
 
// Parameter 1 = number of pixels in strip
// Parameter 2 = pin number (most are valid)
// Parameter 3 = pixel type flags, add together as needed:
//   NEO_KHZ800  800 KHz bitstream (most NeoPixel products w/WS2812 LEDs)
//   NEO_KHZ400  400 KHz (classic 'v1' (not v2) FLORA pixels, WS2811 drivers)
//   NEO_GRB     Pixels are wired for GRB bitstream (most NeoPixel products)
//   NEO_RGB     Pixels are wired for RGB bitstream (v1 FLORA pixels, not v2)
Adafruit_NeoPixel strip = Adafruit_NeoPixel(5, PIN, NEO_GRB + NEO_KHZ800);
 
void setup() {
  strip.begin();
  strip.show(); // Initialize all pixels to 'off'
}
 
void loop() {
  // all pixels show the same color:
  colorWipe(strip.Color(255, 0, 50), 50); // Reddish
}
 
// Fill the dots one after the other with a color
void colorWipe(uint32_t c, uint8_t wait) {
  for(uint16_t i=0; i<strip.numPixels(); i++) {
      strip.setPixelColor(i, c);
      strip.show();
      delay(wait);
  }
}


By the way, is there a page on the Adafruit site that has coding fundamentals? Is it best to get one of the Arduino starter books, or to get familiar with C/C++ first?
tactus72
 
Posts: 6
Joined: Sun Dec 29, 2013 12:26 am

Re: Beauty & the Beast Rose for school play

by adafruit_support_bill on Sat Feb 15, 2014 8:16 am

We do have a series of on-line lessons in our Learning System: http://learn.adafruit.com/search?q=arduino+lesson
There are also a few good books: http://www.adafruit.com/index.php?main_ ... duino+book
I'd start with the on-line lessons for the basics and maybe pick up one of books for more advanced topics. You can also learn a lot from looking at many of the other on-line projects.

I used the "Space Face LED Galaxy Makeup" http://learn.adafruit.com/space-face-le ... p/overview as a template for hardware and code,

Another easy way to get the gradual fading effect is to move your rose-colored colorwipe() to the setup function so it will get called once on reset.

Then you can do another colorwipe in black with a very long wait-time to turn them off one-by-one. The line below should turn one pixel off every 5 minutes
Code: Select all | TOGGLE FULL SIZE
colorwipe(strip.color(0,0,0), 5 * 60 * 1000);  // turn off one every 5 minutes (5 minutes x 60 seconds x 1000 milliseconds

adafruit_support_bill
 
Posts: 81581
Joined: Sat Feb 07, 2009 10:11 am

Please be positive and constructive with your questions and comments.