Artist / Creative Technologist

Blog

Work In Progress, mostly.

Sending a signal - DOGMAS, a project because of the RP2040

It’s not often that a project takes years to complete, but sometimes an idea comes together that predates your ability to bring it into reality. Such was the case with DOGMAS, a project I’d conceptualized and prototyped in 2014, but that only really came together in 2022. Why? I needed the right microcontroller for the job and only found it in the recently released RP2040.

This version from 2014 uses an Arduino Uno, a micro SD card reader, and a coin cell battery.

In short, DOGMAS is an electronic candle that uses its light source to blink out the whole of multiple texts, letter by letter, in Morse code. In its simplest form this project stores a text file in non-volatile memory, reads the text into the memory of the microcontroller, and then translates that text into the blinking of the single LED. As built, it also operates in a self-contained manner, with the candle body containing an 18650 battery to allow it to operate for days on end. Nothing too complicated initially until you try and put it all into in a small form factor, and make it pretty.

Not lot of room to work with.

So when browsing some of the recent offerings from Adafruit I saw the Adafruit QT Py RP2040, I got to thinking. This little microcontroller had everything that I needed, including a capable microcontroller, onboard non-volatile memory, and and easy to interface with USB-C port, and it was the size of a postage stamp. It even had great documentation, perfect!

So I got to testing, and figured out just how powerful this little thing was.

This system runs happily with not a lot of hardware. In what I put together, I only really use 2 major modules, the QTPY PR2040 and the trinket lithium-ion battery backpack. Throw on a switch, an LED, an appropriately sized battery, and a few passives and I was good to go. Using the trinket battery backpack allowed me to simplify the hardware end of what I needed to design quite a bit, and had the added benefit of only needing the one USB port of the QTPY to interface with RP2040 and to charge the battery. The only change needed was to throw in a diode to keep the power flowing in the right way for the switch, and then it was good to go. With this setup I was able to test out some of the software for this project.

Which is where the RP2040 really began to shine. One of my original criterial was to store the text file on non-volatile memory. Previously I’d used an SD card, which worked, but added mechanical complexity and used more power to mount and read from. SD cards are great if you’re regularly changing out the files contained within, but for this project I’d be setting the file within once and hopefully not needing to touch it again. Before finding the QTPY RP2040, I’d looked into getting dedicated flash memory chips and then tying them into an existing microcontroller. This could work, but would have been an extra layer of learning and troubleshooting on top of what I already needed to do for this project. So when I saw that most RP2040 modules already incorporate some form of flash storage, and that they had robust support in firmware for interfacing with flash, I was sold. The QTPY RP2040 has 8MB of SPI flash storage, originally for Circuit Python code storage. As I was coding in Arduino, I could utilize all of that space for text file storage. On top of that, there’s a very handy library called TinyUSB, of which adafruit has been developing upon for a while. Using this library, I was able to treat the QTPY RP2040 as a flash drive, utilizing the same hardware that was would be in each of the candles to write the text to the flash memory. Instead of having to set up a complicated setup whereby I’d be sending the text to the RP2040 over serial, I could just set the RP2040 to flash-drive mode and copy the text file to it. Easy.

As an aside, the easy USB support is a very fun feature of the RP2040. Imagine a flash drive that turns every file stored on it into poetry. Adafruit even sells a version of this micro that is shaped like a USB drive.

Anyways, from there it was only a matter of getting the files off of the flash storage and then translated into the flashing series displayed by the LED. To do this, I adapted the function I’d written for other projects, and had it instead return the series of dits and daws that compose Morse code. If anyone would like to take a look, I’ll include a download for the code I wrote at the end of this post.

With that, the fun part began…

Once the code was all set, I was able to verify that it worked on the breadboard, and then try to figure out how I was going to execute the final hardware. For the longest time, I’d thought about making this into the form factor of a small rectangle, a credit card shaped device that would hang on the wall and blink. It would have been practical, but ultimately boring.

So thankfully during the process of working on this piece I decided on something different, that being a standard taper candle. Conceptually this worked well with the operation of the piece in that if fit with the anachronistic nature of most of the texts, and that candles have a strong modern association with religion, of which a large portion of the texts are the related to. With that decided, I then had figure out how to make a hardware device in the shape of standard candle.

CAD to the rescue.

Using Fusion360, I modeled or imported all of the hardware I knew I was going to use, and began playing with their layout within a cylindrical form. In doing so, It became quickly apparent that I’d need to stack the breakout boards and to shift to a cylindrical battery over a pouch-style. Once I had everything about where I wanted it, I had to figure out an enclosure that would hold the electronics in place while also acting as the outward faux camera body, in addition to working out a way to wire tie together all the electrical components to run the candle. To solve this, I started with the last problem first, and designed a custom circuit board in the shape of a horseshoe to anchor all of the electronics, and around that designed the enclosure.

An rendered exploded view of all of the components within the DOGMAS artwork.

What I landed on was a 3 part body, with the a permanent LED holder, end cup with USB-C and switch pass through, and a long but mostly hollow main body. All held together with the four of the smallest screws I’ve ever used. With that set, I brushed up on my KiCad and worked out the routing of the circuit board. What I ended up with was a 2 sided board that would stack the 2 breakout boards on either side of, allowing some of the smaller passives to be mounted underneath. Using a Bantam CNC, I was able to work through a a few versions of this board quickly.

And from there, it was a quick next step to solder it all up…

And from there, it was only a matter of assembling all of the remaining components. Rather than permanently soldering on the wires of the LED to the circuit board, I instead was able to use the STEMMA QT connector on the QTPY RP2040 and modified one of the premade jumpers to make a harness that ran up to the LED. To secure the battery to the circuit board and keep them all on the same axis, I first hot-glued the legs of the circuit board to the 18650 cell, and then used a length of wide shrink-wrap to hold it all together.

With all that together, all of these assemblies slid into the resin-printed main body and then closed in with the end cap.

And with that, the first of the Dogmas was complete.

When charged, the piece operates for about 5 days at a time. Each of the pieces in the 12 part edition has a different version of the texts stored within it digitally, all the same except for the order in which the lines of the 13 texts are re-assembled. Total, there are about 6.65 million characters per text file. At an average of 2.26 seconds per character it takes about 182 days, or about 6 months, of 24/7 operation to read through the whole of the text contained within.

But why though?

Why spend all of this effort to make an LED blink?

Well, that’s complicated. I’ll start out with the list of texts that I selected to amalgam into each of the Dogmas…

The New Testament (via king James version), The Torah, The Quran, Bhagavad Gita, On the Origin of Species by Charles Darwin, The Dīgha Nikāya (The first book of the The Tripitaka), The Analects by Confucius, Gurū Granth Sāhib, The Socratic Dialogs by Plato, The Code of Hammurabi, The Kojiki, Tao Te Ching, Popol Vuh, and The Epic of Gilgamesh.

You may notice that there’s a there’s a wide variety to the texts included, and that’s because I was looking for what I call foundational texts. Writings that the serve as the underpinning for large parts of culture as it exists now. There are holy texts, philosophic treatises, documents of law, and texts that don’t fit neatly into any category. All have had an monolithic effect on culture, each for a variety of reasons. These texts, and the way they’ve been perceived, have shaped the way most modern people understand and interpret the world. They’ve changed way we interact with with culture, as they have all had some effect culture.

To take all of that meaning, all of these highly significant texts and distill them down into one of the least intrusive methods of communication - a blinking light - I think is powerful. There is a dual nature to the way that humans use sight as the sense by which we most perceive the world, a sense entirely enabled by light and illumination. By taking the texts by which we imbue the world with meaning, and making them the mode by which the area around the work is illuminated. Though their communication we can see and understand the world. Within the long and short flickers of light are over a million words, each able to be read and deciphered if the viewer stays with it.

The candle form follows this saturation of meaning. They are an anachronistic technology that still have a place in cultures around the world. Though it’s impossible to know, candles were likely burning while these works were first inscribed as text, only taking second seat to the sun. Candles also have a modern connotation with meaningful occasions, as they’re now no longer needed with for day-to-day illumination. Instead, they’re used in houses of worship and to set the stage for meaningful events.

With that said…

This idea could take form and function in a variety of ways, and goodness knows that in 8 years I’ve thought up a number of variations. But for this version, I’m happy with it.


Note:

The list of selected foundational texts is only a minuscule slice of writings that have had a large effect on the world’s cultures, and my choice of what texts to include is a result of my view of the world and my background. My list is by no means exhaustive, and I’m sure that an artist of a different background and cultural setting would choose a different set. Within 8mb of possible storage, these 13 texts are my choice to fill that space.


Assets

Now with that, here’s the design files to reference if you’d like to build something similar yourself…

Enjoy!