Posts

Showing posts with the label Arduino

Peak Heath-Robinson

Image
Updated 13/02/2025 Among my many happy follies, I've started setting up to make some electronic music. I've been an electric musician for most of my life, but EDM isn't something I've dabbled in a lot, despite loving the sheer power of it. In all modern genre's, the synth reigns supreme! I'm particularly interest in trying it live and without a computer as my digital audio workstation, a technique known as "DAWless." It's more performative than using Logic Pro on my Mac, the latter a process that feels like being back at work, sometimes. Using drum machines, sequencers and synths is mostly just a matter of turning on the power and pushing a few buttons. That's the theory, anyway. The trouble is, I'd also like to record the good performances, too, but also still have the ability to tweak the knobs on the front panels in a way that fundamentally changes the tonal qualities of the sounds. Not just volume, EQ and pan, but timbre, voicings an...

Finding a MIDI Note From the Period of a Waveform or Finding it from a String/Fret Grid, That Is the Question!

Image
Sometimes the internet is wonderful and the search engines just provide what is asked for, a veritable (if not always verifiable) cargo cult of bounty. Then it sometimes isn't. Take this formula, for instance, it calculates the note number for a Musical Instrument Digital Interface (MIDI) Note On or Note Off command from the pitch of a note. Deriving the nearest MIDI note number from a tone of a given pitch. (Source: Google Search.) This is all well and good if you're talking about theoretical pitches, or working with a high end, high speed microcontroller that can measure a frequency quickly and spit out a MIDI command, but I like my microcontrollers low cost, like the venerable Atmel 328p. You can measure pitch with one of these, but you have to convert the wave's period to pitch, because the processor isn't really up to having a built in frequency counter. The way to do this is to measure the wave's period directly with the pulseIn() command, like so... byt...

Drum Robot (SoléBot) Motherboard Works, meanwhile Behringer's 606 Clone has MIDI. Hmmm...

Image
When you go a-scrolling, entering the search terms "drum robot" into your default "sengine," a few things come up, like Compressorhead's heavy metal covers, a million dollar pneumatic actuated robotic live band. Then there are the usual, incomplete, or niche, hobbyist things, basic busker gimmicks or student science projects. All good, valid stuff, sure, but none of it generalised. Well, there's some SparkFun stuff and an art project, too, but the generalisations are perhaps... too general? So, generalising a robotic drum kit development kit seems the unfilled niche. So that's what I've started to turn my own drumming robot system towards. Meanwhile, looking at the other kind of drum robot, arguably the first modern ones at least, analog drum machines, the latest crop of 606 clones from both Roland and Behringer, have MIDI, a luxury the originals couldn't afford while aiming for a sub-1980s pricepoint with 1980s tech in the 1980s. MIDI is the l...

The EdgieD Arduino State Change Detection Library

EdgieD Library v1.0.0  Crunchysteve, ©2024. Proudly developed and tested in VS Code and Wokwi.com  Quick Install For most people, open ArduinoIDE, open the Library Manager, search EdgieD and click "Install."  For tools like PlatformIO, download the zip and install in your libraries folder the usual way or use git in the Terminal.  What is EdgieD? Loosely based on the button edge detection tutorial at... https://www.arduino.cc/en/Tutorial/BuiltInExamples/StateChangeDetection but generalised for working with variables and other coded binary state changes. It can read digital inputs to detect a button state change, the state change of a variable during runtime, the output state of a timer or the output states of other custom libraries. The included example detects the default "leading edge" (as pressed) of a button, attached between pin 2 and ground, not changing output state again until released, then pressed again.   It can be used for...    ...