I am working on a concept for a master keyboard router.
The master keyboard should be routed to predefined midi outs (1-4).
Each target can be transposed indiviually by an adjusted value. (octave up/down ; sem up down , Setting shown in the corresponding display)
Each target can be enabled / disabled individually. (ONOFF button )
Unfortunately i cannot find any transpose function for the router targets within the scripting documentation. Or do i have to alter the source for this functionality ?
Could somebody give me a hint where to search for any transpose settings?(I only found it for CV values.)
If i understood right kb_transpose is for a directly to a Midibox connected keyboard. I want to use a alreay miditized-keyboard with the router functionality of Midibox.
I think i will hack the midi_router.c MIDI_ROUTER_Receive(mios32_midi_port_t port, mios32_midi_package_t midi_package) to my needs or hook me into APP_NotifyReceivedEvent.
Lets see how this works. Unfortunately i don’t see any way to implement my idea into TKs nice scripting framework.
So will be more a bad hack than something i can give back to the community.
I started to change the source code towards my needs and thanks to the nicely written software structure the progress better than i thought.
If you want to know what i am doing have a look to my first request.This is a short explanation and a reminder for myself.
So far I added 4 new MetaEvents :
_ Event commands _:
1 RouterTranspose = > Sets the transposition to an absolute value (offset is -64 ) means a value of 64 is no transpose 2 RouterIncTranspose => increases the transpose value 3 RouterDecTranspose => decreases the transpose value 4 RouterSetDstChn => set the dst channel of a router node
usage :
type=Meta meta=E_CMD:x
Where x is the node number and E_CMD is the Event commands
Button 4 increases the midi notes of node1 target port by 1 Octave (12 Semitones)
Button 3 decreases the midi notes of node2 target port by 1/2 Octave (6 Semitones)
ENCODER: 1 Sets nodes 0-2 to the same transpose value (stored within the encoder)
Button 5 activates/deactivates the router node. (Channel 0 = off ; channel 17 = all Channels are forwarded)
The Problem :
If you hold a key and change the transpose or channel setting, the release event(NoteOff/Velocity=0) will end up on the wrong note/channel. (the tone hangs) Solution :
I had to remember every NoteOnEvent and alter the forwarded package of each NoteOff to the corresponding note number (instead of the actual settings)
It is working very well and i hadn’t any issues so far.
At the moment max 64 notes per node can be memorized (adjustable by define)
The costs are very high: RAM consumption 3bytes * 16nodes * 64 events > 3072 Bytes of Ram usage