Encoder simulation with 2 keystrokes

Vitja

2013-12-01 19:50:55

I would like to make a encoder simulation with just two keystrokes. One for increase and one for decrease of one CC.
Can I do this with timers and by holding this two keys? Can someone who knows how to do this post a code of an example?
This would be really awesome since I use one keyboard just for MIDI.

DvlsAdvct

2013-12-02 02:08:04

Hi again Vitja

Yes, you can do this using Keystrokes.

Just use the Keystroke action with an outgoing MIDI action to replicate a relative command (usually something like B0 30 3F or 7F) and it will automatically repeat until you release the key. There can be a delay which can be changed in your keyboard settings. If you want to use Timers, though, it would need to look like:

Code: Select all

Translator 1: Key Press
Incoming Message: Key Down Event P
Outgoing Message: Left Timer 0ms Delay Infinitely 0ms Delay

Translator 2: Knob Left
Incoming Message: Left Timer
Outgoing Message: B0 01 7F

Translator 3: Key Release
Incoming Message: Key Up Event P
Outgoing Message: Kill Left Timer
Make sense?

Vitja

2013-12-02 13:36:31

Huh, now that's what I call simplicity!
When I read your code, I thought that I wasn't clear enough!
I was sure that it has to do something with rules and variables.
If I'm honest, I still don't know why this actually works????
Because, if you program 7F for cc, I expected it to jump on that value rather than scaling to that value.
I had some problem to simulate the opposite direction because I entered 00 instead of 01 for minimum value.
So if it's 00, that means OFF immediately?

Thanks for this tip!
Now I have bunch of "faders" for free!!! :D

DvlsAdvct

2013-12-02 16:39:32

This is where the simplicity of MIDI really comes into it. Since your virtual fader is listening for only up and down messages it just simply works. :)

Let us know if you have any other questions.
Jared

Vitja

2013-12-02 20:52:32

OK, I will as this right here, to avoid new discussion.
Is it possible to filter of the Note On end OFF from MIDI signal.
I would like to trigger my synth with Gate In and us MIDI for sequencing it, but I have to filter note ON/OFF commands, so synth just tracks pitch and doesn't open the gate.
Is this even possible?

DvlsAdvct

2013-12-02 23:12:45

It definitely is, it just depends on what midi command you are using. Is it a button press with after touch?

Vitja

2013-12-03 00:38:47

I'm using Ableton Live for this, so no aftertuch. Just plain notes.
I find this hexa thing confusing. Is there a value, that isn't sending note on/off position. Something like legato???

DvlsAdvct

2013-12-03 00:51:00

No no I meant your midi controller. You can fake out ableton so it gets whatever you want. It is really frustrating since ableton is really picky about what it listens for.

Vitja

2013-12-19 19:24:02

Uh I forgot that I asked you about this... sorry for delay!

I will try to explain this as clear as possible.

In Live, I have a MIDI track, that I want to use it to play my Moog Slim Phatty, like a MIDI sequence. But I want to avoid the MIDI note on/off command that Live is sending from this MIDI clip. Usually all MIDI clips/ notes in Live are sending standard MIDI note on/off, duration and velocity. Note on/off are usually note on, pitch info, duration, note off. I would like to send just pitch info and duration. This "duration" is actually dependent on note on and off, so forget about it.
In other words, I would like to get something like pitch information or bitch bend info with normal notes that have filtered note on/off info.

I would like to route this MIDI track out from Live to MT, than filter out the note on/off messages in MT and send it to Moog. With this I would avoid triggering the envelopes on Moog, but still play the pitch of the oscillators.

Why I want to do that?
I want that moog's pitch is automatically played by Live, but envelopes of VCA and VCF are played manually by trigger on drummer's bass drum. This trigger is analog control over note on/off, that I want to filter it out from Live.

With this concept, the drummer would play the rhythm of the synth, but the pitch would be played by Live.

This works with pitch bend cc, but this info has limited range and is really hard to find the right pitch bend that is in tune. This works, because bitch bend has no note on/off commands.

Hope that this was clear enough :wink:

DvlsAdvct

2013-12-19 21:14:50

Hi Vitja

What you are looking to do definitely makes sense. There are a few ways to handle this kind of process. If you want, you can run the bass drum's trigger into MIDI Translator as well, and run both the Ableton signal and the trigger into the synth, but that isn't necessary.

One option is to create a pass through in the MIDI router to send everything from Ableton straight to the Moog, and create a simple translator that prevents the note messages from sending. This might be easiest since you don't need to create any translators for what messages you want sent to the Moog, but you need to make sure the Moog is listening for the correct signals. The translator you need to create simply needs to look like:

Code: Select all

Translator 1: Filter Note Msgs
Incoming Message: 90 pp qq
Rules: None
Outgoing Message: None
If you have note messages sending on multiple channels, however, then you will want it to look like:

Code: Select all

Translator 1: Filter Note Msgs
Incoming Message: pp qq rr
Rules: if pp<144 then exit rules, skip outgoing action
if pp>159 then exit rules, skip outgoing action
Outgoing Message: None
This will only filter out note messages across all channels.

In conjunction with the pass through in the MIDI router, this will easily allow you to cut off the note messages while still passing everything else to the Moog.

This only works, however, if you do not need to translate the pitch bend messages for the Moog to respond. If you do then just create a translator for the pitch bend message so it sends correctly and that same Note translator to filter out the note messages.

That make sense?

Vitja

2013-12-29 15:09:57

Hmmm... I really don't get this.
What confuses me is how to link the router and the translator.
I tried it but nothing seems to happen.

Anyway, I will probably do this trick with Arturia Mini Brute, which has a really nice trigger input for this kind of application.

Thanx anyway!

I really appreciate your help on everything that comes to mind!

DvlsAdvct

2013-12-30 19:09:10

Hi Vitja

Sorry we couldn't get this figured out.

Just to be clear, in regards to routing in MIDI Translator, using the Router and the translators are two separate, yet linked pieces.

The router allows you to pass all MIDI data through from one device to another directly. The only translation that will occur is controlled by individual translators you create. So, for example, you have an Oxygen8 keyboard and Ableton. You want the Oxygen8 to work as per usual, except you want middle C to never send. You COULD create an individual translator for every note, which is massively time consuming, or you could create a translator that excludes middle C via rules, but you would also need translators to control the knobs and wheel modules, and that takes time.

Your best bet is to create a passthrough in the router, connecting the MIDI In of the Oxygen8 and a virtual port connected to Ableton so everything passes directly through, and then create a single translator that filters out middle C. This allows everything to go through untranslated, exactly as it is on the keyboard, except that one note.

Does that make more sense?

Thanks
Jared