Arduino Axe-Fx control library

tysonlt

Power User
Greetings!

I would like to announce my AxeFX control library:

https://github.com/tysonlt/AxeFxControl

This is a 100% complete implementation of the AxeFX III 3rd party MIDI spec.

So far I have tested it with my AFX3, and it is based solely on that. The 2 has different messages and I don't have one to test with.

Implemented are:
  • Preset change
  • Preset increment/decrement with rollover
  • Scene change
  • Scene increment/decrement with rollover
  • Display preset name and number
  • Display scene name and number
  • Effect channel change
  • Retrieve list of effect blocks with channel and bypass status (filters out non-effects such as input/output etc)
  • Effect bypass
  • Tuner control
  • Looper status and control
  • Realtime tuner data
  • Detects preset change from front panel
  • Send and receive tap tempo events
  • Get and set tempo value
  • Configurable auto-refresh
  • Send custom PC/CC/SysEx
  • Add custom sysex handlers with option to override normal processing
  • Add custom effect list filters to change which effects will be displayed
All of this is tested and working. I am working on the following:
  • Change the order that effects are displayed in (perhaps another filter? Or just sensible defaults?)
I would love this open-source project to become a reference implementation for the AxeFX3, and possibly add AFX2 support if this is desired. Please feel free to jump in and collaborate!
 
Last edited:
This is looking very promising! I can imagine how much time it takes you...
I tried to run examples on my Mega2560


Arduino: 1.8.8 (Windows 10), Board: "Arduino/Genuino Mega or Mega 2560, ATmega2560 (Mega 2560)"
C:\Users\Arek\AppData\Local\Temp\cccrr4NH.ltrans0.ltrans.o: In function `main':
<artificial:mad:.text.startup+0x3ac): undefined reference to `AxeSystem::registerPresetChangingCallback(void (*)(int))'
<artificial:mad:.text.startup+0x3d2): undefined reference to `AxeSystem::sendPresetChange(unsigned int)'
collect2.exe: error: ld returned 1 exit status
exit status 1
Error compiling for board Arduino/Genuino Mega or Mega 2560.
 
Hi, sadly the same with 0.3

as example trying to run examples/Tempo :

Arduino: 1.8.8 (Windows 10), Board: "Arduino/Genuino Mega or Mega 2560, ATmega2560 (Mega 2560)"
C:\Users\Arek\AppData\Local\Temp\ccwNgjSD.ltrans0.ltrans.o: In function `main':
<artificial:mad:.text.startup+0x3d8): undefined reference to `AxeSystem::registerSystemChangeCallback(void (*)())'
<artificial:mad:.text.startup+0x3e4): undefined reference to `AxeSystem::registerTapTempoCallback(void (*)())'
<artificial:mad:.text.startup+0x456): undefined reference to `AxeSystem::setTempo(unsigned char)'
<artificial:mad:.text.startup+0x45e): undefined reference to `AxeSystem::update()'
collect2.exe: error: ld returned 1 exit status
exit status 1
Error compiling for board Arduino/Genuino Mega or Mega 2560.
 
Hmm, most mysterious. The source for those files is under src/axe, whereas some versions of Arduino don't like subdirectories. I just compiled for the Mega with no problems. I am using Arduino 1.8.7, I assume you are using 1.8.8?

I have created a branch with all the source files in one folder, if that is the problem:

https://github.com/tysonlt/AxeFxControl/tree/folders
 
Yes, that was the case!
Also,I had to replace

MIDI_CREATE_DEFAULT_INSTANCE();

with

MIDI_CREATE_INSTANCE(HardwareSerial, Serial1, MIDI);

in AxeSystem.cpp @ Line #4 , because for some reason the default is Serial , not Serial1

I'll have a play on weekend, but, I was digging in your code, and man.. i see so many work has been putted into it, and it has much more features that I wanted to create in my one. It is written very well as well..

I really appreciate your work and thank you for publishing such a good project!
Will give you a feedback on weekend, but ,yeah, this seems to be amazing!

Cheers! //Arek
 
Yes, that was the case!
Also,I had to replace

MIDI_CREATE_DEFAULT_INSTANCE();

with

MIDI_CREATE_INSTANCE(HardwareSerial, Serial1, MIDI);

in AxeSystem.cpp @ Line #4 , because for some reason the default is Serial , not Serial1

I'll have a play on weekend, but, I was digging in your code, and man.. i see so many work has been putted into it, and it has much more features that I wanted to create in my one. It is written very well as well..

I really appreciate your work and thank you for publishing such a good project!
Will give you a feedback on weekend, but ,yeah, this seems to be amazing!

Cheers! //Arek

No worries bro, thank you for the feedback. I will make that change to the main branch.

As for the MIDI thing, it bothers me that I have to create it like that with no control over it. The MID library usually does a pretty good job of figuring out which serial to use. Ideally I would read the sysex manually... maybe in the future!
 
The only reason for having a subdir within source was so that if you choose "Include library" in the Arduino editor, it won't include all of the headers! This isn't really that important, but if it stops it compiling for some people I don't mind changing it.
 
MIDI_CREATE_DEFAULT_INSTANCE();

with

MIDI_CREATE_INSTANCE(HardwareSerial, Serial1, MIDI);

in AxeSystem.cpp @ Line #4 , because for some reason the default is Serial , not Serial1

I have bitten the bullet and started to write my own MIDI code. It will let you specify the serial port to use. Hang tight for about 12 hours!
 
https://github.com/tysonlt/AxeFxControl/releases/tag/0.4

No longer relies on any external libraries. MIDI has been implemented in AxeSystem.

A pluggable sysex override has also been added. You can register a callback to receive sysex responses, and returning true from the callback will halt normal sysex processing. Therefore you can send and receive custom sysex to extend the library in the future.

Also added a SysEx test utility in the extra/ folder. This just lets you type sysex bytes to send to the axe, and it prints the response. Currently has a custom handler for command 0x13, which is the effects dump. This has been mostly useful for debugging, but it's fun sending stuff to the Axe to see what it says! An 0x64 response generally means no comprende.
 
Hey Tyson,

Thanks - that’s gold! I’m off site for a few weeks but look forward to having a look when I get back!

Pauly

Greetings!

I would like to announce my AxeFX control library:

https://github.com/tysonlt/AxeFxControl

I hope this can be a complete implementation of what the Axe has to offer over MIDI. At present it implements most of the messages described in the 3rd party MIDI spec except channel changes.

So far I have tested it with my AFX3, and it is based solely on that. The 2 has different messages and I don't have one to test with.

Implemented are:
  • Preset change
  • Preset increment/decrement with rollover
  • Scene change
  • Scene increment/decrement with rollover
  • Display preset name and number
  • Display scene name and number
  • Retrieve list of effect blocks and bypass status (filters out non-effects such as input/output etc)
  • Effect bypass
  • Tuner control
  • Looper status and control
  • Realtime tuner data
  • Detects preset change from front panel
  • Send and receive tap tempo events
  • Get and set tempo value
  • Configurable auto-refresh
  • Send custom PC/CC/SysEx
  • Add custom sysex handlers with option to override normal processing

All of this is tested and working. I am working on the following:
  • Channel control (would this be useful? Would people just use scenes?)
  • Prioritise/configure which effect blocks to display (ie drive/reverb/delay before others)
  • Handle very fast preset changes from controller (only respond to latest preset name message)
  • Occasional corrupt preset names from Axe during very fast preset changes
The last two are only really relevant because I spam the preset increment button during testing, it's probably not a problem unless you can tap the button about 50 times a second :)

I would love this open-source project to become a reference implementation for the AxeFX3, and possibly add AFX2 support if this is desired. Please feel free to jump in and collaborate!
 
Back
Top Bottom