The Commodordion
The Commodordion is an 8-bit accordion primarily made of C64s, floppy disks, and gaffer tape.
About the project
I've been tinkering with this beast, on and off, for about three and a half years. So from my point of view, the Sixtyforgan and Qwertuoso, where I first demonstrated the accordion-like keyboard layout, were spin-offs from this project. In fact, when I released the Sixtyforgan video in 2021, I already had an early version of the Commodordion standing by, but it wasn't presentable at the time. There was no acrylic cover on the back so the guts kept spilling out, and I hadn't coded the the rhythm-box mode for the left-hand side yet.
Things were slowly coming together, though. Once I was happy with the design of the instrument, there was the small matter of learning how to play it. As any budding accordion player can tell you, it's frustrating that you can't see what your hands are doing. Mirrors can help to a degree, but in the end you really have to go by feeling and muscle memory. The little red sticker on the right-hand-side “U” key is there to help me find my way when I have to jump from one area of the keyboard to another.
The rhythm box
The melody side of the Commodordion runs Qwertuoso. The accompaniment side runs a custom application for playing chords and loops, which I'll describe here. Technically both C64s load exactly the same program, but it's possible to switch between the two applications with a special key combination.
Once the accompaniment mode is up and running, the left-hand side is operated with single keypresses only—no key combinations are required. Commonly used keys are close together and, where possible, near the outer edge of the keyboard. It's nevertheless hard to reach some of the functions with the left hand, especially when setting up a loop. I'll return to the matter of ergonomics later in this article.
There's a live mode and a programming mode. Shift lock—a mechanical toggle switch on the C64—is used to select between them.
Live mode
In live mode, the three rows with letters on them represent chords. The layout is very much inspired by the Stradella bass system found on many accordions. The bottom row, from Z to Cursor Right, contains all the major chords arranged according to the circle of fifths. Thus, from any given I chord (tonic), you'll find the IV and V chords on either side of it. The second row, from A to Return, contains the minor chords, and the third row contains diminished chords. Thus, for instance, the keys Z, A, and Q represent C♯ major, C♯ minor, and C♯ dim, respectively.
When you press and hold a chord key and no loop is playing, the program simply plays the chord as an arpeggio and a bass note.
The function keys (F1, F3, F5, F7) start playback of one of four loop patterns stored in memory. When a loop is playing, pressing a chord key adapts the contents of the loop to the desired chord. The digit keys 4–9 set the tempo. Space stops playback.
Programming mode
In programming mode, most keys represent events (triggers or notes) that can be inserted into the current loop. There are drum triggers in the area near the right shift key. Five letters in the bottom row (Z–B) represent bass notes, namely the 1st, 3rd, 5th, 7th, and 8th note from the scale of the current chord (or in case of a dim chord, the actual chord notes). The nine letters on the second row (A–L) invoke the current chord in some fashion, as arpeggios or individual notes.
When no loop is playing, these keys simply trigger the event directly, allowing you to play around and find what you're looking for.
When a loop is playing, the event is recorded. The four function keys start playback—and thus recording—of a given pattern. Space stops playback. Clr/Home clears the current pattern.
The loop is divided into a number of steps, currently always sixteen, and recorded events are quantized to the nearest step. A metronome is heard whenever a loop is playing in programming mode.
The bellows
How the bellows work is explained in the video. But in the early stages of this project (such as when the material for the “montage” part of the video was shot), I had no idea of how I was going to measure the air flow. I went through a number of failed attempts before settling on the final design.
Hot wires and turbines
One approach was inspired by the fuel injection systems used in car engines. You attach a temperature sensor to a heating element (a resistor that's designed to dissipate power). Then you create a feedback loop to keep them at a constant temperature. If the air is still, most of the heat stays near the heating element. But if the air moves, more energy is needed to stay warm, as anybody who lives in a chilly, windy place will know. By measuring how much electric power the system is consuming, you can work out the air flow.
It sounds convoluted, but I figured that if car engines rely on this technique, it probably works. And I actually managed to build a working prototype. Unfortunately it didn't respond to changes in air flow quickly enough for musical articulation. My prototype ran at a temperature of around 50°C. I suspect that it would have responded faster if I had increased the working temperature, but I worried that I'd end up burning myself or even starting a fire.
So I went to look for alternatives. While I was reading up on anemometers and propellers, I came to watch a YouTube video about renewable energy. A man was explaining something—I don't remember what it was, though I'm sure it was interesting—while standing next to a wind turbine, and he had to shout in order to make himself heard over the din. Some of that noise came from the machinery, but a lot of it was unmistakably from the wind hitting the microphone. I remember the “aha” moment vividly: That's how I'm going to measure air flow!
The envelope follower
The envelope follower is implemented on a microcontroller. I sample the incoming noise rather crudely with an analogue comparator: If the signal is above a fixed (but trimmable) threshold, that sample is considered a one. Otherwise it's a zero. Summing the last 512 samples (i.e. counting how many of them were above the threshold) gives a number that's proportional to the amount of noise.
I compute this number as a running average, which has the side effect of low-pass filtering the signal. Then I apply an extra filtering step to smooth out the curve even more. This is a tradeoff: The response needs to be snappy enough for musical phrasing, but slow enough not to contain audible frequencies. With too little filtering, you'll actually hear some of the noise from the microphone bleeding into the sound. As you can see in the “set-up” part of the video, the volume changes are lagging behind the movement of the bellows somewhat, and this is a result of the filtering. The response is quick enough to work with musically, but I think there's room for improving this algorithm.
The noise level doesn't vary linearly with the bellow pressure, so I apply a gamma correction curve before sending the output to an off-the-shelf multiplying DAC.
This particular multiplying DAC is essentially a very long resistor ladder, dividing the analogue input voltage into 4096 equal parts. A 12-bit number is used to select one of the intermediate voltages and bring it to the output.
Mixing
The audio outputs from the two C64s are mixed together in equal proportions, and this combined signal becomes the analogue input to the DAC. As it happens, I prefer the melody side to be louder than the accompaniment side, but that balance is controlled from the application software by setting the master volume of each SID chip.
As I mention in the video, when you hold the bellows still, the volume doesn't drop all the way to zero. This feature would be easy to implement in the microcontroller, or even bake into the gamma correction table. But it's often a good idea, where possible, to defer mixing decisions until after recording. Stereo cables are handy: I actually send the DAC input (the mixed audio from both C64s, unaffected by the bellows) over the left channel and its output over the right channel. Thus, the right channel drops all the way to zero when the bellows stop, but the left channel is held at a constant level. I listen to both channels on my monitor speaker when playing, but they are recorded separately, so I can fine-tune the mix according to taste later.
The recorded audio is also subjected to a bit of eq, compression, and stereo reverb.
Ergonomics
The Commodordion has one huge flaw: It puts a lot of strain on the left wrist, arm, and shoulder. Most keys on the left-hand side are hard to reach, so the wrist ends up in a fully bent position, and at the same time the arm needs to carry a lot of weight while working the bellows. As a musician I take ergonomics seriously (and so should you!), so unfortunately I won't be playing this instrument very often, and I most definitely won't practice for hours to improve my left-hand technique. This rather undermines the potential for the Commodordion as a viable musical instrument.
But on a brighter note, I'm not worried about the right-hand side at all: That arm is in a sound, relaxed position. I'll be sure to bring that lesson with me as I continue to explore the design space of C64-based instruments.
Posted Friday 21-Oct-2022 17:14
Discuss this page
Disclaimer: I am not responsible for what people (other than myself) write in the forums. Please report any abuse, such as insults, slander, spam and illegal material, and I will take appropriate actions. Don't feed the trolls.
Jag tar inget ansvar för det som skrivs i forumet, förutom mina egna inlägg. Vänligen rapportera alla inlägg som bryter mot reglerna, så ska jag se vad jag kan göra. Som regelbrott räknas till exempel förolämpningar, förtal, spam och olagligt material. Mata inte trålarna.
Fri 21-Oct-2022 18:42
Fri 21-Oct-2022 19:57
Fri 21-Oct-2022 20:53
Fri 21-Oct-2022 21:06
Fri 21-Oct-2022 21:28
Fri 21-Oct-2022 21:46
Fri 21-Oct-2022 22:09
Back in the early internet, this functionality was a base feature for most websites. So I don't know why they would be fearful.
Fri 21-Oct-2022 23:46
Sat 22-Oct-2022 04:00
Sat 22-Oct-2022 04:49
Sat 22-Oct-2022 04:57
Sat 22-Oct-2022 05:58
Sat 22-Oct-2022 07:07
Sat 22-Oct-2022 07:58
Sat 22-Oct-2022 10:35
Sat 22-Oct-2022 11:37
Sat 22-Oct-2022 12:17
Linus Åkesson
Sat 22-Oct-2022 12:44
One possible downside is that the fan would have to respond equally (or nearly equally) to air flowing into or out of the bellows, whereas I think most fans are optimized for one direction. I also assumed they would have a large threshold of inertia before they start spinning, but I never got around to actually testing or measuring this, so I could certainly be wrong.
Sat 22-Oct-2022 14:37
Sat 22-Oct-2022 19:47
Sat 22-Oct-2022 21:45
Sun 23-Oct-2022 09:58
Sun 23-Oct-2022 10:19
Sun 23-Oct-2022 13:48
Sun 23-Oct-2022 18:40
Sun 23-Oct-2022 20:53
Mikel
Mon 24-Oct-2022 11:15
Mon 24-Oct-2022 19:31
Mon 24-Oct-2022 20:03
Mon 24-Oct-2022 22:53
Tue 25-Oct-2022 12:00
Tue 25-Oct-2022 21:16
Tue 25-Oct-2022 23:58
Wed 26-Oct-2022 03:31
—————————
Is it my imagination or is there a tremolo or pitch bending effect? Is there a modifier key for that or is it always on and most of the notes in the piece you played too short for it?
Wed 26-Oct-2022 11:47
Linus Åkesson
Wed 26-Oct-2022 19:41
This should be fixed now. Thanks for reporting it!
Yes, an automatic vibrato kicks in after about one second. This is a feature of Qwertuoso, and it can be turned on or off. In my Vocalise video, for instance, I keep it on for most of the piece but turn it off for the final note.
Fri 28-Oct-2022 20:04
Bruce Triggs
Sun 30-Oct-2022 01:03
Mon 31-Oct-2022 01:50
Mon 31-Oct-2022 18:33
Mon 31-Oct-2022 23:20
(Also i love the commodordion and want to make one of my own now lmao)
Tue 1-Nov-2022 19:21
Thu 3-Nov-2022 16:20
Fri 4-Nov-2022 02:40
Congratulations, and thank you!
Fri 4-Nov-2022 04:36
--------------
The frickin net knows everything about me. My word image is extubate. My son-in-law is an anesthesiologist. Intubate and extubate, with means putting a breathing tube in, and taking it out, is what he does.
Sat 5-Nov-2022 04:12
To think I just made industrial controllers with the C64.
Thanks for a flash to the past.
Love your Accordion-ish instrument.
Sun 6-Nov-2022 16:58
Mace John Rattington
Sun 6-Nov-2022 19:15
Mon 7-Nov-2022 14:57
Mon 7-Nov-2022 19:24
Former C64 owner from Finland.
Fri 11-Nov-2022 01:35
Fri 11-Nov-2022 16:26
https://youtu.be/HKP8l8jKjN8
Fri 11-Nov-2022 16:26
https://youtu.be/HKP8l8jKjN8
Fri 11-Nov-2022 22:49
Mon 14-Nov-2022 01:11
Hope you enjoy your toy and rock it out!
Mon 28-Nov-2022 11:46
Sun 8-Jan-2023 19:17
Great Job! It is amazing sound project for C64. Are you also going to release the custom application for playing chords and loops?
Regards,
Martin P.
Sat 14-Jan-2023 19:34
Ben in Seattle
Fri 3-Feb-2023 19:34
Sun 15-Oct-2023 18:30
One thought about the means to measure airflow - since airflow is generally proportional to pressure differential, have your considered the use of a differential pressure sensor? One side exposed to the interior of the bellows, and one side to atmosphere outside - via short pieces of tubing or hose if convenient. This could be separated from your main air vent, which itself could be made from a piece of hose if you would like it to be a little quieter than a simple hole. The advantages of a pressure sensor would include responsiveness, as well as removing the need to heavily filter its output to remove noise as you mentioned you do with the microphone method. Also, you could have separate response curves for squeezing versus stretching... and still apply your gamma function or any other you choose...
Mon 8-Jul-2024 19:23
Thu 17-Oct-2024 17:25