Axoloti controller plan - encoders, touch screen TFT


#1

Hello, I'm working on a simple controller to go in an enclosure with the Axoloti. It's four rotary encoders with a touch screen TFT display used to show labels and values for each. The idea is that it can be flexible enough to use the Axoloti as a multi fx unit or a synth with controls - looking something like the the NSynth Super.

I've got it working with one encoder connected to a NodeMCU, which is connected to a Nextion 4.3" (which makes GUI handling very easy). The NodeMCU is passing MIDI to the Axoloti MIDI In port and the Nextion can show the current 0-127 value from the encoder. This is all programmed using Arduino IDE and the Nextion requires it's pages designed with it's editor program.


I'm hoping to use the encoder switch to select other parameters and send MIDI CCs for each one as they're changed. The touch screen can do something too. Each encoder needs three GPIOs, the Nextion needs UART TX/RX and MIDI IN and OUT to the Axoloti. I'll need a multiplexer for the encoders.
Does all this sound like a good plan? The Axoloti doesn't handle anything other than sound. I also need to send MIDI from the Axoloti to the NodeMCU (or whatever I finally use) to configure the current state of the values of the CCs it's meant to control - using SysEx? Also I need to program three things when changes are made (Axo, NodeMCU, Nextion.) Any suggestions are welcome.

Thanks, Simon.

UPDATED see below


#2

I plan to make something quite similar with an arduino due equiped with a touch screen. I think that we should establish a sort of midi protocol to exchange data between the Axoloti and the pa5ch/preset controller.
The Axoloti should transmit what parameters are editable, what are their names and so on. The preset/patch would be used to manage and program preset banks. It can be also used to show some parameter changez in realntime ( lfos, enveloppes, modulations...)


#3

A dump of CC numbers with their values would be all I would need, with some MIDI message to instigate Axoloti to do this (I am totally new to the Axoloti, by the way!)
Considering the encoders, I feel a multiplexer will probably miss the encoder steps. Then I remembered these I2C encoders... more expense, but they are ideal.


#4

I believe it is the Arturia Beatstep which has a mode where it sends the value 1 every time an encoder is turned one notch to the right, and the value 127 (or -1 interpreted as 7 bit signed) every time an encoder is turned on notch to the left. That way, the controller doesn't have to know the value of the parameter before a knob is turned. The Axoloti could then add the incoming CC value to the relevant parameter value and respond with the real parameter value which could then be displayed. That would make for a fairly simple protocol.

Hm, there would be a startup problem here I suppose - the controller wouldn't know which values to display initially. Of course, it could send a CC value of 0 causing the Axoloti to respond with the actual parameter value without changing it.

I have one comment on the proposed knob layout above: the Ambika has a similar layout with knobs both above and below the screen, and although it allows more knobs that way, I find it very irritating that my hand is blocking my view when I'm adjusting the knobs in the top row.


#5

Hello Ricard. I posted something the other day on a thread discussing how to get Axoloti to respond to relative encoder increment/decrement signals from Arturia encoders used this way: https://sebiik.github.io/community.axoloti.com.backup/t/how-to-implement-midi-relative-controllers/3915/6
Everything is hard wired though. Ideally when you assign a CC to adjust a parameter in the patcher application, Axoloti could allow you to choose relative or absolute values from encoders. Since it doesn't, I'm looking for a way for Axoloti to send details of what the parameter value is for a particular CC, to my controller over MIDI. I know little about the workings of the firmware or writing objects and want just to approach this as sending and receiving MIDI. I don't think the support is there to do this though.

The knob layout has been chosen because the Nextion screen has pcb at the sides but none at the top and bottom, making the encoders too far from the screen and the overall enclosure wider. Ideally I would love to design a pcb and use a TFT screen run directly from a MCU, but that's for another time!


#6

True, the Axoloti doesn't support relative parameters in its firmware. Shouldn't be too hard to implement but requires some knowledge of the internal workings. I believe it can be done in an object since there are objects that reference the internal parameter structures.

I've implemented a patch that can handle rotary encoders connected to Axoloti I/O pins and use them to modify parameters, see this thread https://sebiik.github.io/community.axoloti.com.backup/t/ricard-contributions/4311/3 . It shouldn't be hard to modify to read CC values rather than encoders directly. (In my case I'm running the Axoloti firmware on an Audiothingies P6, where there is encoder and display hardware, which requires modifications to the Axoloti firmware, but the firmware changes are just there to support the different hardware configuration; all the encoder stuff happens in the patch itself.)


#7

Hello, a small update (if anyone's mildly interested). I bought four I2C Encoders from Duppa on Tindie. They weren't great value with the shipping at $32 in total for the basic boards, but having just five wires and the flexibility to daisy-chain more is great however. The code is much simpler with the supplied Arduino library. There's an interrupt and with some decent coding, you just add another encoder object to an array when you add more. They're still connected to the ESP8266.

So I've got lots of MCUs instead of just one now! I'm still considering whether to use the Nextion or switch to I2C OLEDs and how to get parameter data from the Axoloti to the ESP8266. It would be easier with everything connected to the Axoloti of course.


#8

I bought some of those rotary encoders as well. It's best described as a rotary encoder with an (optional) RGB knob that offloads the rotary encoder counting onto a PIC chip on the board and provides an i2c interface. There were some left over IO pins on the PIC so as a bonus the designer made them available for general use (gpio, pwm).

Writing an axo driver for it is on my TODO list.

It should be possible to daisy chain N of them together on the single axo i2c bus.

It would be nice if the axo supported i2c device interrupts. That way you wouldn't have to waste time polling the devices when there is no update- but so far as I can tell the default chibios configuration is not set up for this.