I was recently asked to update my popular NXT sequencer for an EV3 version, so here it is!
The build is pretty simple and can be made by either the Home (31313) or Education (45544) versions of the EV3 kit.
The programming was done in EV3-G and very straight forward. A single loop checks the Colour Sensor connected to Port 1 via a Switch Block. I added multiple conditions to the switch so that there was one for each colour LEGO brick I had available (huge thanks to Filippa from LEGO for the coloured beams!).
For each colour there is a particular sound that is played. I just chose the notes from a C Major scale but you can get creative (Mixolydian anyone???)
For the colour White, I left the sequence blank. This means that as the colour sensor goes over anything white, it won't play any sound. If I had a black table, I would switch the Black case to be 'play nothing' and the White case to play a note.
A separate task spins the motor (connected to Port A). Change the speed as necessary to speed up or slowdown your sequencer.
Download the full Project Here - EV3_Sequencer.ev3
Download the full colour pdf here - EV3_sequencer_build.pdf
Let me know how you go and post up your musical creations!