Highly Liquid Forum facebook twitter google plus rss feed

Go Back   Highly Liquid Forum > Current Products > MIDI CPU

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 05-25-2010, 11:44 PM
John's Avatar
John John is offline
Moderator
 
Join Date: Jan 2009
Posts: 3,007
Default Configuration SysEx Howto

The MIDI CPU is configured via MIDI SysEx message. If you're unable to write your own SysEx, please start a forum thread and I'll help you write it. The procedure is very simple, once you give it a try.

Tools you need to send the SysEx file:
  • A computer with a MIDI interface that supports SysEx
  • Free-to-download software for sending SysEx to the MIDI CPU.

Test your interface:

Most computer MIDI interfaces can send and receive SysEx messages, but some can't. To test your interface:

Using a MIDI cable, connect your computer's MIDI Out to your computer's MIDI In. Launch SendSX and make sure that the correct MIDI interfaces are selected in the Midi In and Midi Out menus.

Enter a sysex message in the MIDI Out pane, like this:

F0 00 01 02 03 04 05 F7

Send the message. The identical code should appear in the MIDI In pane.

If the sysex message above is not echoed back, then try a simple MIDI note-on message:

90 00 01

If you send the note message from the MIDI Out pane, but it does not come back via the MIDI In pane, you might have the wrong MIDI interfaces selected.

A SysEx message looks like:

On the forums, I put SysEx in a little code window, like this:
Code:
// Just a comment!
F0 00 01 5D 04 01
// another comment!
00
00 00 4C 00 50 7F
F7
Any line beginning with "//" is just a comment, and not a functional part of the code.

The important parts are the sysex bytes. Each byte ("00" or "F0" or "4F", etc.) is shown as a hexadecimal or "hex" (machine-speak) number. Humans use decimal numbers.

We might talk about "MIDI Note #60". "60" in this case is a decimal number. If we wanted to specify that note in the sysex, we must first convert it to hexadecimal. You can see a list of MIDI note numbers in both decimal and hex format here:

http://forum.highlyliquid.com/showthread.php?t=1125

You can also type "60 in hex" into Google, and you'll get: "60 = 0x3C". Just remove the "0x" part to get the byte for the SysEx.

The same conversion works for CC #s, slider positions, note velocity, and every other data byte in MIDI.

How to send the code using SendSX:

Select the text from the code window, copy it, and then paste it into the "Midi Out" pane of the SendSX window. SendSX knows to ignore the "//" comments, so you can leave that stuff in there.

Note: Because of problems using multiple lines of code inside SendSX, it is recommended that you convert your code to a binary .syx file. The .syx can be opened directly with SendSX using the File->Open command. Here is the link to the text-to-syx converter:

http://support.codeandcopper.com/txt-to-syx/


Then, make sure the correct MIDI port is selected in the "Midi Out" menu, and click the "Send" button. That's it!

It is wise to save your sysex as a text file, so that you can easily make adjustments, if necessary. You can also tweak your hex code inside the SendSX application.

Note: If SendSX reports an "undefined external error", try converting your hex code using the text-to-sysex converter first, then opening the .syx file with SendSX using the File->Open command.

How to send the code using SysEx Librarian:

SysEx Librarian uses binary-format (raw hex) sysex files with the extension ".syx". To generate a .syx file, go here:

http://support.codeandcopper.com/txt-to-syx/

Copy your code into the window and click "convert". A file download will begin. Save the file with a ".syx" extension, load it into SysEx Librarian, send it to the MIDI CPU, and you're done.

Last edited by John; 01-19-2015 at 06:24 PM.
Reply With Quote
  #2  
Old 07-07-2010, 08:30 PM
Jim McDougall Jim McDougall is offline
Moderator
 
Join Date: Aug 2009
Posts: 395
Default Sending your sysex configuration

Midi CPU can only process 1 Sysex configuration message at a time. A configuration message is a segement that starts with F0 and ends with F7. Your typical configuration file will have 2 or more of these messages. From your configuration file copy the first message into SendSx or equivalent and send it. You will see the led on the board it self light up and then go out. The Midi CPU resets when the light goes out. Now send the second message block.Again the on-board LED will light for a few seconds and the go out. Repeat this process until all the message blocks in your configuration definition have been sent. If after sending a block, the LED does not light up, it is an indication that there is an error in that particular block of configuration as the CPU did not accept it for processing. Check that block for errors. Once corrected, then re-send and continue on. Once all the message blocks have been accepted you are good to go and its time to check that what you configured is how you wanted it to work. Good Luck !
Reply With Quote
  #3  
Old 12-31-2010, 05:12 PM
stefanuk stefanuk is offline
Member
 
Join Date: Nov 2010
Posts: 35
Default

The Sqwerl does not start it says

An exception of class NilObjectException was not handled. The application must shut down
Reply With Quote
  #4  
Old 01-08-2011, 02:38 AM
wabbitguy wabbitguy is offline
Member
 
Join Date: Aug 2010
Posts: 53
Default

Quote:
Originally Posted by stefanuk View Post
The Sqwerl does not start it says

An exception of class NilObjectException was not handled. The application must shut down
NilObjects are usually the result when you try to click buttons in the interface without setting up Sqwerl first. It also helps to let me know what MIDI interface you are using, along with the OS and platform.

Standard procedure is:

1. Select your MIDI interface in the popup menu items for the IN and OUT
2. Connect the two MIDI cables from your interface to the MSA
3. Click the SCAN button to allow Sqwerl to find your MSA.

If Sqwerl doesn't find your MSA, check the cables, check the IN and OUT (you might have them reversed; or you're using Thru not IN and OUT), the MIDI drivers for your interface are out of date, or your MIDI interface doesn't support SYSEX.

Mel
Reply With Quote
  #5  
Old 03-04-2012, 10:37 AM
slateboy slateboy is offline
Junior Member
 
Join Date: Feb 2012
Posts: 15
Default

Forgive me for being dumb, i am on my first few attempts at programming my CPU

Is it possible to configure one terminal at a time, ie, dump sysex:
F0 00 01 5D 04 01
00
00 00 44 00 01 00
00 01 44 00 01 7F
F7

OR
will the device only accept a complete layer dump, about 296 bytes worth?

and, does the activity indicator illumination time vary on message type or message length, ie with a successful sysex dump the LED appears to stay on longer than a "failed" dump. is this correct?

thanks

Last edited by slateboy; 03-04-2012 at 01:26 PM. Reason: ammended text
Reply With Quote
  #6  
Old 03-04-2012, 07:46 PM
Jim McDougall Jim McDougall is offline
Moderator
 
Join Date: Aug 2009
Posts: 395
Default

Yes - you can send individual terminal configuration messages as well as groups.
Reply With Quote
  #7  
Old 03-07-2012, 03:15 PM
John's Avatar
John John is offline
Moderator
 
Join Date: Jan 2009
Posts: 3,007
Default

Quote:
Originally Posted by slateboy View Post
Forgive me for being dumb, i am on my first few attempts at programming my CPU

Is it possible to configure one terminal at a time, ie, dump sysex:
F0 00 01 5D 04 01
00
00 00 44 00 01 00
00 01 44 00 01 7F
F7

OR
will the device only accept a complete layer dump, about 296 bytes worth?
As Jim says, yes--you can specify only a single configuration chunk, if you wish, or anywhere between that and a full layer.

Any chunks not specified in your sysex will be unchanged in MIDI CPU configuration memory.

Quote:
and, does the activity indicator illumination time vary on message type or message length, ie with a successful sysex dump the LED appears to stay on longer than a "failed" dump. is this correct?

thanks
Correct. When the MIDI CPU sends any type of MIDI output--either MIDI messages during normal operation, or a sysex dump when requested--the activity LED will blink. For very long strings of output, such as a configuration dump, the LED will stay lit for a noticeably long time. (each byte requires about 0.3 milliseconds, and the MIDI CPU always adds a little extra so that very short messages result in a easily noticeable "blink")

This is unrelated to the activity LED self-test, which is performed at every boot and also serves to indicate receipt of a sysex message that changes MIDI CPU configuration. This is always a fixed length.
Reply With Quote
  #8  
Old 10-16-2012, 02:48 PM
Root6t6 Root6t6 is offline
Junior Member
 
Join Date: Sep 2012
Posts: 16
Default

Just for everybody's information and to help out those having issues programming...

I was having no luck at all using SendSx to program my MIDI-CPU project with countless tries and checks of my code and just about to pull my hair out when I was just copy/pasting my code text file into SendSx and sending.
I could not even get the activity LED to flicker once...

However I then tried using the text-to-sysex Converter mentioned and linked to in the above post to create sysex .syx files that I then sent using SendSx.
Worked on the first try and all is good!

Give the converter a try if you are having trouble.
Cheers!!!
Reply With Quote
  #9  
Old 11-27-2012, 12:26 AM
slateboy slateboy is offline
Junior Member
 
Join Date: Feb 2012
Posts: 15
Default midi cpu programming aid

Is there any app or tool to assist in programming sysex for the midi-CPU?

I am unaware of one so i have taken it upon myself to create something that will do the job. This really is in the early stages of functionality but if it appears of value or use i may invest my time further to advance it.

If on the other hand there is a tool out there to do the job already please let me know so i can save myself (and others) time.
Likewise, if my attempt is in anyway unsuitable please comment and i will act accordingly.

see:
http://sugarkick.co.uk/midicpu

thanks for looking.
Reply With Quote
  #10  
Old 11-27-2012, 01:58 AM
John's Avatar
John John is offline
Moderator
 
Join Date: Jan 2009
Posts: 3,007
Default

Quote:
Originally Posted by slateboy View Post
Is there any app or tool to assist in programming sysex for the midi-CPU?

I am unaware of one so i have taken it upon myself to create something that will do the job. This really is in the early stages of functionality but if it appears of value or use i may invest my time further to advance it.

If on the other hand there is a tool out there to do the job already please let me know so i can save myself (and others) time.
Likewise, if my attempt is in anyway unsuitable please comment and i will act accordingly.

see:
http://sugarkick.co.uk/midicpu

thanks for looking.
Slateboy, thank you for posting this! This is very well done. I will begin directing users to your app, if you are comfortable with that.

I should disclose that I have been experimenting with Max to build a locally-executable app that does this sort of thing. But it is a pretty long way off. I hope that doesn't discourage you. I'll probably be using your app...a lot.
Reply With Quote
  #11  
Old 11-27-2012, 03:11 PM
slateboy slateboy is offline
Junior Member
 
Join Date: Feb 2012
Posts: 15
Default

thanks for the words of encouragement. If you, and others, feel it is of use by all means use it and direct others to do the same. I will add a bit more when i get time.
Reply With Quote
  #12  
Old 02-15-2013, 11:03 PM
lagouyn lagouyn is offline
Junior Member
 
Join Date: Feb 2013
Posts: 2
Default Restore to factory default?

Hello,

New member...embarking on a 25-note Hammond bass pedal project.

Question: after having sent some SysEx to the MidiCPU, is it possible to restore it to the factory default?

(I recall reading in the new user post that the MidiCPU ships with a default configuration.)

Thanks!
-Allan
Reply With Quote
  #13  
Old 02-16-2013, 06:06 PM
J.D. J.D. is offline
Member
 
Join Date: Jun 2010
Location: Providence
Posts: 57
Default

Allan --

Read the manual buddy!!!

I don't think there's any code that will reset the factory settings. But they're all listed in chapter 9 of the Firmware manual. Cut, paste, relax.
Reply With Quote
  #14  
Old 02-19-2013, 06:03 PM
John's Avatar
John John is offline
Moderator
 
Join Date: Jan 2009
Posts: 3,007
Default

Quote:
Originally Posted by lagouyn View Post
Hello,

New member...embarking on a 25-note Hammond bass pedal project.

Question: after having sent some SysEx to the MidiCPU, is it possible to restore it to the factory default?

(I recall reading in the new user post that the MidiCPU ships with a default configuration.)

Thanks!
-Allan
Hi Allan,

As J.D. indicates, the factory defaults are described in the firmware user manual linked from the product page.

Unfortunately, there is no shortcut to "globally revert" the MIDI CPU to its factory state. But you can get the same result by copying the default sysex from the manual and sending it to the MIDI CPU. I probably should post the default sysex files here for anyone that needs them.
Reply With Quote
  #15  
Old 07-22-2013, 02:30 PM
ceb2112 ceb2112 is offline
Junior Member
 
Join Date: Jul 2013
Posts: 7
Default Want to be sure my MIDI interface can do SysEx

I have a USB-MIDI interface, E-MU midi1x1 Tab (see pic), that I use on a Mac to connect a MIDI keyboard to control software instruments in GarageBand. I want to be sure I can send SysEx over this, prior to buying the MIDI CPU. First, does anyone know if I can? Second, if I want to use Sqwerl to do a loopback test, can I just connect the two male MIDI in and out connectors to each other via a female-female connector such as the 5-pin MIDI Coupler from Radio Shack (274-530) to create the loopback?



Thanks,
Chris
Reply With Quote
  #16  
Old 07-22-2013, 05:17 PM
John's Avatar
John John is offline
Moderator
 
Join Date: Jan 2009
Posts: 3,007
Default

Quote:
Originally Posted by ceb2112 View Post
I have a USB-MIDI interface, E-MU midi1x1 Tab (see pic), that I use on a Mac to connect a MIDI keyboard to control software instruments in GarageBand. I want to be sure I can send SysEx over this, prior to buying the MIDI CPU. First, does anyone know if I can? Second, if I want to use Sqwerl to do a loopback test, can I just connect the two male MIDI in and out connectors to each other via a female-female connector such as the 5-pin MIDI Coupler from Radio Shack (274-530) to create the loopback?



Thanks,
Chris
Hi Chris, welcome.

I don't have experience with this particular interface, so I'm not if or how well it handles sysex.

But yes, using a female-female connector should work for the loopback.
Reply With Quote
  #17  
Old 07-22-2013, 05:35 PM
ceb2112 ceb2112 is offline
Junior Member
 
Join Date: Jul 2013
Posts: 7
Default

Well I tried the coupler and ran the loopback test in Sqwerl, and it said "SysEx Time Out!". Sqwerl does see the interface (i.e. it shows up in the "MIDI Interface" section at the lower right of the UI). The interface is working properly - I can hook up my keyboard through it to my computer and play instruments in GarageBand.

The reason I asked about using the coupler, as it seems like it is intended as a means to extend a cable. I would think (but I'm a complete beginner with this stuff), that in order for it to work for what I'm trying to do, it would have to be like a crossover cable, i.e. crossing over pins 4 and 5, in order to work as a loopback cable.

Chris
Reply With Quote
  #18  
Old 07-22-2013, 05:51 PM
John's Avatar
John John is offline
Moderator
 
Join Date: Jan 2009
Posts: 3,007
Default

Quote:
Originally Posted by ceb2112 View Post
Well I tried the coupler and ran the loopback test in Sqwerl, and it said "SysEx Time Out!". Sqwerl does see the interface (i.e. it shows up in the "MIDI Interface" section at the lower right of the UI). The interface is working properly - I can hook up my keyboard through it to my computer and play instruments in GarageBand.

The reason I asked about using the coupler, as it seems like it is intended as a means to extend a cable. I would think (but I'm a complete beginner with this stuff), that in order for it to work for what I'm trying to do, it would have to be like a crossover cable, i.e. crossing over pins 4 and 5, in order to work as a loopback cable.

Chris
You might also try using SendSX together with the loopback. (Make sure to select the interface in both the "Midi In" and "Midi Out" menu.) Can you send a MIDI note and see it come back in? The hex code for a note would be:

90 00 01

If that works, then try a simple arbitrary sysex message like this:

F0 00 F7

That too should come back.

If neither works, then perhaps you are right about the crossover, but I don't believe it will be necessary.

Last edited by John; 07-22-2013 at 05:55 PM.
Reply With Quote
  #19  
Old 07-22-2013, 08:28 PM
ceb2112 ceb2112 is offline
Junior Member
 
Join Date: Jul 2013
Posts: 7
Default

Quote:
Originally Posted by John View Post
You might also try using SendSX together with the loopback. (Make sure to select the interface in both the "Midi In" and "Midi Out" menu.) Can you send a MIDI note and see it come back in? The hex code for a note would be:

90 00 01

If that works, then try a simple arbitrary sysex message like this:

F0 00 F7

That too should come back.

If neither works, then perhaps you are right about the crossover, but I don't believe it will be necessary.
Couldn't use SendSX, as I'm on a Mac. But all is well (I think). I used a combination of SysEx Librarian, and it's "sister tool", MIDI Monitor, to successfully perform a loopback test of SysEx messages, with the MIDI In and Out of my USB-MIDI interface connected via the Radio Shack MIDI Coupler. MIDI Monitor showed the exact same SysEx data being received as was sent, when Out and In were connected together with the coupler.

Yay!!!
Reply With Quote
  #20  
Old 10-23-2013, 09:07 PM
soundog soundog is offline
Junior Member
 
Join Date: Jan 2013
Location: Battle Ground, WA
Posts: 18
Default

Quote:
Originally Posted by slateboy View Post
thanks for the words of encouragement. If you, and others, feel it is of use by all means use it and direct others to do the same. I will add a bit more when i get time.
Slateboy --- This is very useful, thank you for creating and sharing it! If you ever have the time, it would be great if you could add the "multipurpose data register" commands, complete through version 1.4.
Reply With Quote
Reply

Tags
hex, howto, midi cpu, sysex

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 10:26 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2017, vBulletin Solutions, Inc.