-
Arduino Test sketch
03/22/2018 at 01:34 • 0 commentsTonight I have made a start on developing a sketch for the Arduino.
The Arduino has two main functions in this project; to read a variety of buttons and sensors, and to send a command to the Pi based on its readings.
For testing and prototyping I have decided to write a simple menu for the LCD button shield that allows me to manually select data to send.
At present the left and right buttons cycle through the chromatic note scale, and the up/down buttons step the range number up and down. The select button outputs both the note and range to serial.
The arduino is also running a function that reads both potentiometer readings and combine them. This function does not appear on screen just yet, but it will certainly be used at the core of any slide processing that will determine the note being played.
Next step is to develop the python scripts some more and add a serial handle, then I will be able to transfer development from my Tinkerboard 👌
-
Making a Start
03/17/2018 at 00:25 • 0 commentsNormally it takes an age for me to formulate and out a plan of action down for a project, however this one has fallen into place rather quickly!
Today I have put in place my prototyping board:
An Asus Tinkerboard w/Justboom Amp/DAC hat
Arduino Mega w/lcdshield (plus a wifi shield underneath. No plans on using it in this project).
Two potentiometers.
This little setup will allow me to test everything from getting data from the (currently hypothetical) slide mechanism using the pots, start work on formulating the serial data to be sent to the Pi from the Arduino for notes, work on using the lcdshield and buttons as a method of menu control to the Pi/Tinkerboard, and also work on how the Pi will handle that data.
I also had a little play with Fluidsynth on my laptop (an aged beast running the Pi x86 Desktop OS) and it took me ten minutes to get all dependencies installed and notes coming out via python script. Great start so far!!
-
The slide mechanism
03/16/2018 at 21:50 • 2 commentsThis is the area that will need the most thought, investigation and research I feel.
7 distinct note positions, with the areas in between still selectable, all in one smooth and easy to use mechanism.
My first thought was to somehow fabricate a >50cm slide potentiometer to mount in the frame.
Second idea would be to use 7 standard slide potentiometers all in a line, and create a mechanism for the bar moved by the player to move the slide pot as it passes.
If pot 1 is reading 0 we know the slide is in position 1 and would sound note one on that pitch; any other reading would indicate a pitch bend down in that note (as the slide has been moved out). Once pot 1 hits 1023 we know that the slide has reached position 2 and can start reading pot 2 for the pitch bend value, and so on and so forth.
This second way would take a lot of refinement to get a smooth output from the Arduino but having the range of 7 full potentiometers (compared to the one pot idea) would give a far greater degree of accuracy.
-
Prototyping
03/16/2018 at 07:11 • 0 commentsI am going to build my prototyping onto on of these boards:
I have another one which I will load with my Justboom amp/DAC and a Pi, alongside an Arduino Mega with a display shield.
-
Controls: Revision
03/16/2018 at 06:58 • 0 commentsJust a note for myself here, really.
Rather than using combinations of buttons to determine pitch look into using two buttons to allow the player to cycle up and down through the ranges.
Also add momentary buttons to 'Octave up' and 'Octave down' for quick jumps when the range cycling won't be fast enough.
Volume control - use a thumb trigger on the left hand to control note velocity.
Also add a note on/off momentary switch where a mouthpiece could go and use lip/chin to trigger notes on or off, or use a traditional mouthpiece with some kind of air sensor in it.
Also project name:
I may update the name to RaspBone or TinkerBone depending on what board I settle on.
-
Software
03/16/2018 at 06:48 • 0 commentsMy initial thoughts and research on how to create the software side of this project has brought me to Fluidsynth.
Fluidsynth is a fantastic bit of software with many features, but one feature is exactly what I need; it capable of generating notes from MIDI data using a loaded soundfont. With some work this could carry out exactly what I need the Pi to be doing in this project.
Fluidsynth has no GUI and is operated via command-line. It has a python module on Github too. This is fantastic - I will be able to write my own python scripts and control it exactly the way I like.
The Arduino could even just pass simple commands rather than MIDI data and have the Pi then generate the midi to pass to fluidsynth.
Hurrah!
-
Construction
03/15/2018 at 21:49 • 0 commentsFor the hardware there are many options.
My gut feeling is to go for Aluminium extrusion; easy to assemble, and it'll be easy to mount components to it.
Assembly will be rather trombone like, built from two, elongated U-shaped parts.
The first part will be the slide mechanism. Rather than an assembly that moves, there will be a thin bar that will slide inside the extrusion.
Moving this will adjust the a potentiometer of sorts (still undecided on this element).
The second part (not as long as the first shape will join the 1st part at a 90 degree angle, giving that trombone shape.
On the other end of the U shape a bracket will be created to hold a speaker, for on-board output.
A DIN rail will be mounted through centre to allow for an easy and modular electronics section.
The electronics will comprise of:
Battery Pack outputting 8v-24v
Pi/Tinkerboard with Justboom Amp and DAC combo.
Arduino
The Justboom Amp accepts 8v-24v via it's barrel connector and powers the amp, DAC and Pi from this input.
The speaker connects to the amp hat also (either 4Ohm or 8Ohm. I'm going to be using a car speaker at first).
The Arduino will read any buttons and potentiometer values and use those to send MIDI information via USB to the Pi.
The Pi will be running software to interpret that midi data and turn it into sound using a VST or other virtual instrument software.
Depending on the software I use I may either add an Arduino lcd/button shield to control sounds and settings, or I may use a webserver and change settings via Wi-Fi.
-
Note production
03/15/2018 at 08:01 • 0 commentsA traditional trombone features a slide which the player adjusts to adjust the pitch of the note, and in combination with pitching the original note on the mouthpiece, can create a wide range of notes.
There are 7 positions on a slide, and let's say are range of 6 notes per position, gives me 42 potential notes to recreate.
To select the note range I will use momentary switches, operated by the players left hand. They will need to be ergonomically placed to allow comfortable use while supporting the instrument weight.
So far either using slide potentiometers or even ultrasonic sensors could be used to capture the slide movement.
-
Rough plan
03/14/2018 at 21:58 • 0 commentsimagine a trombone, with a speaker in the bell.
Pi mounted to the stock, Arduino reading sensor info and sending to Pi for processing.
Pi outputs to speaker but also has headphone out or midi out.
Battery powered.
Switches on the the left hand hold to control octaves/pitch of slide.