Jump to content

HawThorn

Members
  • Posts

    24
  • Joined

  • Last visited

    Never

Everything posted by HawThorn

  1. Can I use a think like this? It’s not really beautiful, but... void MIOS_MIDI_Init(void) __wparam { if (evnt2 == 0x00) { // send the MIDI event F0 7F 01 02 01 31 00 MIOS_MIDI_BeginStream(); MIOS_MIDI_TxBufferPut(0xF0); MIOS_MIDI_TxBufferPut(0x7F); MIOS_MIDI_TxBufferPut(0x01); MIOS_MIDI_TxBufferPut(0x02); MIOS_MIDI_TxBufferPut(0x01); MIOS_MIDI_TxBufferPut(0x31); MIOS_MIDI_TxBufferPut(0x00); MIOS_MIDI_EndStream(); } //etc, etc, etc... for each my 128 values if (evnt1 == 0x00) { // send the MIDI event 00 31 F7 MIOS_MIDI_BeginStream(); MIOS_MIDI_TxBufferPut(0x00); MIOS_MIDI_TxBufferPut(0x31); MIOS_MIDI_TxBufferPut(0xF7); MIOS_MIDI_EndStream(); } //etc, etc, etc... for each my 128 values } on my network I can received only CC, so it’s not important for my to do a detection of event
  2. Yes, a little bit more explanation: The sysex look like: F0 7F 01 02 01 01 YY 00 XX 00 F7 So the first part of the sysex is like that: F0 7F 01 02 01 01 (3Z 3Z ) 3Z 00 And the second part of the sysex like that: (3Z 3Z) 3Z 00 F7 For YY (the second value of the control): it’s the value scale to 1-101, translate in ascii code, and put in the sysex. Some examples: 0 ---> 1 ---> 31 19 ---> 15 ---> 31 35 60 ---> 48 ---> 34 38 107 ---> 85 ---> 38 35 127 ---> 101 ---> 31 30 31 For the XX (the first value of the CC): it’s just the value translated in an ascii code and increase by 1 Some examples for XX: 0 ---> 1 ---> 31 15 ---> 16 ---> 31 36 49 ---> 50 ---> 35 30 87 ---> 88 ---> 88 88 103 ---> 104 ---> 31 30 34 127 ---> 128 ---> 31 32 38 So for exemple if the value CC 13 120 is coming in, the value sysex F0 7F 01 02 01 01 39 35 00 31 34 F7 Or for the value CC 109 35, the value sysex F0 7F 01 02 01 01 32 38 00 31 31 30 00 F7 Other for the value CC 16 49, the value sysex F0 7F 01 02 01 01 33 39 00 31 37 00 F7 For the variable Y in the first part of the sysex, I can have an error of 2%. Well, actually, I use MIDI-OX to translate my CC and to be sure I have 256 entries. 128 for the first part of the sysex and 128 for the second part. Exemple : *,Ctrl,*,*,0,0,Y,0,*,SysEx,F0 7F 01 02 01 01 31 *,Ctrl,*,*,28,28,Y,0,*,SysEx,F0 7F 01 02 01 01 32 32 *,Ctrl,*,*,112,112,Y,0,*,SysEx,F0 7F 01 02 01 01 38 39 *,Ctrl,4,4,*,*,N,0,*,SysEx,00 35 00 F7 *,Ctrl,34,34,*,*,N,0,*,SysEx,00 33 35 00 F7 *,Ctrl,114,114,*,*,N,0,*,SysEx,00 31 31 35 00 F7 Well, I think, I must program it like this: If you receive the second value 00 from a CC then send 7F 01 02 01 01 31 … if than you receive the second value 75 from a CC then send 7F 01 02 01 01 36 30 … etc If you receive the first value 00 form a CC then send 31 00 F7 … if than you receive the first value 101 form a CC then send 31 30 32 00 F7 … etc And perhaps clone the CC when it coming in… I hope I’m not too unmethodical in my explanations, if you can help me…
  3. Hello, Before working with the mios, I want to be sure that it can do what I want. So, is it possible to program a large translation map? I receive a CC, depend with the second value, I send a half sysex message. And with the first value, I send the other part of my sysex message. Is it possible? Thanks Laurent
×
×
  • Create New...