44ed82b6bcacfc5624c7fbb29fcc5d55319d2152
[miniband.git] / README.md
1 # Code Club - Mini Band Project
2
3 Make your own mini band!
4 You and your friends can form your own finger-sized band and rock out using Raspberry Pi and Arduino.
5 Learn how to build circuits with sensors and outputs and write a simple programme to control your instruments.
6
7 ## You will make:
8
9 * A guitar
10 * A set of drums
11 * A pair of maracas
12
13 ## You will need:
14
15 * 1 x Raspberry Pi (plus monitor and power supply)
16 * USB hub
17 * 2 x Arduino Uno boards (with USB cables)
18 * 1 x strip potentiometer
19 * 2 x tilt sensors
20 * 4 x piezo buzzers (the type in greetings cards, easy to get from Maplin)
21 * 10K resistors
22 * Bread boards (1 per instrument)
23 * Card
24 * Sugru (or some other modelling material)
25 * Electrical tape
26 * Plastic drinking straw
27 * Pencil
28
29
30 ## Software requirements:
31
32 * Scratch
33 * IDE developer environment for Arduino
34 * Py Serial library
35
36
37 ## Useful links:
38
39 * [Pictures](http://bit.ly/codeclubminiband)
40 * [Ardunio code](https://github.com/KatJoyWhite/miniband/tree/master/arduino)
41
42
43
44 ## Pull-down Resistors
45
46 You’ll find your analogue inputs receive signal when you don’t expect them to.
47 This is because there’s electricty floating around in the system, or something like that.
48
49 To fix this, you need to wire each input to ground, through a 10KΩ resistor.
50
51 A better explanation can be found [here](http://arduino.cc/en/Tutorial/DigitalPins).
52
53
54
55 ## Drum Kit
56
57 ### 1. Make your drums
58
59 Take your 4 piezo buzzers and attach a ring of Sugru (or other modelling material) as shown in the picture.
60 This will increase the flexibility and resonance of the sensors. Let the sugru set.
61
62
63 ### 2. Connect the circuit
64
65 Piezo buzzers generate a small charges when you tap them, so they don’t need a power source.
66 Connect one lead from your buzzer to one of your analogue inputs, and connect the other lead to ground.
67 Repeat for each of your drums. It is easiest to use a bread board for making your circuit.
68 Look at the picture for an example.
69
70
71 ### 3. Program the Arduino
72
73 Find the appropriate code from the respository and upload to your Ardunio board.
74
75
76 ### 4. Set up in Scratch
77
78 Find four different drum sounds (or whatever sounds you'd like your drums to make!). Upload the sounds to Scratch.
79
80
81 ## Guitar
82
83 ### 1. Make your guitar
84
85 Grab your strip potentiomater, a piece of thin card, and a pencil.
86 Lightly draw round your potentiometer on the card and then use this as a guide to draw out your guitar shape.
87 (The potentiomater will be the fret board of your guitar).
88 Cut out and colour in the guitar and stick down the potentiomater.
89 Tape a pencil or stick to the back of the guitar to make it stiffen the fret board.
90
91 ### 2. Connect the circuit
92
93 The potentiomater strip adjusts resistance, so you will need to feed it some electricity.
94 Run +5V into one of the strip’s outer pins, and ground into the other outer pin.
95 It doesn’t matter which way around you connect these, but it will affect which the direction
96 the fretboard runs (high and the top, low at the bottom or vice-versa).
97
98 Signal will come from the centre pin, so connect that to one of your analogue inputs and you should be good to go.
99
100
101 ### 3. Program the Arduino
102
103 Find the appropriate code from the respository and upload to your Ardunio board.
104
105
106 ### 4. Set up in Scratch
107
108 Find five different guitar sounds and upload to Scratch.
109
110
111 ## Maracas
112
113 ### 1. Make your maracas
114
115 Cut 2 short lengths of drinking straw for your maraca handles.
116 Using Sugru (or other modelling material), make 2 maraca heads by rolling it up into balls.
117 Push the maraca heads onto the straws and mold into a maraca shape.
118 Connect lengths of wire to the connectors of the 2 tilt sensors and then push each sensor into a straw until it presses into the Sugru.
119 Leave the Sugru to set.
120
121
122 ### 2. Connect the circuit
123
124 Connect the +5V port on the Arduino board to one of the pins on the tilt switch (it doesn't matter which way round).
125 Connect the other pin to an empty digital input on the board.
126
127
128 ### 3. Program the Arduino
129
130 Find the appropriate code from the respository and upload to your Ardunio board.
131
132
133 ### 4. Set up in Scratch
134
135 Find a maraca / shaker sound and upload to Scratch.
136
137