Introduction: Simple Midi Flute/Recorder Controller (EWI)

Picture of Simple Midi Flute/Recorder Controller (EWI)

As a child (about 30 years ago) I started my music lessons on the flute (a recorder to be precise) and now I want a modern electronic version of this instrument (an Electronic Wind Instrument as it's called, abreviated EWI). They are available, but prices start from €350/$400. So I decided to make one myself to see if I could make it cheaper.

Ideally my electronic recorder would also be capable of making it's own sounds like a synthesizer, however although I'm not entirely new to electronics, I’m not an expert either. Also I wanted a design achievable/understandable for beginners with low cost and easily obtainable parts. So decided to start with the most simplest form: a midi controller looking and playing like a recorder using push buttons and air flowspeed detection. The midi recorder connects via a midi-to-usb adapter to a computer which produces sound using a software synthesizer (on a pc, freeware), and (optionally) send it back to the a speaker inside the midi recorder.

The cost of this simple midi recorder turned out to be less than $40!

Although not quite as advanced as a commercial EWI and the construction is my first try, it works fine and I think it is a good base to make all sorts of improvements:

I'll probably show you some of these improvements in a follow-up instructable.


Disclaimer: This instructable describes what I did to make this midi controller. Be aware I'm no electronics or wood expert and don't know much about safety of finishes/paints. (Most of the knowledge I used, I obtained from others and I judged this information to be safe/healthy for my own personal use). You should use your own judgement whether it's safe and healthy to do the same. By using this instructable in any way, you and only you bear the responsibility for all damages occurred by using this instructable.

Step 1: How It Works and What We Need to Make

Picture of How It Works and What We Need to Make

How it works

As mentioned in the first step, the setup consists of three main components: a computer, a midi recorder controller and a converter which translates the serial midi received from the controller to usb signals the computer receives and sends to the software synthesizer. The first picture shows a schematic of the components above and the data flow between them.


What we need to make

  1. Computer: Install a vst-host and find a audio synthesizer plugin.
  2. Midi2Usb converter: Add a audio cable tot usb side of the converter which receives audio from computer. Replace the Serial Midi (DIN-5) cables with a custom cable to the recorder which provides power to the controller, receives midi data from the controller (to be send to pc) and optional another cable to send audio (generated by pc) to the speaker inside the controller.
  3. Midi Recorder Controller: Detects finger presses (with 9 pushbuttons) and airflow/breath (with a microphone which registers audio level) and converts this user input to serial midi (with an Arduino). Also outputs audio received from the pc (amplifier and speaker).The second picture shows you how the end results looks, The following steps in more detail how to make the components.


The instructable can be divided in two parts

  1. Part I - step 3 to 7: setup the computer, modify the Midi2Usb converter and make the basic parts of the Midi Recorder Controller so it’s able to communicate with the computer and play a simple (midi) tune.
  2. Part II - step 9 and further: we will add the user input (buttons and breath flow sensor) to the Midi Recorder Controller as well as install the optional speaker.

Step 8 explains how to test your setup and can be used from step 7 onward to constantly check if your modifications ‘broke’ something.

(Installing the speaker in the midi recorder and attached the audio cable/plug to the Midi2Usb converter are optional if you don't mind the sound coming from your computer.)

When using the terms recorder and controller alone or together, you should read midi recorder controller.

Step 2: Tools and Supplies

Picture of Tools and Supplies

You'll need some supplies and basic tools. I got almost all my electrical supplies from ebay, and the rest from a local DIY-store.


Supplies

Part I - step 3 to 7

With these supplies you can test (step 8) if the setup works (plays sound, although without user input since buttons/breath sensor not yet installed)


Part II - step 9 and further (to finish the midi recorder)

Optional - Needed if you want to install a speaker inside the midi recorder:


Some remarks:

  • Prices can be outdated
  • Dimensions of wood and cable conduits are suggestions and can be altered.
  • I used a telephone cable between midi recorder and midi2usb converter. Other cables like utp/internet cable is also possible (use RJ45 socket). You can also omit the socket and solder the midi2usb converter directly to the midi recorder.
  • Instead of screwing the ducts back to back, you can also glue them together, in which case you don't need the 4mm nuts and bolts.
  • Since you put the midi recorder in your mouth you should use a coating which is safe for your health.
  • Make sure the mic breakout is not a sound-dectection-only board (which only outputs detection events), but actually outputs the sound level/amplitude.


Tools needed:

    • Drill
    • 10mm drill bit
    • 4mm drill bit (to connect ducts, same size as metal nuts and bolts)
    • 2 and 3 mm drill bits (to mount speaker and drill sound holes in lid)
    • Small files
    • Saw (to shorten ducts and wood strips)
    • Screwdriver (suitable for cabinet connectors)
    • Soldering Iron
    • Hobby knife
    • Sandpaper
    • Paint brush

    Step 3: Enclosure of Recorder

    Picture of Enclosure of Recorder

    First we need to make an enclosure. Since I found hard to find regular plastic electronics enclosure which are narrow and long enough, I had to look elsewhere and stumbled upon cable raceways/ducts.

    To start obtain a plastic cable raceway/duct like the one in the picture. If you cannot obtain this type of duct no problem, but be sure your duct can house the electronics (I wouldn't buy a much smaller duct). If your duct dimensions differ, also be aware you have the modify the dimensions of the wooden strip and block.

    My duct has a double bottom, this is not necessary and in fact only troublesome.

    Cut two pieces of duct at a length of about 400 mm. These pieces should be mounted together back-to back. My duct had nice holes predrilled to mount it to the wall, which I used to screw (4mm nut and bolt) them together. However you can also use glue (probably the better choice).

    Step 4: Power Distribution Board

    Picture of Power Distribution Board

    Multiple components will need to be provided with 5V and GND and our Arduino only has 1x 5V pin and 2x GND pins. Because of this I added a power distribution board. This board is made by:

    1. using a strip of perforated board, just wide enough to fit in de enclosure (upper duct), but not small enough to fall out,
    2. running/soldering two pieces of (stiff/thick) stripped wire lengthwise to the board (the 'rails') to which all other 5V and GND lines in further steps will be attached,
    3. attaching a flexible wire to the 5V rail to be later attached to the RJ11 jack in the bottom duct and
    4. attaching a flexible wire to the GND rail to be later attached to the RJ11 jack in the bottom duct.

    The circuit board should be placed at the beginning of the upper duct. The flexible wires need to end up in the lower duct. For this you can drill a hole through both ducts. (However I used the slots for the Arduino-pins in the next step.)

    Step 5: Arduino Nano

    Picture of Arduino Nano

    I had to divide components over lower and upper duct and choose to place the Arduino Nano and Microphone (Breath Flow) sensor into the lower duct. However the Arduino Nano needs to connect to the power distribution board and buttons in the upper duct. A passage way for the wires between upper and lower duct is needed.

    Often the Arduino Nano will be shipped to you with male pin headers (first picture). However I found it easier to attach other components if I use female pin header on the Nano. So I soldered these on. (You don't need to solder on the ICSP (2x3) pinheader, but if you do, you should make an extra opening between lower and upper duct to provide room for these pins.)

    The Nano should be put in lower duct (fourth picture) leaving enough room to install the microphone sensor board in a later step with an extra 1 cm margin.

    To plug in wires from the upper duct into the pins of the Nano, I made two slots between the two ducts (fifth picture). I used a Dremel and small file for this, but a drill and small file should also work.

    The Arduino Nano’s pinheaders are pushed into the slots, This will also keep the Arduino Nano from shifting in de lower duct, so I didn't need to glue/screw it in place.

    This fifth picture also shows you that the female pin header can be stacked. By soldering female header to the wires of other components (e.g. the wire ends of the buttons as shown in the picture) you can easily plugin wires into the Arduino through the slots.

    Next thing we need to do is connect the Arduino to the power distribution board. Take two flexible wires just long enough to span the distance between the power distribution board and Arduino pins in the upper duct, Solder one wire to the GND rail and the other to the 5V rail of the power distribution board. Then solder these wires to the outer pins of a female pin header of three pins. (So the middle pin has no wire attached.) This 3-pin-header should be plugged into the 5V-RST-GND pins. (See last picture/drawing which highlights the correct pins.)

    Step 6: Midi to USB Converter

    Picture of Midi to USB Converter

    We only need 3 wires for the midi recorder to work: 5V, GND, and midi out. For the connection to the Midi2Usb converter, a telephone cable seemed a good choice, also because of its flexibility. Because I wanted this cable to be detachable, I installed a telephone (RJ-11) socket.


    Install and connect RJ11 socket

    The socket is installed next to the Arduino Nano. Because it is slightly higher than the duct, I had to make a hole for the socket to poke through. Since I made the hole a little bit too small for the base of the socket it can't fall through and I didn't need to glue the socket in the duct. As the sockets can differ slightly in size and shape you may have to alter this for your specific socket and/or (hot)glue it.

    The third picture with the schematic shows how to connect the socket:

    • pin 1 of RJ11 soldered to a flexible wire routed to the upper duct (via the hole for the 5V/GND wires in step 4) and soldered to a 220 ohm resistor which should be inserted into the TX/D1 pin of the Arduino Nano (see second picture).
    • pin 2 of RJ11 soldered to the flexible 5V wire from the distribution board in step 4
    • pin 3 of RJ11 soldered to the flexible GND wire from the power distribution board in step 4


    Modify Midi2Usb device

    The third picture also shows how to make the telephone cable to the Midi2Usb device. So I replaced the midi-in and midi-out cables of the Midi2Usb device with the telephone cable and attached the wires in the cable as follows:

    • Wire from pin 1 of plug - to midi IN of Midi2Usb (located at the midi side of the Midi2Usb)
    • Wire from pin 2 of plug - to 5V of the Midi2Usb board (located at the usb side of the Midi2Usb)
    • Wire from pin 3 of plug – to GND of the Midi2Usb board (located at the usb side of the Midi2Usb)

    See last three pictures for the results.

    Step 7: Arduino Sketch and Software Synthesizer

    Picture of Arduino Sketch and Software Synthesizer

    In this step we program the Arduino and install the software synthesizer.


    Programming the Arduino Nano

    If you are not familiair with the Arduino platform check out their website: https://www.arduino.cc/en/Guide/HomePage. For the windows platform you have to follow these steps:

    • Make sure you have the Arduino IDE installed (additional libraries are not necessary) and the driver to connect to your Arduino Nano.
    • Download the file 'MidiRecorder_PianoFingering.ino' file/sketch included in this step (scroll down).
    • Open your 'Documents\Arduino' folder, make a new folder there and call it MidiRecorder_PianoFingering' (If this folder is not the place where you keep your sketches you probably are experienced enough with the Arduino IDE to figure the proper steps out yourself :-) )
    • Place the downloaded file in this new folder.
    • Connect your Arduino to your pc via USB.
    • Open de Ino file within your Arduino IDE
    • Make sure you have selected the right development board (Arduino Nano 168 or 328) and have selected the right COM port.
    • Press upload to upload the sketch to your Arduino Nano.


    Explanation of sketch

    I tried to keep the sketch as simple as possible and decided not to use flute fingering (in which notes are combination of button presses), but piano fingering (in which each button press is different note):

    • Setup - In the setup we tell the Arduino that the pins connected to the buttons are input pints. If the thumb button is pressed (or no buttons are attached) we set the state variable to demoMode.
    • Loop - if state is demoMode - A melody is send to the computer to synthesize. The melody is a string (e.g. "c4 d2 e4") in QBasic style (https://en.wikibooks.org/...#PLAY). The melody repeats after 2 seconds.
    • Loop - if state is NOT demoMode - We determine the volume of sound received by the microphone (=maximum difference between analog signals) and send a volume midi ('Control Change') message. Also we check all buttons one at a time for their state. If newly pressed we send a noteon ('Channel Voice') midi message. If the thumb buttons is also pressed the note we send will be a sharp one. If newly unpressed we send a noteoff midi message.

    For more info about how midi works, see this excellent instructable: https://www.instructables.com/id/What-is-MIDI/.


    Setting up the software synthesizer

    Software synthesizers (vst) often come as plugins with file extension dll. These plugins need a host to run. A nice free vst-host is savihost. I choose the VST2 version, including keyboard. You can download it from http://www.hermannseib.com/english/savihost.htm.

    You can use almost all vst plugins you like, since we only send the most basic midi messages to the synthesizer (noteon/noteoff and volume change messages). Some suggestions on plugins (all free to use):

    I like to use Lxox_Flute because of it's simplicity and nice flute simulation. Elek7ro is also not too hard to understand and lets you create other instruments. Synth1 has a nice set of predefined wind instruments and lets you remap your breath volume to another effect. TX16Wx lets you use your own sample sounds (wav-files). Kontakt 5 has a nice solid feeling to it.

    To run a plugin you need to rename (or copy) savihost.exe to match the filename of the vst-plugin dll-file. After running the new exe, make sure to activate midi in menu 'Devices'>'Midi' and set the 'Input Port 1' to your midi2USB device (see first picture).

    Note: I noticed the Lxox_Flute plugin does not make sound on low octaves. The Arduino 'Oct' variable is set to octave 5 which works on my setup. If this doesn't work on your setup (improbable) you can change the Arduino 'oct' variable or transform the octave via VSTHost menu 'PlugIn' > submenu 'Transformation' > set 'Channel' to '1' > set 'Transposition' to '+1 Octave' (see second picture).

    Step 8: Testing the Setup

    Picture of Testing the Setup

    At this point we can test if the communication from Arduino to software synthesizer (on computer) is working:

    1. Attach your midi2usb converter to your computer.
    2. Start your software synthesizer and select your midi2usb converter (in my case ‘USB2.0-MIDI’) as midi input device.
    3. Attach your midi recorder to your midi2usb converter (plug the telephone cable into the RJ11 jack).

    Because we don't have any buttons installed, the Arduino Nano will enter demo mode and send a melody through the midi2usb converter to your software synthesizer. The synthesizer converts this midi info to sound which you here coming out of your computer!

    Step 9: Add Buttons

    Picture of Add Buttons

    I installed 8 buttons in the upper duct and 1 (thumb) button in the lower duct.

    The buttons are soldered to a piece of perforated circuit board just small enough to slide into the duct, but not too small to prevent it falling out. My perforated board is only wide enough for four buttons, so I needed two pieces for the upper duct and one small piece for the lower duct. I also found it more comfortable if the pink button has less distance to the previous button than the others.

    We need to provide every button with ground, 5 volts and a data line. The circuit picture shows how to connect the buttons (dashed ground line is on the back side of the perf board, red and purple solid lines are on the front side of the perf board). In the overview picture you can see that I routed the (purple) data lines of the right board underneath the left board so the cables wouldn't prevent the lid to close.

    I soldered the data lines of the buttons in the upper duct to a female 8-pin header for easy insertion into pin D3 to D10 of the Arduino Nano. The 5V and GND lines were connected to the 5V and GND rails of the power distribution board.

    The data line of the thumb button was routed through the hole between lower and upper duct and inserted into D11 of the Arduino Nano. (In this case using a female 2-pin header.) You can also route the 5V and GND lines of the thumb button through the hole and solder them to rails on the power distribution board. However I soldered them directly to 5V and GND of the RJ11 socket to minimize on the amount of wires going through the enclosure.

    After installing all buttons (upper duct and lower duct) we can drill the holes in de lid. I used a 10mm drill bit. This is a bit larger than needed but gives some room for shifting the button boards in the enclosure without the buttons catching the side of the holes and coming stuck after pressing them.

    After this I placed the lids and install the button caps. The boards should sit high enough in de duct to give the buttons enough room to be pressed down. Two buttons didn’t sit high enough and couldn’t be pressed down, so I slid some paper underneath the board to lift the button up towards the lid.

    Note: If you want to install the speaker, you need to keep extra room between the thumb button and the RJ-11 socket to place the audio socket in step 11.

    Step 10: Airflow Sensor Board

    Picture of Airflow Sensor Board

    The microphone sensor board will be used as a simple airflow sensor and listens
    to the amount of sound your breath makes. The harder you blow, the higher the audio volume that will be detected.

    I installed the sensor board it in the bottom duct. Since my board came with the microphone up-right (see first picture), I had to bend it to lie on its side (see second picture). There are also variations of this board with the microphone already on its side.

    The microphone board has a potentiometer which makes it too high for the duct and this potentiometer has a screw to fine tune the microphone. So I needed to make a square hole in the lid to make room for the potentiometer and to keep the screw accessible. For this I drilled two (round) holes next to each other and used a small file to square the shape.

    The board should be connected to ground and 5V. The analog pin on the board is connected to A0 of the Arduino. All wires are routed through the hole between bottom and upper duct.

    Step 11: Optional - Speaker and Amplifier

    Picture of Optional - Speaker and Amplifier

    This step is optional and only needed if you want the sound to come out of your midi recorder instead of your pc.

    Also I first tried to send the audio signal over the remaining wire in the telephone cable. However I soon found out that due to interference the sound quality became very bad. Because of this I used a seperate audio cable to transport the audio signal, which gave much better sound.

    The only common connection between the audio circuit and the arduino circuit is the 5V coming from the telephone cable (and besides powering the arduino/buttons/microphone via the power distribution board) which also powers the amplifier board. So there is no direct ground connection (adding this seemed to enhance the audio interference) and I rely on the ground circuitry inside the pc. Consider if you find this wise for your own build!

    In this step the audio socket, the speaker and amplifier are placed in the lower duct. The socket is placed between the RJ-11 socket and the thumb button, the amplifier board is placed on the other side of the thumb button, the speaker at the end of the duct.

    The speaker just fits if we trim the receding rims to make some room (first picture). I used a hobby knife to carve the inner rims away. Then I attached two wires to the speaker (green and white).

    Next up is drilling the holes. Since we want to mark where they need to be, I applied masking tape to the lid. (This also makes removing the markings a lot easier.) First I marked the corner holes to fix the speaker to the lid using small bolts. I used the speaker as a template to mark the corner holes and drilled them with a matching drill bit (2mm, second picture - red circles). After this I drawed a grid on the lid to mark all the sound holes and used a slightly bigger drill bit (3mm).

    The amp board was placed between the thumb button and speaker (see fifth picture, second one from the bottom). 5V of the amp board (bottom left) can be connected to the power distribution board, but since the thumb button also has 5V and to reduce the wires, I connected the amp board here. The audio wire (green) from the audio socket was connected to the audio-left-in of the amp board (upper left). The ground wire (white) from the audio socket was connected to audio-ground of the amp board (upper left).

    Only thing left is connecting the speaker wires to the audio-out-left of the amp board (upper right). It is not really important if we attach the white speaker wire to + or -, (but would be if we would have connected two speakers.)

    Bottom picture shows the closed duct with speaker and amp board inside.

    Note: The second picture from the bottom shows a schematic instead of the photo of my resulting lower duct. This is because my RJ-11 cable broke and without a new one at hand I removed the RJ-11 and audio sockets and installed a perforated board instead. To this add-in board, I soldered the RJ-11 cable and audio cable. After this I connected the 5V/GND wires coming from the power distribution board, the midi wire from the Arduino TX pin and the audio/GND wires from the audio-cable.

    Step 12: Mouthpiece and Wooden Sides

    Picture of Mouthpiece and Wooden Sides

    Shaping the mouthpiece

    For the mouthpiece use a block of wood equal or slightly larger than the dimensions of the ducts. For my ducts this was about 24 mm thick and 28 mm high. I choose a length of 70 mm. Next I made a nice shape for the mouth using first a coarse file, followed by finer files and finally fine sandpaper.

    The schematic shows how I shaped the mouth piece and where I drilled the holes for the air channel. The diameter of the holes on the mouth side are 2mm-4mm and are filed down to a nice oval opening. On the back two holes are needed: A hole at the bottom which exits to the microphone (via an inserted straw) and a hole in the middle which connects the mouth opening to the opening for the straw. The end of middle hole is plugged so all air exist via the straw in the bottom hole. The diameter of the holes on the back end depends on the diameter of the straw you use, which in my case was 10mm. This diameter also depends on the air flow you feel comfortable with and of course what type of straw you can obtain/buy.


    Preparing the straw

    The mouthpiece and microphone sensor are connected with before mentioned straw. This air you blow in the straw will contain harmful moisture, so I put a piece of plastic foil (from a sandwich bag) at the end of the straw. (If the foil at this end is pressed against the microphone, the sound will still be detected.) However now the air cannot escape, so I cut a hole in the straw and a corresponding opening in the bottom duct at the corresponding position.


    Securing mouthpiece to enclosure

    The only simple solution I could think of to secure the mouthpiece to the enclosure was to connect them with wooden strips at either side.

    I made the strips as long as the combined length of the enclosure and my mouthpiece (470 mm in my case). Using standard wood glue I first glued the sides to the mouthpiece. Next I placed the enclosure in between and drilled two holes through at the beginning and end of the enclosure, avoiding hitting any electronics. Using cabinet screws (see last picture) I screwed the plastic enclosure in between the strips.


    Protect the wood from moisture

    Especially the mouth piece needs protection from moisture in your mouth.

    I applied a clear finish (multiple times) to the outside of the mouth piece and also (for aesthetic reasons) to the side strips. I used a toy safe "rust-oleum clear sealer satin - toy safe"

    Also the inside of the mouthpiece (the air channel) needs protection. I treated this with a little bit of vegetable oil (olive should also work).


    Alternative straws

    I tried some variations on the straw design, see second picture. I expected the second double straw design to be more effective since it forces the air stream to pass closer by the microphone. I also expected the dogwhistle to be more effective since it produces sound (inaudible but sound nonethteless). By more effective I mean that the sensor values should be more stable and easier to (graduately) manipulate with your breath.

    I was suprised to find the other designs made no significant difference, and it was even more difficult to reach a high sensor value with the dog whistle. Since the original design is easier to build than the double straw design and cheaper than the dog whistle, I decided to stick with it.

    Step 13: How It Sounds...

    I recorded some audio samples to give you an idea how your result might sound. I maximized the volume for optimum sound resolution. You might want/need to turn your volume down!

    1. Demo with gradually increased air flow / breath with the Synth1 plugin, with instrument '81:Square lead'

    https://www.youtube.com/watch?v=7-Y3K0Y8nJQ

    2. Flute synthesis with the Llox_Flute plugin

    https://www.youtube.com/watch?v=HScyJ3kJcQY

    3. Star wars theme with the Synth1 plugin using SynBrass and Sax intruments.

    https://www.youtube.com/watch?v=o-IGGUbUlEQ

    https://www.youtube.com/watch?v=m5bny5rwt2E

    Note: It was 30+ years since I last handled a flute and never became very good at it. So especially the Star Wars theme is sort of a worst case demo!

    Step 14: Acknowledgements and Links

    I got advise on how to protect the mouthpiece from moisture from the following sellers of recorders:

    I bought the sealer to treat the mouthpiece from:

    For info on how to use midi on an Arduino see the following Instructables:

    Audio was recorded with the integrated recorder of Savihost:

    TunesToTube was used to convert the audio samples to youtube videos:

    Comments

    NardJ (author)2017-03-02

    Hi, thx for your nice comment! The mic input is averaged (line 199) using the decay variable. Reducing the value (line 145, default=95%) will reduce latency, but also will make the breath response a bit more jittery. You will need to try and test some values (0-100). (To be safe, you should also check if your synth-software does not cause the delay.) I myself did not notice a large decay btw, but maybe I'm just not that observant.

    You can connect the pots to the analog pins of the arduino, read their values in the loop function and send a midi command depending on the analog value on these pins (use the midi function at line 323). The challenge probably is finding the correct midi codes and setting up your synth-software to respond to them. I did not try this, so I haven't got any code, but it shouldn't be that difficult. Cheers and have fun!,

    GiacomoL4 (author)2017-03-01

    Hi nardj, very nice project! Is there a way to reduce latency between the mic input and digital output? I've made a little prototype with just one button, but the time between "in" and "out" is about 0,5 sec or more... How about the latency of your complete project? it was good?

    I really like to add potentiometers to the final project to control virtual filters, effects, etc...
    What should I do if I want to add potentiometers to control virtual "knobs" of the synth interface?
    thx a lot!

    NardJ (author)2016-12-30

    Hi MJBauer, very nice build! Do you have a demo video? (I only see one labeled 'awful') And what is the price tag of the components?

    Maybe you could put it on instructables, only a bill of materials and a little more info on constructing would be necessary. I really like the open case and how clean it looks!

    mjbauer (author)NardJ2016-12-30

    The "remi" is still a work-in-progress. When version 2 is nearer to completion, I will (1) make a better demo video, (2) make a bill of materials and calculate the build cost, which I expect will be under $100, and (3) provide more details on construction, maybe post on Instructables. Note that my project is only suitable for people with good electronic prototyping skills, unless someone offers to do PCB designs for the handset and controller boards. Thanks for your kind comments. -Mike

    mjbauer (author)2016-12-28

    ​Good idea! A similar project, but with touch pads and built-in sound synth can be found here: http://mjbauer.biz/Build_the_REMI_by_MJB.htm Kindly send me your comments - my email address is on the linked page.

    GiacomoL4 (author)2016-11-17

    Hi, I wonder to know if I can use a single arduino UNO for this project (not the nano). and how much extra buttons I can add (n max buttons?). Can I add potentiometers to control effects with these components? how much sensible is the mic? If u play in a very noisy space it sounds without blowing in? How about using in ableton live? ps. your work is awesome! :)

    NardJ (author)GiacomoL42016-11-17

    Hi, thx!

    For the buttons this build uses digital pins (D0..D13), which have the same amount on most nanos and unos. So D2, D12, D13 are still available for extra buttons. However don't use D0 and D1 since they are used by midi (TX and RX signal). For potentiometers you need analog pins (A0..A5). Only one (A0) is used by the microphone. On an uno you'll still have A1-A5 available (on the nano also A6 and A7). You can read the extra potentiometer within arduino code and send a corresponding midi command and value to your synthesizer software.

    I don't think the microphone is susceptible to background noise since it is inside the flute, but you will have to try. You can try putting foam between the mic and sides of the enclosure to dampen any further noise from the outside.

    If this still does not help, you can replace the mic with a pressure (barometric) sensor/breakout-board, but this is probably something for a more advanced build, in which case you'll also could/should replace the buttons with capacitive sensors and if you have a 3d printer you could print a nicer enclosure.

    Would like to see your finished build!

    cccparmy (author)2016-08-24

    Great job!very nice!

    АлексейС36 (author)2016-06-12

    Great job! Good clear description! Thank you!

    Fastjeep (author)2016-04-14

    Could you explane how I can make this flute with the original fingersetting for a flute insted for a piano?

    NardJ (author)Fastjeep2016-04-17

    You will have to edit line 237 to 300. Below some untested code to replace it:

    [code]
    //button at pin 11 is thumbbutton, first button at pin 3 is last hole of our flute and not present in a real recorder

    String buttons="000000000";
    for (int i=3;i<11;i++){
    if (digitalRead(i)==1) buttons.setCharAt(i-3,"1");
    }

    if buttons.equals("100000000") button=5 ;//F low
    if buttons.equals("101111111") button=7 ;//G low
    if buttons.equals("100111111") button=9 ;//A
    if buttons.equals("101101111") button=11; //B
    if buttons.equals("100001111") button=13;//C high
    if buttons.equals("100000111") button=15;//D
    if buttons.equals("100000011") button=17;//E
    if buttons.equals("100000101") button=18;//F
    if buttons.equals("100000100") button=20;//G high
    if (button!=lastbutton) {
    noteOff(12*Oct+lastButton);
    noteOn(12*Oct+button);
    }
    lastButton=button;

    [/code]

    MartyK1 (author)2016-04-12

    How hard would it be to configure this for standard MIDI output (5-pin DIN) for use with MIDI hardware synths? I don't feel the need to add a PC to my MIDI rig.

    NardJ (author)MartyK12016-04-12

    Simply connect TX, GND and 5V to a DIN-5 plug instead of the midi2usb converter. (more info: http://www.arduino.cc/en/Tutorial/Midi). Sometimes this circuit has some extra protection using an optocoupler (http://electronics.stackexchange.com/questions/172144/midi-to-arduino-with-a-4n38-optocoupler)

    Fastjeep (author)2016-03-26

    Super nice project!

    DIY Hacks and How Tos (author)2016-03-20

    Awesome recorder!

    About This Instructable

    3,652views

    20favorites

    License:

    More by NardJ:Simple Midi Flute/Recorder Controller (EWI)
    Add instructable to: