
things you will need
The following items from the Discover Computing kit:
- 1 x Crumble
- 1 x Battery pack
- 1 x Sparkle baton
- 1 x Button switch
- 3 x Red croc leads, 2 x Black croc leads, 1 x Green croc lead, 1 x Yellow croc lead
- 1 x USB cable
A computer with a USB port and the Crumble software installed.
Plus,
- 1 x ruler
- Sticky tape
- Camera (a digital SLR works best but an iphone will also work)
- A dark room or cupboard


Connect the Crumble to power
Use one red croc lead and one black croc lead to connect the Crumble to the battery box.
Safety first
Make sure the battery pack switch is set to OFF.

Add the output
- Attach one red croc lead, one black croc lead and one green croc lead to the connectors on the right hand side of the Crumble (as shown).
- Attach the croc leads to the connectors on the left hand side of the Sparkle baton (as shown).
Need to know
Make sure you connect the croc leads to side of the Sparkle baton with the arrow pointing to the right.

Add the input
- Attach one red croc lead to the remaining positive (+) connector on the battery box.
- Attach one yellow croc lead to the A (input/output) connector on the Crumble.
- Attach the croc leads to the button switch.

Build the paint brush
Use sticky tape to attach the croc leads connected to the Sparkle baton to the ruler.

Connect the Crumble to a computer
- Use the USB cable to connect your Crumble circuit to a computer with a USB post and with the Crumble software installed.
- Open the Crumble software.

Code the Crumble - colour the paintbrush
- Turn the battery pack on.
- Snap a ‘do forever’ loop to a program start block.
- Tell the Crumble to WAIT UNTIL the button is pressed (A is HI).
- When the button is pressed, tell the Crumble to set each of the Sparkles to a different colour.
Things to know
A WAIT UNTIL block is a type of conditional instruction. A condition is something which a computer must consider before continuing through a program.
In this case, the Crumble needs to consider whether the button has been pressed before turning all of the Sparkles on.


Code the Crumble - set the timer
- Tell the Crumble to keep the Sparkles ON for 6 seconds before turning them all OFF.
- Make sure your battery pack is switched ON.
- Send your code to the Crumble and press the button switch to test your program out.
- Once your program is working as expected, disconnect your Crumble circuit from the USB cable.

Set-up the camera
Next, you will need to set-up your camera or phone to take a long-exposure photograph.
- If you are using a digital SLR camera, set the shutter speed to 6 seconds.
- If you are using an iphone, first set the camera to take live photographs. Once you have taken a picture, you will be able to convert it to a long exposure photograph from the camera roll.
- If you are still unsure, type ‘how to take a long exposure photograph with (insert the name of your phone or camera)’ into your preferred search engine. You will then be presented with lots of instructions / options for your camera or phone.
Things to know
Long-exposure photography involves leaving the camera shutter open longer than usual. This allows items that are not moving to be captured sharply and items that are moving to be blurry.

Take a photograph
- Head to a dark room (or cupboard) with your Crumble circuit and camera.
- Holding the ruler, position your Sparkle baton in front of your camera with the Sparkles facing towards you.
- Press the button on your Crumble circuit to turn the Sparkles on.
- Keeping the Sparkle baton as still as possible, press the button on your camera to take a photograph.
- Once you’ve pressed the button, start to slowly move the Sparkle baton around before the timer runs out.
Top tip
If the Sparkles turned off too quickly, change the duration in step 7.

Time to experiment
- Try experimenting with different Sparkle sequences and colours.
- Ready for a challenge,? Try to write a message using the same technique here.
