Don't Panic! This is probably a good sensor!

A project log for The well-tempered chaos sequencer

A mechanical chaos musical instrument based on the intuitive visual relationships between musical structures and generic chaos

3mrrrx3mrrrx 10/21/2018 at 02:570 Comments

While the best sensor is the probably the one you don't have, there is number of sensors that are probably just as good! For this project the sensor for counting the bearing ball fall in a bin of a board had to be a simple and cheap as possible. This is especially import for make the board simple to build and easily reproducible. At the current stage of the project three kind of sensors were take in to consideration:

Those three Sensor where used in developing the board. Each sensor had its advantages and problems. most interestingly was the fact that each of sensor had its one probably of functioning!

probably of
No Sensor less 0.20€analogRead()novery lowlow 
---------- more ----------

# no sensor -  just jumper cable

Using no sensor was one of the main concepts for his project. The idea was to embed jumper cables in the 3D-printed model to act as button, switches or electrical  electrical circle.  This had the advantage that probably no soldering would be needed and the hole electrical circuit would be built within minutes.   

The jumper cables pina each connected to the Arduino: 

5V                     -->           Jumper cable pin 0

Analog in XX    -->           Jumper cable pin 1

In this case the bearing balls when touching both jumper will close the electrical circuit. The resulting analog signal by the Arduino analog read would have clear spikes that are very definitive for registering a falling bearing ball.  

 THE DOWN SIDE of this sensor is it's tolerance as the probably for this sensor to register a falling ball is very low. Most of the times a bearing ball would touch only one pin or even jump over both pins. if the pins of the jumper cable were to be pushed deeper in to the board this would result in to blocking the bin. 

# CNY70 : Reflective Optical Sensor with Transistor Output

This is probably the most expensive sensor used in this project ( around 2€ each). The sensor is very accurate and reliable. 


The sensor uses an infrared emitter and phototransistor. A falling bearing ball will act as a refactor for emitted infrared light and the phototransistor will register the falling ball. Reading the sensor using the Analog in of the Arduino gives even an indication of  the proximity of the a bearing ball to the phototransistor, by the fraction of the ball that reflects to back to sensor.   

 THE DOWN SIDE of this sensor is its high price and complexity. For this sensor to work properly the bearing ball should fall within a fixed distance from the sensors. Ball falling closer than this fixed distance or even touching the sensor will probably not be detected as they will not reflect the the infrared light back to phototransistor. 

# Piezo elements - or at least s small part of one

Piezo elements are probably the most beautiful sensor of all time and universe.  They simple, cheap and very reliable. Even if they are too big to fit in one of the bis can be easily fixed by cutting out a strip  of the element.  


When the bearing ball hits piezo element it will result in clear peek. This can be seen in the reading from the Arduino analog in. This signal is perfect as it very short can be easily translated to musical events using simple thresh holding.    

 THE DOWN SIDE of this sensor is that it has to acoustically isolated for each bin. The isolation is very important so that the sensor only registers the bearing ball fall in that specific bin. The isolation of the sensors is done using plastic or foam.  Another done side is that sensors tend to break when cutting them. Cutting works but one has to be very careful.