busker99 Posted June 5, 2008 Report Share Posted June 5, 2008 Have just finished an integrated core and 64 note d-out board for my midi pipe organ. All works fine on my PalmVx, midi keyboard, Casio FDD player, cakewalk etc. However, I tried it on the SD Card midi player. If the pause is pressed, it stops playing but does not turn off the notes that are playing. I have tested all the equipment on MidiOx. This shows that all the players send an individual note off when paused, and then a block of control codes. With the SD player, it just sends the block of control codes. This works fine on a commercial J.Wale midi out card. Can the midio 128 be coded to accomodate this? Quote Link to comment Share on other sites More sharing options...
TK. Posted June 5, 2008 Report Share Posted June 5, 2008 Does the player send an "All Notes Off" CC? (CC#123) - MIDIO128 could be enhanced to parse this CC and to turn off all outputs once receivedBest Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
busker99 Posted June 9, 2008 Author Report Share Posted June 9, 2008 Many Thanks for you rapid reply Thorsten. Yes, on "pause" or "stop" the SD player sends a CC7B (#123-All notes off) for each channel, followed by a 78 (#120-All sound off) for each channel. Can midio128 be modified to respond to this? Quote Link to comment Share on other sites More sharing options...
DavidBanner Posted June 10, 2008 Report Share Posted June 10, 2008 like TK said, you can parse the midi input and look for the all-notes off CC7B.Using an IF statement you can then turn off all of the outputs individually within the IF statement.for example: in the ain64_din128_dout128_v2_0 application you would put the IF statement in the MPROC_NotifyReceivedEvnt function.This IF statement is contained in the main.c file. Quote Link to comment Share on other sites More sharing options...
busker99 Posted June 10, 2008 Author Report Share Posted June 10, 2008 Thank you for your reply David. However, I have no knowledge of the programming necessary and can only approach the problem from a "common sense" Point of view. I am using MIDIO128_v2_1d. Could you please show the necessary code and indicate where it should be included in the MIDIO128 main.asm. I can then create the new hex file in MPlab. Quote Link to comment Share on other sites More sharing options...
DavidBanner Posted June 10, 2008 Report Share Posted June 10, 2008 MIDIO128 main.asm <-- this is an assembly filethe suggested route I mentioned is using C because you posted this thread in the C programming area.when it comes to asm I am not you man.... Quote Link to comment Share on other sites More sharing options...
busker99 Posted June 10, 2008 Author Report Share Posted June 10, 2008 Thanks for your time anyway. I'll repost it in the asm section. Quote Link to comment Share on other sites More sharing options...
TK. Posted June 10, 2008 Report Share Posted June 10, 2008 I moved it to the assembler section.If there isn't another volunteer, I will do the changes in MIDIO128. It shouldn't be so difficult, just need some time for testing (e.g., the inversion flags have to be taken into account)Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
Orgautomatix Posted June 15, 2008 Report Share Posted June 15, 2008 Hello everybody !I'm also interested in such a modification... I'm using 2 Midio 128 (and 3 more soon) with Palm as midifiles reader, and I'm considering to use soon a SD midifiles reader, so...Have a good Sunday !Chris Quote Link to comment Share on other sites More sharing options...
TK. Posted June 27, 2008 Report Share Posted June 27, 2008 The "All Notes Off" function is available now in version v2.2:http://www.ucapps.de/midio128_changelog.htmlNote that it's disabled by default to ensure compatibility - please let me know if you're having issues with the configurationBest Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
Orgautomatix Posted June 30, 2008 Report Share Posted June 30, 2008 Hello TKThank you very much for spending time. I'd just tried. I uploaded the new setup midio 128 with Mios Studio, turned the "all note off " command on channel 1 in the Midio 128.ini, transformed it in sysex file with Perl, and uploaded to the core with Midiox. I made a little midi sequence in Cubase with long notes on channel 1 and inserted a CC123 before the end of notes. All is working but the CC123 seems to be ignored, the test leds turn off only at the end of the notes. Perhaps I did something wrong ?Bonne soirée à tout le monde !Christian Quote Link to comment Share on other sites More sharing options...
TK. Posted June 30, 2008 Report Share Posted June 30, 2008 Hi Christan,it would be interesting, which CC value is sent. CC#123 0 should be ignored, values > 0 should turn off the LEDs. Can you confirm this?In order to doublecheck, if the configuration of the channel setting was successful: use the debug window if MIOS studio to read out address "0x8c" - it should contain 0x01You can also write to this address. 0x00 will disable the feature, 0x01 will set it to channel 1, 0x02 to channel 2, etc...Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
Orgautomatix Posted July 1, 2008 Report Share Posted July 1, 2008 Hi Thorsten !Many thanks for fast reply ! Yes I'd already tried with different values of CC123.I've change values in the PIC, as you indicated, with debug interface of Mios Studio, it's now working fine ! But, after turning off / turning on the board, CC123 is ignored, the adress 0x8C has come back at 0x00 !How can I get it allways in memory ?Sorry for so naîve questions, I'm beginner in electrinics and programming, but I learn, I learn ! ! !Have a good dayChris Quote Link to comment Share on other sites More sharing options...
Orgautomatix Posted July 1, 2008 Report Share Posted July 1, 2008 HI again Thorsten !After looking everywhere, I found my error. Just forgot to change the midio128.pl file in the Perl directory, so the CC123 change was not stored in the sysex files. I can say now all is working fine ! :D Even after a reset, a CC123 turns off all the notes on.Thank you very much for help. Now, for security, I'm going to put a CC123 at the end of all my midi sequences. Just a little problem (or perhaps not), one of my 3 Midio 128 boards is runing under 2 MIDI channels. Is it possible to get the all note off for 2 different midi channels ?RegardsChris Quote Link to comment Share on other sites More sharing options...
busker99 Posted July 4, 2008 Author Report Share Posted July 4, 2008 I must thank you for your time and effort T.K. I have managed (eventually !!) to master the minefield of compiling the new hex file, with all the necessary utilities, I then applied the new sysex patch, created from the MK_Midio128.ini file, and the core will now respond to #CC123 to turn the notes off. But...... It will only turn off the notes for the one channel it is set for, and it seems that the #CC123 must be given a value of > 0. Is this the case ?RegardsBusker99 Quote Link to comment Share on other sites More sharing options...
Orgautomatix Posted July 4, 2008 Report Share Posted July 4, 2008 Hello IanFor CC123 just have a look to the last reply from TK : CC#123 0 should be ignored, values > 0 should turn off the LEDs.Regards Chris Quote Link to comment Share on other sites More sharing options...
busker99 Posted July 4, 2008 Author Report Share Posted July 4, 2008 Hello Chris,Yes I had noted T.K's reply. According to most of the geeks and pundits on the web, it seems that the midi standard is not rigid and many manufacturers interpret the control codes to suit their own convenience. However, the SD player sends it's control codes with a zero value, according to the cakewalk "logging" I received from John Smith. I will get him to confirm this. It would seem that the answer is for the SD player software to send individual "note-off" commands for all the notes playing, before it pauses, just like all the other equipment I have tried. The other (Commercial) midi card, by Omega Electronics, does respond to these commands.So, we still have the problem it seems.RegardsIan - Busker99 Quote Link to comment Share on other sites More sharing options...
Orgautomatix Posted July 4, 2008 Report Share Posted July 4, 2008 Hello IanYou'r right, I've Just reed on my big MIDI book that recommandation for sequencer (harware or software) is, before to stop, sending 127 note-off messages on each channel and then, one all note-off message (CC123). If so, the midio 128 must stop the note-on, does it? RegardsChris Quote Link to comment Share on other sites More sharing options...
TK. Posted July 4, 2008 Report Share Posted July 4, 2008 YesIf you prefer an "Omni" mode (this is also the answer to Chris' request), the source code has to be (slightly) modified - are you able to recompile the source code? Then I could simply tell you the changes. Otherwise I've to create a new releaseAnd yes, value 0 has no effect. The MIDI spec doesn't make clear, if this is desired or not. Here again: a simple code change (removing the condition) will helpDoes your sequencer send CC#123 with value 0? Then I will disable the check in the next release.Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
busker99 Posted July 4, 2008 Author Report Share Posted July 4, 2008 Hello T.K.Yes, If you can modify and produce a new asm file, I can recompile the hex.Ideally, It needs to turn off all notes on all channels on receipt of a #cc123, with a value of 0. Would be great if it could also responded to a #cc120, of value 0. Thank you, once again, for sharing your time and expertise with us all.Regards Busker99 - Ian Quote Link to comment Share on other sites More sharing options...
TK. Posted July 4, 2008 Report Share Posted July 4, 2008 Ok :)Open midio_midi.inc, search for following section: ;; if All Notes Off CC active: check it here SET_BSR MIDIO_BASE movf MIDIO_ALL_NOTES_OFF_CHANNEL, W, BANKED bz MIDIO_MIDI_NotifyReceivedEventNC ; ignore if channel value == 0 addlw -1 ; MIDI channel = channel value - 1 andlw 0x0f iorlw 0xb0 ; check for CC | <channel> xorwf MIDIO_LAST_RECEIVED_EVNT0, W, BANKED bnz MIDIO_MIDI_NotifyReceivedEventNC movf MIDIO_LAST_RECEIVED_EVNT1, W, BANKED ; check for CC#123 xorlw 123 bnz MIDIO_MIDI_NotifyReceivedEventNC movf MIDIO_LAST_RECEIVED_EVNT2, W, BANKED ; check for value > 0 bz MIDIO_MIDI_NotifyReceivedEventNCMIDIO_MIDI_NotifyReceivedEventNO goto MIDIO_DOUT_ClearAll ; set all DOUTs to passive stateMIDIO_MIDI_NotifyReceivedEventNC[/code] and replace it by: [code] ;; if All Notes Off CC active: check it here SET_BSR MIDIO_BASE movf MIDIO_ALL_NOTES_OFF_CHANNEL, W, BANKED bz MIDIO_MIDI_NotifyReceivedEventNC ; ignore if channel value == 0 ;; react on any channel (omni mode) movf MIDIO_LAST_RECEIVED_EVNT0, W, BANKED ; check for CC andlw 0xf0 xorlw 0xb0 bnz MIDIO_MIDI_NotifyReceivedEventNC movf MIDIO_LAST_RECEIVED_EVNT1, W, BANKED ; check for CC#123 xorlw 123 bnz MIDIO_MIDI_NotifyReceivedEventNCMIDIO_MIDI_NotifyReceivedEventNO goto MIDIO_DOUT_ClearAll ; set all DOUTs to passive stateMIDIO_MIDI_NotifyReceivedEventNCI think, that it isn't required to parse for CC#120 in addition - one CC is enough to deactivate all DOUTsBest Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
Orgautomatix Posted July 5, 2008 Report Share Posted July 5, 2008 Hello Thorsten !Many thanks for work, all is fine now. :DFor test I've set my midio on 8 different channels; I can say now that a CC123 of any value stops all notes on all channels. Not tested on 16 channels though but it must work as well :)I'm now considering I must learn programming Pic. Everywhere it's told it's very easy, only 35 instructions to learn.... But, when reading Midio128 programm, doesn't seem so easy ??? If at least I could be abble to change litle things by myself...Thank you once moreBest regardsChrisChris Quote Link to comment Share on other sites More sharing options...
busker99 Posted July 12, 2008 Author Report Share Posted July 12, 2008 Hello T.K.Thank you for all the help you have given with the note off problem. It now works fine, turning everything off on receipt of #CC123. My first thoughts on using the new GPUtils was utter confusion, but after some rational thought, it now seems to be doing what I want. It seems, from looking at some of the other Perle scripts, that it might be possible to convert syx files back to asm. This would be useful for checking the scale and options when there are problems. Could anybody offer some guidance on how to achieve this ? I tried to follow the same proceedure as for making the syx file, with 'Make' but all I got was.......................Regards - Busker99Ian Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.