OK, so I checked my code. Here are my comments in the assembler code for receiving NRPN:
; NRPN MSB followed by NRPN LSB then data value. No other sequence or combination is permitted.
; And NRPN MSB and LSB must be transmitted for each and every data value (ie: there is no NRPN running status).
; reception of the NRPN MSB always resets the NRPN sequence.
I wrote the code this way because it appears to be the most common implementation and is 100% reliable. Whereas, other implementations (such as your controller) result in ambiguous situations where MIDI NRPN controllers can be screwed up.
See http://www.philrees.co.uk/nrpnq.htm
I am willing to hear from others as to whether this is proper practice or not.
Perhaps I could be convinced to add a global parameter to allow changing the NRPN behavior.
Mike
And here is the actual assembler:
; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
; the MIDI NRPN controller messages are handled below
; the NRPN MSB received must match the global NRPN MSB (global 16) for any parameter change to occur
; in order to avoid overruns and stop RPN's from interfering with NRPN's, the sequence of NRPN MUST be
; NRPN MSB followed by NRPN LSB then data value. No other sequencer combination is permitted.
; And NRPN MSB and LSB must be transmitted for each and every data value (ie: there is no NRPN running status).
; reception of the NRPN MSB always resets the NRPN sequence
; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
MIDI_NRPN_MSB:
mov a, d
sta M_NRPN_MSB ; save the NRPN MSB
mvi a, 2 ; set NRPN sequence to MSB received
sta M_NRPN_SEQUENCE
jmp MIDI_MODE_NO ; end by reset of control change status
; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
MIDI_NRPN_LSB:
lda M_NRPN_SEQUENCE ; get current NRPN sequence
cpi 2 ; test for MSB received
jnz MIDI_MODE_NO ; no MSB received so get out
dcr a ; set A=1 (LSB received)
sta M_NRPN_SEQUENCE ; save sequence flag
mov a, d ; put MIDI Data value into A
sta M_NRPN_LSB ; save the NRPN LSB
jmp MIDI_MODE_NO ; end by reset of control change status
; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
MIDI_NRPN_DAT:
lda M_NRPN_SEQUENCE ; get current NRPN sequence
cpi 1 ; test for MSB and LSB received
jnz MIDI_MODE_NO ; no MSB,LSB received so get out
dcr a ; set A=0 (reset sequence flag)
sta M_NRPN_SEQUENCE ; save sequence flag
mov a, d
sta M_NRPN_DATA ; save the data value
lda M_NRPN_MSB ; get the current NRPN MSB
mov b, a ; put the current NRPN MSB into B
lda C_NRPN_MSB ; get selected NRPN MSB (global 16)
cmp b ; compare selected NRPN MSB to current NRPN MSB
mvi a, 1 ; preload A = true
jz MIDI_NRPN_SKIP ; skip if selected MSB = current MSB
xra a ; did not match therefore set changed flag = false
MIDI_NRPN_SKIP:
sta M_NRPN_CHANGE ; save changed flag (will only change if NRPN MSB matches global)
jmp MIDI_MODE_NO ; end by reset of control change status
; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
From: Michael Hawkins <korgpolyex800@...>
To: "korgpolyex@yahoogroups.com" <korgpolyex@yahoogroups.com>
Sent: Thursday, August 1, 2013 10:31 AM
Subject: Re: [korgpolyex] Re: Maudio midi controller problems..
I'll have to check it out later today. But glancing at it, looks like it should work.
Although, it is more common to see NRPN and RPN's to be sent in groups of three for every message.
So it is a bit unusual to see the LSB and MSB to go out once and then a bunch of value messages by themselves.
However, I believe that the HAWK code supports that anyway. I'll have to check.
Mike
From: bimmerfan222 <bperkins211@...>
To: korgpolyex@yahoogroups.com
Sent: Thursday, August 1, 2013 7:29 AM
Subject: [korgpolyex] Re: Maudio midi controller problems..
I managed to fix the jittery output. The 8th pot was defective, causing the MC's analog input to float without a steady reference I guess.
Anyway, that one defective pot messed up the other 7 in that group. I guess the mod wheel was on some kind of isolated circuit? I dunno..
Just glad the new pot I put in fixed it!
Additionally, the old pot must have been impacted by the PO. Not only damaging the pot, but also the trace/pad for that pot's wiper lead. It was lifted from the PCB when I went in to desolder it!
The new pot's lead is barely making connection.. If it goes bad again, I may have to just remove the pot and ground the input to stabilize the rest.
I still have NRPN problems.
This is a link to the Oxygen's manual..
http://www.m-audio.com/images/global/manuals/051014_OxyLine_UG-EN01_V1.PDF
Here's a copy of what MIDIOX showed when I setup a knob to nrpn control "90", the VCF LFO1 Mod Depth. I have "GL 16 00" as my global setting.
024DEEAE 1 -- B0 62 5A 1 --- CC: NRPN LSB
024DEEAF 1 -- B0 63 00 1 --- CC: NRPN MSB
024DEEB0 1 -- B0 06 01 1 --- CC: Data Entry MSB
024DEEE0 1 -- B0 06 02 1 --- CC: Data Entry MSB
024DEF14 1 -- B0 06 04 1 --- CC: Data Entry MSB
024DEF74 1 -- B0 06 06 1 --- CC: Data Entry MSB
024DEFCB 1 -- B0 06 07 1 --- CC: Data Entry MSB
024DF045 1 -- B0 06 08 1 --- CC: Data Entry MSB
024DF078 1 -- B0 06 09 1 --- CC: Data Entry MSB
024DF0CA 1 -- B0 06 0A 1 --- CC: Data Entry MSB
024DF15D 1 -- B0 06 0B 1 --- CC: Data Entry MSB
024DF1C3 1 -- B0 06 0C 1 --- CC: Data Entry MSB
024DF256 1 -- B0 06 0D 1 --- CC: Data Entry MSB
024DF2CB 1 -- B0 06 0F 1 --- CC: Data Entry MSB
024DF3BB 1 -- B0 62 5A 1 --- CC: NRPN LSB
024DF3BC 1 -- B0 63 00 1 --- CC: NRPN MSB
024DF3BD 1 -- B0 06 10 1 --- CC: Data Entry MSB
024DF44E 1 -- B0 06 11 1 --- CC: Data Entry MSB
024DF529 1 -- B0 06 12 1 --- CC: Data Entry MSB
No response whatsoever from the HAWK with the above stream of msgs, post surgery.
Any ideas?
Thanks,
-Blaine
--- In korgpolyex@yahoogroups.com, Michael Hawkins <korgpolyex800@...> wrote:
>
> Check for a midi loop.
>
> Send the text of a batch of the CC messages you're seeing on MIDI-OX.
>
>
> Mike
>
>
>
> ________________________________
> From: bimmerfan222 <bperkins211@...>
> To: korgpolyex@yahoogroups.com
> Sent: Tuesday, July 30, 2013 8:55 AM
> Subject: [korgpolyex] Maudio midi controller problems..
>
>
>
> Â
> Ok, this one has me stumped.
>
> I have a Maudio Oxygen 8 V2 that I just picked up.
>
> For some odd reason, I cant get the 8 assignable knobs to send proper CC messages.
>
> Hooked up to the HAWK either direct or indirect thru the PC. I can see the messages in MIDIOX go thru fine. But the HAWK only partially responds to any of the knobs.. it's like it hears it for a moment, then suddenly does not hear it.
> If I turn the knob really slow, I can get more reaction from the HAWK, but it's still jittery.
>
> Odd thing is, the assignable Mod Wheel (next to the pitch wheel). Will send a CC flawlessly.. no jitters or problems whatsoever.
>
> So what would cause this? Again, I can see it sending all the messages in MIDI OX, but HAWK seems to only pick up part of the msg stream when using one of the 8 knobs.
>
> I do know that the very last knob has an issue where it wants to deviate to "33" when it is set to 0-127. I have disabled it, I suspect it has a cold joint or defective pot. The others dont act like that.
> Looking at the PCB, it appears each knob has it's own path to the main CPU (tiny stamp sized PIC thing).
>
> Any ideas? I was hoping to splice in a organ pedalset into the keyboard matrix later on.. but this knob issue has me scratching my head.
>
> -Blaine
>