Using just a few rotary encoders to control almost every parameter of axoloti?


#1

hi all, right now people are using potentiometers to adjust parameters.

but since the axoloti has limited amount of analog inputs, and those pots consume power as well, i suggest we look into rotary encoders
like:
one to scroll trough parameters of a patch
one to control first param
one to control second param (if supported)
one to control third param (if supported)
one to control fourth param (if supported)

small example:
if the first encoder is 0: light up external led 1 for adjusting adsr_1 envelope (using the other encoders)
if the first encoder is 1: light up external led 2 for adjusting oscilator 1&2 pitch/mix (using the other encoders)
if the first encoder is 2: light up external led 3 for adjusting other params (using the other encoders)
and so on.

and to go even fancier: perhaps make a serial based display driver? (like 2x16characters or 4x20characters)

if you still don't get what i mean, simply look at the Groovesizer TB2 (open source arduino due based synth), it uses the exact system i pretty much want right now for axoloti. :smile:
and if that isn't clear enough, have a look at this: https://sebiik.github.io/community.axoloti.com.backup/t/ableton-push-controlling-axoloti/248
but the only difference being having the controls embedded instead of using midi. (so no ableton push needed, since the price can be quite high for it)

for now, the major 2 questions are: is it possible and if so, how do we archieve this code/patching wise?


128 channel mux for many buttons to axoloti?
#2

One way to do it that doesn't involve making an object/.axs with outlets for every single parameter you'd want to control, and inlets for all the encoders. One encoder input (parameter selecter) controls a counter and some muxes that sends the other encoders to counters that are connected to the outputs.


#3

I kind of touch on this already in this thread.

is it possible... yes. Ive already shown that on the push, midi is just the implementation... it could be anything including gpio/lcd.

you don't do it by adding objects, you do it by accessing parameters directly... this means it works for every patch without additional objects being added.

is it easy...
well once you understand how parameters work, then getting/setting those is not hard, but its still a lot of code to get it to work. and frankly, without an LCD screen its pretty useless for anything other than trivial patches. (it wouldn't really be worth the effort)

whilst I recognise the Push is expensive (if you don't happen to already use it for Live) there could be quite a few other midi control options that people could write 'drivers' for, e.g. Launchpads are cheap. with a bit of 'creativity' these could be pretty good... and have the advantage that many people can use. (look at what people have done with launchpads with Live.)

note: this is also the concept of Axoloti Control, which is still (afaik) planned, but of course Axolotl Core is taking priority.

note: using midi can result in low precision (7bit), unless you take the approach used by push with endless encoders and use relative encoding ... which is extremely cool.


Parameter editor
#4

why is it me thinking it's the best (and easiest) to have an arduino zero compatible as midi cc on the axoloti?


#5

you mean like this simple thing i did just now?

encoder inputs.axp (14.3 KB)


#6

I had the same idea as Inaba, but I don't understand answers (maybe because I never used a axoloti)

Would it be possible to create a patch and use a main poti to switch beneath osc, lfo, filters etc. and use the other potis to adjust selected parameters? That woud be pretty much the system of a Waldorf Blofeld or a MicroKorg.
Or, to be more specific, would it be possible to do this just in the Axoloti patcher? (without programing new objects etc.)


#7

Did you have any luck with using encoders in the end? Did your patch work? Looks pretty good to me.


#8

Here is my test with a rotary enc., the patch file can be download at github. It may don't run very sweet and need some improvement.


#9

maybe this is off-topic,but I just did this


#10

I think the encoders would work great if there was a way to have the axoloti control a small oled screen to display defined parameters. This would make it so much more powerful ! Is there a way to easily interface it to a small oled screen?


#11

Here is where I have got to with this one.
Using arduino to deal with UI

More photos and info when I am closer to everything working together.


#12

Have you seen these?

https://www.amazon.co.uk/gp/aw/d/B0156CO5IE/ref=aw_wl_ov_dp_1_1?colid=22A0CMSPVTSTN&coliid=I6QZFSWH7WJ6I&vs=1


#13

Sooo further explanation of what's going on in the photo I posted plus a vid

The black buttons (top left in pic) cycle through pages

Each page has 4 variables which are controlled by the four rotary encoders

The values are then displayed on the blue numerical displays (3 digits per encoder 0-127)

In the final version this will give 80 midi cc's which can then be sent to axoloti via UART

I hope to send values from axoloti to set the variables so that it all makes sense when you load presets etc as wel as 3 letter descriptions of the parameters to display on the screens but have yet to go near that.


#14

Reminds me very much of a Waldorf style matrix. :slight_smile:


#15

What is the way to get axoloti to send the info to the arduino? This could open the possibility to make an encoder based interface really interactive!


#16

I plan to use UART.
Connect rx , tx and gnd.
Apply code ( I have yet to work that bit out)
I have been getting the arduino side of things sorted so I have some variables to send when I do test it.


#17

what about a maple mini (clone) with stm32duino. It's much faster (72mhz, 4 timers, 12bit ADCs etc.) then a lot of AVRs and it's much cheaper. Later you can flash your MCU with chibios, too. A maple mini clone cost only around $3 incl. shipping example1 & example 2.

I played around with a maple mini clone, oled screen (ssd1306), two enc. etc. and send the message by uart to axoloti. for most components there a library with you can edit by your need but they're working out of the box.
I used midi styled communication with a higher baudrate. I was able to use the oled screen to print out current lfo waveform like an oscilloscope.

At the moment, I'm trying to mod my euxo layout to use a maple mini clone and send the datas to axoloti. transmitting should be done by I2C. If I get it working, I will post the codes online.


#18

Does that mean you have had success cominicating between axoloti and something over UART?
I would be very interested to know more about what you were doing at the axoloti end.


#19

yes, no problem. I used the chibios reference and the "extra_midi_input.axh" from archive/tests/io bin.

this is one script2 code, where an LFO value should be transmit.

uint8_t *rxbuf;
uint8_t *txbuf;
int i = 0;

void setup (void){
static uint8_t _txbuf[8] attribute ((section (".sram2")));
static uint8_t _rxbuf[8] attribute ((section (".sram2")));
txbuf = _txbuf;
rxbuf = _rxbuf;

}

void loop (void){

/*rxbuf[0] = sdGet(&SD2);
out1 = rxbuf[0];
LogTextMessage("serial: %i", rxbuf[0]);
*/
//LogTextMessage("HELLO");
sdPut(&SD2, 0x01);
sdPut(&SD2, 0x02);
sdPut(&SD2, in1);
/*
rxbuf[0] = sdGet(&SD2);
out1 = rxbuf[0];
*/
chThdSleepMilliseconds(1);

}

finally axo sends 3 bytes. 1. byte = new message; 2. byte = type of message for arduino code; 3. byte = value…
I don't know if axo's uart gpios are 5V compatible to work with avr voltage level.


#20

This is great news. Would it be possible to have axoloti send "there's a new program and here are the parameters I understand for this program" to the UI controler ?

I have an oled setup + 3 encoders (w/ button) I designed to react to light that I could adapt for this. It's based on teensy3.. color display at very nice rate, but that would be overkill.

I think ideally if we could scroll through the parameters and change them it would be great.