2023 Group 5 – Fairy Wings

Design blog

A holistic view was adopted to select the materials we used to ensure user friendliness, efficient functioning of the circuit and keeping in mind the stage setup, lighting and the impact of the wings on the performance.

  • Iridescent paper – it reflects well on the stage where the spotlight will only focus on the actors and its pitch dark all around. It stands out well. This also means it reflects the led lights better
    It is also light weight.
  • Craft wire – they are light weight and allow to mimic the realistic veins of the wings. Also they are light weight so, the actor doesn’t need to carry much weight and they still uphold the structure of the wings.
  • Buttons – In order to disguise the buttons, we have put them as a pendant. This way, the buttons are easily accessible to the user and also seems like a part of the accessories a fairy would wear.
  • 6-inch servo elongated arms – since the wings are quite large and wide, the servo arms of the SG90 servo cannot cover much surface area of the wings to make them flutter effectively. 6-inch servo elongated arms.
  • Small breadboard – To allow the user to control the wings and the LED strip, a connection had to be established between the back where the Arduino board is and around their neck. Instead of soldering the buttons to the wires directly, using a smaller breadboard allows the buttons to be mounted safely and securely and also ensures that the user won’t be harmed if the wires were soldered to the buttons directly rather than the other way around.
  • Potentiometer – Potentiometer allows to map a range of values between 0 and 1023 based on the analog input read. This helps to transition between a large range of colors smoothly. The twisting feature of the potentiometer is also quite intuitive for the user to use
  • Buttons – Instead of smaller buttons, we got larger buttons that could also pass as gems on the necklace and are easier to interact with instead of the small ones, making it more user friendly.
  • 9V Battery – required to power the circuit and specifically the LED strip.

How does the user interact?

The Arduino board is mounted behind the user and is connected to the wings and LED strips. As a result, another breadboard that is accessible to them, simple to operate, and doesn’t get in the way of their performance has to be given to them. We thought of three ways for the user to interact with the system:

  • Idea 1 – the user interacts via a bracelet around their wrist.
  • Idea 2 – the user interacts via the necklace around their neck.
  • Idea 3 – the user interacts via a staff or a wand in their hand.

All of these ideas can be easily disguised as accessories a fairy would wear hence, they fit well with the costume. Considering the frequent hand movements during the performance, we decided to go with the necklace around the user’s neck. This way, it’s easily reachable, won’t interfere with their movements and ensures that the connection between the Arduino board at the back and the necklace remains secure. Hence, to ensure the functionality isn’t compromised while the performance, the necklace idea was chosen in the end.

Design principles

Visibility – he user can quickly identify which controls to use owing to the necklace they wear during performances. Similar sequins have been stuck to the button and potentiometer used to control the lights, making it evident how functionally related they are.

Affordance – Using buttons instead of any other input device is to use familiarity of the user with the object to make it easy for the user to understand how it works. People are aware how buttons are clickable.

Feedback -Every user interaction generates feedback. By pressing the blue button, the RGB led strip can be turned on or off to provide visual feedback. The sound of the servo arms moving provides haptic and auditory input when the wings begin to flutter upon pushing the red button. Additionally, when the potentiometer is twisted, the RGB led strip’s colors shift visually.


Sketches and prototypes

Prototype 1

Idea behind the functionality:

  • The wires are connected to the breadboard
  • Wires extend all the over the shoulder and mimic as a necklace as a user interface – the buttons acts as gems on it
  • Press the button to flutter the wings
  • Press the button to turn on and off the LED strip
  • The potentiometer is also allows controlling the different colors of the LED lights.
LED lights testing

We decided to test each functionality and circuit individually first and then put them all together for the prototype. This was to make sure that all the functionalities are coded and that they are not dependent on other functionality.

We first started working with the LED strip. Testing out the code and working out whether we can control it with button. Installed an additional library, FastLED for coding the LED strip and then completed the circuit by connecting the LED to a 330 ohm blue resistor and a capacitor.

Servo testing

Making the first quick prototype to test out the capacity of the servo to move the small size wings. This is also to test out how the servo can be connected to the wings.

Prototype 2

Changing the size of the wings to full size to test out the fluttering with the servos. Sizing up the wings needed 2 servos instead of 1. A single servo cannot handle the weight of the big wings and establishes 2 points of contact with the wing.

Final Prototype

Craft wire wings

While we are working on the functionality of the wings and the LED lights, we start working on the final design of the wings made of craft wire.

The wire was quite flimsy alone, we chose a weaker wire so that it would be easier to work with, also for the lightweight property, however this also meant that it wasn’t so strong or immune to damage. Adding all the details inside provided some structure and made the initial wing frame much stronger. To connect each piece of wire to another, I coiled one around the other – this also provided more structure and made it much more sturdy.

Cellophane

The cellophane seemed quite thick initially, we wanted the wire to show through in the middle section as this was a key aesthetic feature in the design – the wings should mimic those of a butterfly. We realised the cellophane could be split into two pieces which made it thinner. We did this for both wings so the wire details came through as intended.

After we taped the entire wire wing and stuck it to the cellophane, we pinched the paper around the cellophane to secure it. In come places, this made it rip in some places so we had to remove the paper and stick it down less taught. This was difficult as we had to get the right ratio of having the cellophane paper loose enough so that it wouldn’t rip but also not too loose otherwise wrinkles would appear in the wing. The wrinkles were not pleasing at all, aesthetically, so we used trial and error before we were happy with how the cellophane looked and stuck it properly.

After this the paper was cut to size with about 5-8 cm extra around the edges. We then used a lighter to seal the edges, since there was so much extra cellophane it wasn’t burning correctly and morphed in a strange way. We then cut again leaving only 1-2cm. Since it was now too short the cellophane was sticking to the wire with a gap in between and the two pieces weren’t sticking to each other. After pinching the cellophane together first and then applying heat, the cellophane sheets moulded into each other and then the wire as initially intended.

Servo testing with the final wings

Trying out the MG996R servo for the final wings. The bigger servo was stronger and could easily move the wings to make them flutter.

Another iteration from the previous carboard wings was to attach long arms to the servo arms to cover more surface area on the wings and help them flutter better.

Soldering

We needed the LED lights on both the wings, so had to cut the the LED strip into 2 pieces and solder 3 pin female header on the ends of it.

Potentiometer Testing

testing out the code for the potentiometer independent of the buttons to test out its independent functionality.

Back support

U – shaped back support created with the metal craft wire. The U-shaped wire is slotted inside the waistband user wears to wear the wings. The servos are attached to this support.

This was an unsuccessful iteration because the wire that is attached to the wings restricted the movement of the wings when fluttering. Also because

Final support

Project Task List

Making the first quick prototype to test out the capacity of the servo to move the small size wings. This is also to test out how the servo can be connected to the wings. Sizing up on the wings

As an overview, the workload was divided based on everyone’s strengths.

  • Amrina – responsible for the making of the final metal wings and back support
  • Halak & Jess – responsible for prototyping, circuit and testing out the functionality with code

Maker Manual

Contents

  • Overview
  • Tools
  • Supplies
  • Circuit Diagram
  • Building instructions
  • Code
  • Testing
  • Possible improvements

Overview

A stunning set of wearable wings suitable for any fairy to step into their own spotlight!

​By using the costume-coherent attached amulet, the lights can be discretely toggled and colour-changed in real time by the wearer without breaking immersion. The same control system can also be used to toggle wing flapping to further enhance the performance. 

The straps are tied around the torso so that the wings can be worn, and the amulet can be worn around the neck. The Arduino board is mounted to the back to minimize its visibility to the audience. The amulet and its strings can be decorated to match the costume. The cellophane foil covering the wire is lightweight and light-reflective to allow for easier servo operation whilst standing out in a theatrical environment. 

​ 

Tools

  • Pliers 
  • Lighter
  • Wire strippers 
  • Pen/pencil 
  • Scissors 
  • Tape: consider masking tape, double sided and clear cellotape 
  • Screwdriver 
  • Soldering supplies 

Supplies

  • Craft wire 
  • Iridescent cellophane 
  • 330 ohm blue resistor
  • 25v capacitor
  • SG90 servos × 4 
  • 6-inch servo elongated arms (3D printed by Dave) 
  • RGB strip WS2812B – 30 or 60 LEDs per metre is fine – 1.5-2m of strip is enough 
  • Female 3-pin header x 2 (for soldering) 
  • Female single pin headers 
  • Roll wires for the “amulet” 
  • Plenty of pin (male-male) wires 
  • Large buttons × 2 
  • Potentiometer × 1 
  • Arduino board × 1 (including breadboard) 
  • Mini breadboard × 1 
  • 9V battery and snap connector 
  • Cardboard  (made out of old recycled boxes)
  • old birthday decorations (repurposed)
  • Optional embellishments on wires/buttons (such as sticky sequins and ribbons) 

Circuit diagram and Layout

​ 

​ 

​ add the circuit pic above 🙂

Building Instructions

  1. Draw out one wing on the cardboard and cut it out. Use this as a stencil for the wire. 
  2. Cut around 1m of wire and make the outline of the top section of the wing using the cardboard as a guide. 
  3. Using around 0.5m of wire create the bottom section of the wing. 
  4. Attach the top and bottom by spiralling a piece of wire around the section where they touch. The spiral also makes the wire sturdier. 
  5. Using the cardboard sketch as a guide, create the inside details of the wing. Again, attach each piece by creating a spiral of wire. 
  6. Use double sided tape to cover all the wire – small gaps are fine, but the wire should be at least 80% covered 
  7. Measuring the length of one wing, top to bottom, cut two pieces of cellophane 
  8. Place the taped wing carefully onto one piece of cellophane. Place the other piece of cellophane on top, ensure there are minimal wrinkles but that it is not too taught as you need room to pinch it around the wire. 
  9. Softly, pinch the cellophane around the outside of the wing before pinching around each of the wires. Do not pinch too hard as the cellophane will rip. 
  10. Turn the wing over and repeat this on the other side to make sure the cellophane is stuck to the wire outline on both sides. 
  11. Cut around the cellophane leaving around 1-2cm past the wire 
  12. To seal the cellophane around the wire, pinch it together then carefully use a lighter to heat it up, so it burns and moulds together around the wire. Make sure the cellophane is just above the flame and doesn’t actually touch it i.e. you’re applying heat not setting it on fire, a flame is used since it helps focus the heat over a small area. (Take extra care of surroundings and make sure your hand isn’t close to any open flame. 
    • Alternatively, if the cellophane is cut to size, cello tape can be used to seal it over the wire however, this can look messy and using a lighter gives a cleaner finish. 
  13. Repeat steps 2-12 to make the second wing. 
  14. Attaching the longer servo arms to the servos, position two servos along the inside of each wing, then stick the arms to the wings. The servo arms should be parallel. 
  15. Using wire, connect the two servos on both sides to reinforce them – do this on both wings. 
  16. Then connect the wings by using wire to connect the wire supports that were made in step 15. The connections should run horizontally, one at the top, and one at the bottom to create a square structure. 
  17. To strengthen the support, add connections from the top horizontal wire support down to the bottom in three, equally spaced points. The support should be strong enough to support the servos and keep the wings in place, but not so strong that the wings are rigid and stiff – they should still be able to flutter elegantly. 
  18. Cut the RGB strip to the desired length. 
  19. The 3-pin headers must then be soldered to the side of the strip indicated by the arrow.  
  20. Remove the backing and stick it down. If sticking along the outside frame, cello tape may be needed to reinforce it as the strip may not stay in place along the edge of the wire. 
  21. Wire up the mini breadboard to the two buttons and potentiometer 
  22. Use the longer leads to connect the components of the mini breadboard back to the Arduino Uno board 
  23. Using the recycled gold strips, wrap the leads tightly together to give it the appearance of a necklace. 
  24. Add gems to the buttons and potentiometer to also disguise them as a pendant in the necklace. 
  25. Connect the servos and RGB strips to the Arduino board and breadboard.  
  26. Create/stick the cardboard box to the wire support between the wings. Make sure this is on the correct side (the side that won’t be touching the wearer’s back). 
  27. Place the Arduino board, carefully, into the box along with all wiring. The ‘necklace’ (mini breadboard does not go inside so naturally some wiring will not fit fully inside the box – this is okay). 
  28. Add the strings to the top of the wire support – these are so that the wings can be worn by tying them around the wearer’s arms. 
  29. Add embellishments as desired. 

Code

// code by Halak & Jes :))))
#include <Servo.h>
#include <FastLED.h>
#define LED_PIN 5
#define NUM_LEDS 99  // we have 99 leds

Servo myservo;  // create servo object to control a servo         
Servo myservo2;
Servo myservo3;
Servo myservo4;

int pos = 0;
bool servoMoving = false;
bool lightOn = false;


const int potPin = A0;      // potentiometer pin (analog)
const int lightBtnPin = 2;  // the button to turn on lights
const int flapBtnPin = 3;  // button to control servo

// variable for reading the pushbutton status 
int buttonStateL = 0;  // for lights
int buttonStateS = 0;  // for servos
int potVal = 0;

int pressesL = 0;
int pressesS = 0;
CRGB leds[NUM_LEDS];

// global r,g,b values approach
int red = 255;
int blue = 0;
int green = 200;

void setup() {
  Serial.begin(9600);

  FastLED.addLeds<WS2812, LED_PIN, RGB>(leds, NUM_LEDS);
  FastLED.setMaxPowerInVoltsAndMilliamps(5, 500);
  FastLED.clear();
  FastLED.show();

// pinMode(lightBtnPin, INPUT_PULLUP);

  pinMode(lightBtnPin, INPUT);
  pinMode(flapBtnPin, INPUT);
  // Potentiometer doesn't need definition, just analogRead();

  myservo.attach(10);  // attaches the servo on pin 9 to the servo object
  myservo2.attach(11);
  myservo3.attach(12);  // attaches the servo on pin 9 to the servo object
  myservo4.attach(13);

  // interrupt
  //pinMode(INTERRUPT_PIN, INPUT_PULLUP);
  pinMode(flapBtnPin, INPUT_PULLUP);
  attachInterrupt(digitalPinToInterrupt(flapBtnPin), interruptServo, FALLING); // trigger when button pressed, but not when released.
  //attachInterrupt(digitalPinToInterrupt(lightBtnPin), interruptLight, FALLING);
}


void interruptServo() {
  Serial.println("interrupted");

  if(servoMoving == true){
    servoMoving = false;
  }
}

// void interruptLight() {
//   Serial.println("interrupted");
//   updateLights();
// }


void turnAtoB(int a, int b, int speed) {  // a to b, a < b
  for (pos = a; pos <= b; pos += 1) {
    myservo.write(pos);  // tell servo to go to position in variable 'pos'
    myservo2.write(pos);
    myservo3.write(pos);
    myservo4.write(pos);
    delay(speed);  // waits 15ms for the servo to reach the position
  }
}

void reverseAtoB(int a, int b, int speed) {  // a to b, a > b
  for (pos = a; pos >= b; pos -= 1) {
    myservo.write(pos);  // tell servo to go to position in variable 'pos'
    myservo2.write(pos);
    myservo3.write(pos);
    myservo4.write(pos);
    delay(speed);  // waits 15ms for the servo to reach the position
  }
}


void colourStrip(int g, int r, int b) {
  for (int i = 0; i < NUM_LEDS; i++) {
    leds[i] = CRGB(g, r, b);  //
    FastLED.show();
  }
}


void dialcol(int in) {  // input should be potentiometer value
  // logically, colour cycles are just shifting the distribution of RGB between two at a time.
  // see: R=255,B=0 -> R=0, B=255 goes through red, pink, purple, blue (keeping last value 0 to keep it light);
  // we do this for RB, BG and GR: shifting 255 values 3 times, so x of 765 "points" to map onto 0-1024

  // first off, map where the potentiometer is on its cycle
  int mapped = map(in, 0, 1023, 0, 765);

  // now work out: is it RB[0], BG[1] or GR[2]?
  int phase = mapped / 255;  // int divide
  int rem = mapped % 255;    // modulus: this is how far in we are (first val of pair)

  if (phase == 0) {  // RG
    red = rem;
    green = 255 - rem;
    blue = 0;
  } else if (phase == 2) {  // GB
    green = rem;
    blue = 255 - rem;
    red=0;
  } else {  //BR
    blue = rem;
    red = 255 - rem;
    green=0;
  }
  // reload lights if they're on
  if(pressesL %2 != 0){
    colourStrip(green, red, blue);
  }
}

void updateLights() {
  if(lightOn ==true) {
    colourStrip(green, red, blue);
  } else {
    colourStrip(0,0,0);
  }
}

void loop() {

  delay(100);
  buttonStateL = digitalRead(lightBtnPin);
  delay(100);
  buttonStateS = digitalRead(flapBtnPin);
  
  potVal = analogRead(potPin);
  dialcol(potVal);

  // check if the pushbutton is pressed.
  //   if it is, the buttonState is HIGH:
  // of buttonstate is on - then only read the potentiometer and change the colour
  // if (buttonStateL == LOW) {
  //   pressesL++;
  //   if (pressesL % 2 != 0) {
  //     Serial.println("led on");
  //     colourStrip(green, red, blue);
  //   } 
  //   else {
  //     Serial.println("led is turned off");
  //     lightOn = false; 
  //     colourStrip(0,0,0);
  //   }
  // }
  colourStrip(green, red, blue);

  if (buttonStateS == LOW) {
    pressesS++;
    if (pressesS % 2 == 0) { // even: turn off
      Serial.println("its even, so the servo is off");
      servoMoving = false;
    } else {
      Serial.println("its odd, so the servo is on");
      servoMoving = true;
    }
  }

  if(servoMoving ==true) {
    Serial.println("servoMoving");
    int min = 0;
    int max = 100;
    int spd = 15;
    turnAtoB(90, 140, spd);
    reverseAtoB(140, 90, spd);
    // i think (the first two servos) need to go 180 to 140
  }
  //updateLights();
}

​ Circ 07, Circ 04 were used as a reference for the code for the push buttons and the servos. FastLED library was used for the coding the addressable LED strip

Testing

Testing was conducted at every stage of the building process. Firstly, the RGB strips were programmed to output a single colour to ensure all LEDs were functional; they were also tested after being soldered to the headers to ensure the 3-pin header had been joined properly, and then again when the button input had been wired. 

The mini breadboard was wired to connect two buttons and a potentiometer to the main arduino. We used a sketch that printed different outputs to the serial monitor when it detected each button press, and kept a record of previous state to ensure buttons were togglable. We also printed the value of the potentiometer at regular intervals. When we were certain all input methods were responsive and wired correctly, we connected the RGB strip to the arduino and debugged a sketch which took inputs from the potentiometer and mapped them to an RGB output. 

As the servos were attached to the wings, they were tested using a simple servo movement sketch to ensure both that the wings moved in the right direction (away from the intended user) and that a pair along the wing would move in sync. Once all servos were installed, we ensured they could be activated and deactivated with button presses before assembling to the frame.  

Issues that came up during code testing were mainly to do with button responsiveness. Even when wired properly, both buttons appeared to not register response or lag when turning off the servo or RGB strip. After re-working the order of checking for buttons within loop(), we introduced an interrupt to the servo button pin which prioritised checking the state of the servos when the button was pressed. This reduced the severity of the issue, but there is still a short delay between either button press and actual stopping of the RGB strip and/or servo. 

​ 

Possible Improvements

Hardware improvements
  • The RGB strip would go around the entire wing.  
  • Customisable pendant: buttons can be changed so colours fit the character/scene better, further blending the pendant into the costume. 
Coding improvements
  • Different light sequences could be programmed and used. For example, different patterns such as blinking or running, and colours could be cycled. There could also be the option to adjust the brightness of the lights. 
  • Fluttering could have a speed adjustment feature – allows for more dramatic effects on stage. 
  • Allow to change the colour on the led strip with the potentiometer without turning on the lights as well.

Group members