Go Down

Topic: Sysex message transmission (Read 956 times) previous topic - next topic

kooroshi60

Hello guys.
I wonder if it is possible to program an Arduino (as a stand alone device) in order to send single a Sysex message using a switch to a MIDI device?

I need to send these two Sysex messages to a Roland JV-1010 in order to switch the Scale tuning ON and OFF.

Scale tune ON= F0 41 10 6A 12 00 00 00 07 01 78 F7

Scale tune OFF= F0 41 10 6A 12 00 00 00 07 00 79 F7

I have programmed the scale tuning values in JV-1010 module and now, I like to be able to turn it on and off without the computer.

Any help is highly appreciated.
Ciao!

Grumpy_Mike

Quote
I wonder if it is possible to program an Arduino (as a stand alone device) in order to send single a Sysex message using a switch to a MIDI device?
Yes it is.

Quote
Scale tune ON= F0 41 10 6A 12 00 00 00 07 01 78 F7

Scale tune OFF= F0 41 10 6A 12 00 00 00 07 00 79 F7
Just send those bytes out to the MIDI device.

kooroshi60

#2
Oct 04, 2016, 11:40 pm Last Edit: Oct 05, 2016, 09:06 am by kooroshi60 Reason: Putting the code in it's proper section.
Thank you Mike. Do you think this code is correct?

Code: [Select]
#include <MIDI.h>
#include <midi_Defs.h>
#include <midi_Message.h>
#include <midi_Namespace.h>
#include <midi_Settings.h>


//Scale tuning switch for Roland Jv-1010

int switchPinON = 8;
int switchPinOFF = 7;
byte onArray[12] = {0xf0, 0x41, 0x10, 0x6a, 0x12, 0x00, 0x00, 0x00, 0x07, 0x01, 0x78, 0xf7}; // ON array
byte offArray[12] = {0xf0, 0x41, 0x10, 0x6a, 0x12, 0x00, 0x00, 0x00, 0x07, 0x00, 0x79, 0xf7}; // OFF array

void setup()
{
pinMode (switchPinON, INPUT);
pinMode (switchPinOFF, INPUT);

}

void loop()
{

if (digitalRead(switchPinON) == HIGH)
{
sendSysex (10, onArray, true);
}
}
if (digitalRead(switchPinOFF) == HIGH)
{
sendSysex (10, offArray, true);
}
}




I am a completely noob to Arduino; So this is all I could figure out!
Arduino is showing error on this code Indeed!
Would you guys please help me out with this?
Thank you!




Grumpy_Mike

Read the how to use this forum sticky post and learn about posting code using code tabs. This will allow us to try your code for ourselves. Don't post it again, just edit that post.

Go Up