Close

Log #7 How to connect to phone and use Fluidsynth to create music

A project log for The Digi-Gurdy and Digi[Nerdy]Gurdy

MIDI electronic portable practice hurdy-gurdy: It's always in tune.

xenonjohnXenonJohn 08/23/2019 at 23:303 Comments

This video update shows how you use a phone to play the MIDI data coming out of the DigiGurdy.

The soundfont file (.sf2 format) has to have been uploaded onto the phone in advance. I will make this file available soon. All the sounds to be played are stored in this file.

The MIDI player I am using is called FluidSynth and is available free from the Google Play store for Android phones. An Apple version also exists but I have not tried it with the DigiGurdy.

The DigiGurdy outputs data on 5 MIDI channels. In FluidSynth we must assign an instrument or sound to each of these 5 channels for it to work correctly. This is best explained with a video and so the video below shows me setting up Fluidsynth on a phone in this way. FluidSynth has a very basic user interface but it also has very low latency (time between pressing a key and hearing the sound) and so works well with the DigiGurdy.

Discussions

XenonJohn wrote 08/24/2019 at 21:53 point

Good ideas. I have written a few Android apps the cheat way using MIT App Inventor II. I did consider a phone holder of some sort actually on the DigiGurdy itself but for now the phone holder that clips to the edge of a table works quite well. It is actually designed for the front edge of car dashboards. Is there any variant of FluidSynth out there with a nicer user interface by any chance, or one that can just remember your last-used setup? That would be quite useful.

  Are you sure? yes | no

Craig Hissett wrote 08/24/2019 at 23:42 point

Ah yes, I've messed about with App Inventor, but never done a trying worthwhile with it. I'm becoming quite handy with Visual Studio at work so I will probably go that way :)

I haven't come across any android based variants I'm afraid. There's some useful python code that works with Fluidsynth; it wouldn't take too much to whack a Pi into the project and create a web-based GUI?

  Are you sure? yes | no

Craig Hissett wrote 08/24/2019 at 00:15 point

I'm a big fan of fluidsynth on android. I've used it to test resding drum pads on my drum controller project, and I'm contemplating using it within my Wi-Fi trombone project too; connect an old phone to the arduino controlling the slide and sensor readings, then use the phone's audio output to run to some more powerful speakers.

If i build the phone into the back of the trombone it'll give a nice easy interface for changing sounds and suchlike. It also opens the door to an android app being written to manipulate the Arduino settings via the serial connection.

  Are you sure? yes | no