This piece represents a stunning fusion of art and technology. The painting itself is a modern take on Picasso-style cubist work, with five vibrant, distinct colors. Hidden behind the canvas are capacitive touch sensors, cleverly detecting which area of the painting is being touched. The integrated RGB LED strip then dynamically shifts its color to match the hue selected on the canvas. It's a beautiful blend of interactive mood lighting and fine art, all in one stunning creation.
The making of this piece of art was captured into a beautiful short film, which you can watch by playing the YouTube video above.
First, we need the painting itself. You can either paint it yourself (which I highly recommend since it adds such a personal touch and makes it truly authentic) or get an existing artwork printed. I've attached a PDF with a bunch of beautiful artworks if you want to pick one and print it. Just a heads-up, those aren't my own creations. I've collected them from Pinterest and other places over time, so they're strictly for personal use, not for commercial use.
I decided to go the DIY route and make my own painting. I started with a rough sketch to get the basic idea down.
Then, I added the five colors using poster paints (you can totally use more colors, but you'll need a touch sensor for each one!).
Finally, I did the line work with black poster paint.
Part of this project was sponsored by Justway.
Justway offers a comprehensive suite of solutions, including CNC machining, 3D printing, sheet metal fabrication, injection molding, and urethane casting, offering rapid prototyping and mass production solutions. With an extensive network of specialized factories, Justway ensures top-quality products tailored to your needs.
Here are the steps to get your project 3D printed by Justway's 3D printing service.
First, head over to Justway's 3D printing service and select 3D printing. You also have options like CNC machining, injection Molding and Urethane Casting. But for this project, we will use the 3D printing service.
Click on "upload your design". A new page will appear. Here, you need to click on "Select CAD files" and upload the STL file.
After that, select the Quantity, Material (I recommend PLA or ABS for this project). In the color section, you can either select white and paint it later, or select the color you like directly in the 3D print. This will save time later.
Finally, after selecting all the options, you can enter your email and submit the request to get a quote.
Justway is a great option, especially for complex prints which might be tricky to print at home with low-end printers. Plus, you get options like surface finishing and resin 3D prints.
Solder the Touch sensorsNext, we'll prepare the touch sensors with some soldering.
Follow these steps:
- Ground (GND) Connections: Solder all the GND pads of your touch sensors (five, or the number corresponding to your colors) together. Use enough wire between each sensor to allow you to position them freely later.
- Power (VCC) Connections: Similarly, solder all the VCC pads of the sensors together, again using sufficient wire lengths for flexibility.
- Signal (I/O) Connections: Attach a single wire to the Signal (I/O) pin of each individual sensor. These wires will be connected to the microcontroller, so ensure they are of adequate length for easy placement.
Now it's time to attach the touch sensors behind their corresponding color sections in the painting. Using glue is not a good idea as it would add unwanted thickness between the paper and the sensor. For optimal touch detection through the paper, we need the sensor to be as flush as possible. I simply used cellophane tape to stick the sensors.
However, this approach has a limitation. The touch sensitive zone is restricted to the sensor's surface area. Ideally, I wanted the entire area of each color to be responsive. I experimented with aluminum foil to expand the sensing region, but that unfortunately resulted in false triggers. As a compromise, I positioned each touch sensor at the center of its respective colored region. If you have any other ideas on how to make the whole colored area touch sensitive, please share them in the comments – I'd love to hear your suggestions!
Solder the sensors to the microcontrollerNext, we'll solder the signal output (I/O) pin from each sensor to a corresponding GPIO pin on the microcontroller. I connected my sensors sequentially to GPIO pins 0 through 4 on the XIAO SAMD21.
An Arduino would work just as well. However, the XIAO conveniently offers additional Vin and GND pads on the underside, directly connected to the USB-C power input. These will come in handy in the next step.
Solder the RGB LED stripWe can now solder the WS2813 LED strip to the Xiao. Disregard the white wire (B0). Solder the yellow wire (D0) to GPIO 6. It's crucial to connect this only to GPIO 6, as this specific pin is designed to handle the high-speed data transfer necessary for the LED strip.
Next, solder all GND wires from the sensors and the WS2813 to the GND pad on the underside of the Xiao. Similarly, connect all VCC wires from the sensors and WS2813 to the Vin pad, also on the underside. This eliminates the need for a separate power supply for the LED strip, allowing the entire system to be powered by a single USB-C cable plugged into the Xiao.
ProgrammingNow, connect the Xiao to your PC using a USB-C cable and upload the code. Initially, identifying which sensor corresponds to which color might be challenging. To address this, I initially uploaded the code with a random assignment of colors to sensors. After testing out the sensors, I then adjusted the color assignments in the code to match the actual sensor connections.
The code itself is relatively straightforward. It begins by displaying a sequence of colors, positioned to align with the corresponding colors on the painting. When a sensor detects touch input, the LED strip illuminates with the color associated with that sensor.
Next, I framed the painting using a white IKEA picture frame.
I also constructed an enclosure to conceal the wiring and microcontroller behind the frame. This enclosure serves a dual purpose: it hides the electronics and creates space, allowing the light to reflect off the wall and diffuse around the back of the frame.
Finally, I secured the LED strip around the perimeter of the enclosure, behind the painting.
Finally, all that remains is to hang the painting in your desired location, maybe beside your bed, desk, or anywhere a mood light would be suitable. And enjoy the unique and satisfying experience of changing colors through this interactive method.
It's incredibly pleasing to simply tap a color on the painting and see the mood light transform to match. It almost feels like having a superpower! I hope you'll build your own version and share your artwork, too!
Comments