Now that we have (part of) a cube, as shown in the first part of the series, it’d be nice to add some functionality. A project like this needs some complexity, otherwise, where would be the fun in making it. So, lets add some electronics, for the sake of experiment. Prototyping some electronics gives good insights in what works and what doesn’t. Also, it often creates new, inspiring ideas.
One of the main features of the CubeLamp is the ability to control which sides of the cube will be lit. For example: if two cubes are mated, the surfaces in between should be turned off. Furthermore, I think it’s a cool idea if the state every side can be controlled individually.
Capacitive touch control of some LEDs comes to mind here, so let’s prototype. For the LEDs, I’ve used some side emitting LEDs. Per surface, 3 LEDs, wired in parallel, are used. Two surfaces are equipped with LEDs, partially because I think that’s sufficient for this experiment, and for the other part, because prototyping on this scale is nitty-gritty work. See below for an illustration: the wires are 0.2mm thickness!
So, the two sides have some LEDs that can be controlled individually. Luckily, the surfaces of the cube have copper on them; how comfortable. This means we can very easily make some capacitive sensors. For this purpose, I use an ESP32: it’s cheap, and has built-in HW/SW support for reading capacitive inputs. Also, for future connectivity applications, having WiFi (or alternative, e.g. esp-now) is a nice property of the ESP32.
Et voilà, we have a working prototype! To convince the reader in these digital times, some video material has been made. As you can see, the system works quite responsive.
That’s it for now. I’ll hopefully keep working on this project. Some next ideas / open issues:
- How to detect when a cube is connected to another one? This is not too hard, for example, simply detect if there’s a power input.
- How to detect where a cube is connected? This is a bit more complicated. Some possibilities:
- Detect where the power comes from.
- Capacitive presence detection: 6 surfaces, 6 inputs. Great. However, I don’t know if this is feasible, in terms of detectability and make-ability.
- Similarly, I could use optical presence detection, as every surface has LEDs. This would require some optical detector though.
- Every cube has 4 corners. 4 points of contact will give trouble, as 3 points are required for mechanical contact. Having 4 points of contact requires some form of flexibility in the frame. PCBs are not very flexible.
All in all: sufficient puzzles to be solved!