Simple audio to midi device

Questions and discussion about building and using Max for Live devices
Post Reply
ze2be
Posts: 3455
Joined: Mon Apr 12, 2004 2:17 am
Location: Mos Eisley

Simple audio to midi device

Post by ze2be » Thu Feb 16, 2012 4:12 pm

Hi, Im looking for a simple audio to midi device!
To generate midi pulses from individual acoustic drums.
Perhaps a small vibration sensor that can be attatched
to the drum, generating some signal I can convert to midi.
I once used a game pad as a midi controller,
so it shouldnt be to hard finding a solution for it?
? ? ? ? ?

MFRedoom
Posts: 50
Joined: Wed Nov 04, 2009 4:28 pm

Re: Simple audio to midi device

Post by MFRedoom » Thu Feb 16, 2012 4:25 pm

http://www.mindthepressure.org/plugz.php

Crude but does the trick and it's FREEEEEEEEEEE!

JR

ze2be
Posts: 3455
Joined: Mon Apr 12, 2004 2:17 am
Location: Mos Eisley

Re: Simple audio to midi device

Post by ze2be » Thu Feb 16, 2012 5:24 pm

Cool! Did you build it? :)

Next step is geting some small and cheap mics.
Hmm, perhaps cheapo skype headset mics is worth a try.
? ? ? ? ?

trevox
Posts: 659
Joined: Wed Mar 23, 2011 12:58 am

Re: Simple audio to midi device

Post by trevox » Thu Feb 16, 2012 5:35 pm

There a max object called bonk~ that can be used for this. You set a threshold value and once a signal goes from below that threshold, to above it, it sends a bang. You can then tell that bang to do whatever you like. It struggles a bit for rolls and stuff like that where the audio never goes below the threshold though. The sensor idea is a good one as it should be more accurate and I've seen videos of people doing this to good effect. Google it and you should find it.

The only other thing is that you will need to create an audio M4L device and will not be able to send midi from it - well I don't think you can natively anyway. There are methods like sending out OSC data (using udpsend and udpreceive objects) which allow communication between M4L patches and even other applications on you machine. You can use normal send and receive objects, but personally I have found that to be quite erratic in their timing.

After a lot of pain and suffering, I eventually bought an electronic drum kit and it works great!!

trevox
Posts: 659
Joined: Wed Mar 23, 2011 12:58 am

Re: Simple audio to midi device

Post by trevox » Thu Feb 16, 2012 5:44 pm

MFRedoom wrote:http://www.mindthepressure.org/plugz.php

Crude but does the trick and it's FREEEEEEEEEEE!

JR
Is there a way to send audio into it in Live and get the midi out?

MFRedoom
Posts: 50
Joined: Wed Nov 04, 2009 4:28 pm

Re: Simple audio to midi device

Post by MFRedoom » Thu Feb 16, 2012 7:56 pm

Set whatever the Ext. in audio source is on an audio track with the plug on that same track.

Set midi in from that audio track ( should seethe plug name in the box directly below ).

Then adjust the sensitivity to taste.

I find that it helps to put a bird, I mean a scale device on it, the awesome midi quantize patch and / or midi tax.

This thing is nowhere near accurate but I like to record the results and chop.

Hope that helps.

JR

oddstep
Posts: 1732
Joined: Tue Feb 12, 2008 9:47 pm
Location: Plymouth the great

Re: Simple audio to midi device

Post by oddstep » Fri Feb 17, 2012 8:16 pm

@trevox. Do you reckon that udpsend is better than send for firing midi data around live. I'm making a bonk/fiddle hybrid device (!) using send, its slightly rascally but I thought was just down to the intrinsic difficulty of the task, plus Live's midi weirdness.

broc
Posts: 1151
Joined: Mon Jul 26, 2004 8:37 am

Re: Simple audio to midi device

Post by broc » Sat Feb 18, 2012 11:02 am

In my experience udpsend/udpreceive seems more reliable at high data rates (>50 messages per second).
But regarding latency there is no substantial difference to send/receive.

pid
Posts: 354
Joined: Thu Nov 05, 2009 9:51 am

Re: Simple audio to midi device

Post by pid » Sat Feb 18, 2012 12:27 pm

and with udp objects you have more control over data rate with the 'maxqueuesize' and 'maxpacketsize' messages, which i find myself using a lot more in m4l than in max.
3dot... wrote: in short.. we live in disappointing times..

Valiumdupeuple
Posts: 1051
Joined: Mon May 31, 2010 12:36 pm
Contact:

Re: Simple audio to midi device

Post by Valiumdupeuple » Sun Feb 19, 2012 2:18 pm

Hey guys, it's simpler than that.
I've made a device which does exactly what you want. I use piezo mics sitcked on the kickdrum and the snare. Those signals then go to a pair of audio inputs on my soundcard, then to one audio track (with stereo input like 1/2 or 3/4 whatever your signal goes into the soundcard). On this audio track my M4L device uses bonk, and the trick is to implement the sampler into the device... no need to send midi through different tracks.
So the device has bonk and two samplers inside (one for the kick, one for the snare). I don't have it on this laptop but it's pretty easy to do, and I'll post it if you want.

ze2be
Posts: 3455
Joined: Mon Apr 12, 2004 2:17 am
Location: Mos Eisley

Re: Simple audio to midi device

Post by ze2be » Mon Feb 20, 2012 9:42 pm

? ? ? ? ?

trevox
Posts: 659
Joined: Wed Mar 23, 2011 12:58 am

Re: Simple audio to midi device

Post by trevox » Tue Feb 21, 2012 10:12 pm

broc wrote:In my experience udpsend/udpreceive seems more reliable at high data rates (>50 messages per second).
But regarding latency there is no substantial difference to send/receive.
Ah, we've had this conversation before :)

Yeah, I'd agree with this. I did some tests and when not triggering notes quickly, normal send/receive was okay, but I have an electronic drumkit and wanted to play snare rolls etc and send/receive fell on it's arse as the delay in sending the signal seemed to vary, with bad resuts. There may be a similar latency with udpsend/udpreceive, but any delay is consistent so you get smooth rolls.

trevox
Posts: 659
Joined: Wed Mar 23, 2011 12:58 am

Re: Simple audio to midi device

Post by trevox » Tue Feb 21, 2012 10:19 pm

Valiumdupeuple wrote:Hey guys, it's simpler than that.
I've made a device which does exactly what you want. I use piezo mics sitcked on the kickdrum and the snare. Those signals then go to a pair of audio inputs on my soundcard, then to one audio track (with stereo input like 1/2 or 3/4 whatever your signal goes into the soundcard). On this audio track my M4L device uses bonk, and the trick is to implement the sampler into the device... no need to send midi through different tracks.
So the device has bonk and two samplers inside (one for the kick, one for the snare). I don't have it on this laptop but it's pretty easy to do, and I'll post it if you want.
This wouldn't work where you are not using samples though. For instance, I use my kit is to play several different synths. Also, you may want more than 2 drums, so number of inputs/mics you need could be an issue. Not saying your solution would not work, just not sure if it meets what the OP wants to do!

broc
Posts: 1151
Joined: Mon Jul 26, 2004 8:37 am

Re: Simple audio to midi device

Post by broc » Wed Feb 22, 2012 12:20 am

trevox wrote:
Valiumdupeuple wrote:Hey guys, it's simpler than that.
I've made a device which does exactly what you want. I use piezo mics sitcked on the kickdrum and the snare. Those signals then go to a pair of audio inputs on my soundcard, then to one audio track (with stereo input like 1/2 or 3/4 whatever your signal goes into the soundcard). On this audio track my M4L device uses bonk, and the trick is to implement the sampler into the device... no need to send midi through different tracks.
So the device has bonk and two samplers inside (one for the kick, one for the snare). I don't have it on this laptop but it's pretty easy to do, and I'll post it if you want.
This wouldn't work where you are not using samples though. For instance, I use my kit is to play several different synths..
Note that you can use the [vst~] object to integrate any softsynth/sampler into the device.

trevox
Posts: 659
Joined: Wed Mar 23, 2011 12:58 am

Re: Simple audio to midi device

Post by trevox » Wed Feb 22, 2012 5:29 am

broc wrote:
trevox wrote:
Valiumdupeuple wrote:Hey guys, it's simpler than that.
I've made a device which does exactly what you want. I use piezo mics sitcked on the kickdrum and the snare. Those signals then go to a pair of audio inputs on my soundcard, then to one audio track (with stereo input like 1/2 or 3/4 whatever your signal goes into the soundcard). On this audio track my M4L device uses bonk, and the trick is to implement the sampler into the device... no need to send midi through different tracks.
So the device has bonk and two samplers inside (one for the kick, one for the snare). I don't have it on this laptop but it's pretty easy to do, and I'll post it if you want.
This wouldn't work where you are not using samples though. For instance, I use my kit is to play several different synths..
Note that you can use the [vst~] object to integrate any softsynth/sampler into the device.
True, though having a load of vst~'s embedded in a M4L patch wouldn't be my cup of tea. Personally, I use mostly hardware and want things less complicated when I go to write some music, albeit with probably more programming involved to get there as I want to spit the separate drums out to separate midi channels after some treatment. One this is done once, it does not have to be programmed again. Then again, the OP may not have this type of need, but I find it very flexible either way.

Post Reply