Jump to content
Why become a member? ×

Build your own MIDI controller. (I did!)


stoo

Recommended Posts

J'ai pris la prise midi que j'avais préparé pour le premier footswitch que j'ai fabriqué (ta première version) et ça fonctionnait très bien! Y a t-il un changement par rapport au premier ...? 

Je vais chercher de ce côté là! 

Encore merci pour tout Stoo, tu es un chef pour moi !!! 

Je te retiens au courrant dès que j'ai trouvé! 

J'ai hâte de voir tes nouvelles versions si tu développes ce projet! 

À bientôt ! 

Guillaume 

Edited by guillaumegart
Link to comment
Share on other sites

5 hours ago, guillaumegart said:

I took the midi plug that I had prepared for the first footswitch I made (your first version) and it worked very well! Is there a change from the first ...?

I'll look on that side!

Thank you again for everything Stoo, you are a chef for me !!!

I'll keep you posted as soon as I find it!

I can't wait to see your new releases if you develop this project!

See you soon !

Guillaume

I think the MIDI socket wiring should be the same for both versions.... 

Glad to hear you're making progress!

I haven't got any current plans for future versions, but maybe inspiration will strike again - who knows?

Cheers!

Link to comment
Share on other sites

Bonjour Stoo, 

Rien ne change pour mon footswitch.... 

J'ai refait le cablage, vérifié les fils de la prise MIDI.... 

Hormis téléverser les croquis Arduino et paramétrer l'ecran Nextion y a t-il d'autres manipulations ou paramétrages a faire ? 

Je suis bloqué pour l'instant. J'arrive seulement a changer les pages de l'ecran.... 

16198905893828276789566400284953.jpg

Link to comment
Share on other sites

28 minutes ago, guillaumegart said:

Hello Stoo,

Nothing changes for my footswitch ....

I redid the wiring, checked the wires of the MIDI socket ....

Apart from uploading the Arduino sketches and configuring the Nextion screen are there any other manipulations or settings to be made?

I'm stuck for now. I can only change the pages of the screen ....

Sorry, I misunderstood..... I thought you had got the MIDI communication working by using the MIDI socket and wires from your previous build.

I have had another look over my notes and I have found some mistakes in the files I uploaded to github - the wiring for the breadboard circuit diagram, and the soldered shield circuit diagrams don't match!

I was guiding you earlier based on the breadboard version, as that is easier to read - but that doesn't match the circuit that is in my working controller! Sorry to have confused you!

OK - So in my controller, I have 

Arduino TX3 (14) -> yellow wire -> Nextion screen
Arduino RX3 (15) -> blue wire -> Nextion screen
Arduino TX2 (16) -> green wire -> MIDI socket pin 5 (the green one in https://www.instructables.com/Send-and-Receive-MIDI-with-Arduino/ )

I have the 220 ohm resistor in mine on the +5V wire - same as in the instructables link above, but I just came across these pages - https://www.electroschematics.com/midi-introduction/ and https://www.arduino.cc/en/Tutorial/BuiltInExamples/Midi - which suggest putting a resistor on both the +5V and the serial TX wires. I'm not going to change mine, but if I was starting again, I will use resistors on both wires. Your choice!

Right so - this now means that : 

Serial3 is being used for the Nextion screen
Serial2 is being used for MIDI, and 
Serial1 is free for debugging messages and for uploading new sketches from the computer to the Arduino.

That also means the advice I gave you earlier was also incorrect. 

In my Nextion library, my NexConfig.h has the following lines for serial configuration  :

/** 
 * Define DEBUG_SERIAL_ENABLE to enable debug serial. 
 * Comment it to disable debug serial. 
 */
//#define DEBUG_SERIAL_ENABLE

/**
 * Define dbSerial for the output of debug messages. 
 */
#define dbSerial Serial

/**
 * Define nexSerial for communicate with Nextion touch panel. 
 */
#define nexSerial Serial3

and the first line of the "06_midi.ino" file should be:

MIDI_CREATE_INSTANCE(HardwareSerial, Serial2, MIDI);

But this matches the code on github, so hopefully you should be OK with this one.

Sorry again - hope this is enough to get you up and running!

Link to comment
Share on other sites

Hello Stoo,

thank you for your great article on the controller.

Your 8 switches mount works very well with the 128x64  oled screen.

I'm looking for a  6 footswitches configuration with the arduino  nano  and the 128x64 oled screen.

I try to modify  your code to make with 6 switches, but it doesn't work (MidiSwitcher3x2.ino).

Would you have a code for this situation ?

thanks in advance

MidiSwitcher3x2.ino

Link to comment
Share on other sites

1 hour ago, ricou831 said:

Hello Stoo,

thank you for your great article on the controller.

Your 8 switches mount works very well with the 128x64  oled screen.

I'm looking for a  6 footswitches configuration with the arduino  nano  and the 128x64 oled screen.

I try to modify  your code to make with 6 switches, but it doesn't work (MidiSwitcher3x2.ino).

Would you have a code for this situation ?

thanks in advance

MidiSwitcher3x2.ino 14.14 kB · 1 download

Hiya - 

"It doesn't work" doesn't really give me much to go on. I'm happy to try and help with specific problems if you can explain what you've done, what you expected to see happen, and what actually happened...... I'm not sure I want to get into a "I've changed some stuff, now it doesn't work, please fix" type situations though :D

I don't have anything ready configured for a 3x2 configuration, but my advice would be - start with the code for my 4x2 version on github - https://github.com/stoonoon/hxsMidiSwitcher/blob/master/hxsMidiSwitcher.ino 

Make sure you can
-compile it,
-upload it to your nano,
-and that your switches get detected by the Nano, and do something on the MIDI device you're controlling....

If the nano has 2 pins that aren't connected to switches - it won't know or care... it'll just think that no-one is pressing those switches.

Once you've got that far, then you can make small iterative changes - maybe start with the void displayUpdate(void) function and get the text displaying on the screen to look how you want.
Then, once that works OK - save a copy somewhere so you have a reference point you can go back to, and then try fiddling with the void midiSend() function, and update the switch/case statements so the MIDI commands match the commands you have displaying on the screen.
After that, you could maybe go through the void readButtons() function and make sure any 2xfootswitch combo functions you want to use are pointing to switches that you have, and are on switch combinations that make sense to you. 

Hope that helps

Link to comment
Share on other sites

Hi, Stoo

Thanks for your return.

For the 3X2 midi controller, i start with the code for your 4x2 version.

I try to modify all the items, but finally i have many errors.

I just finish the 4X2 version, and it works very well.

It's useful, but the footswitch spacing is very low.

I try to restart my 3x2 version with your advice.

Thanks.

IMG_1112.jpg

Edited by ricou831
Link to comment
Share on other sites

  • 2 weeks later...

Hi Stoo!

Thanks for making this available!

Managed to get the initial page to work on your oled version of the switcher. Can´t make sw 1+2 and sw2+3 to work, so I´m stuck with FS1-5 + Snapshot 1-3. Sw 3+4 and 7+8 works though. Any idea what I´m doing wrong?

Link to comment
Share on other sites

29 minutes ago, marilo said:

Hi Stoo!

Thanks for making this available!

Managed to get the initial page to work on your oled version of the switcher. Can´t make sw 1+2 and sw2+3 to work, so I´m stuck with FS1-5 + Snapshot 1-3. Sw 3+4 and 7+8 works though. Any idea what I´m doing wrong?

The obvious things to check first would be switch wiring and ordering - do all of the switches work individually?

When you press them individually do they do what you'd expect?

 

Link to comment
Share on other sites

On 23/05/2021 at 13:58, stoo said:

The obvious things to check first would be switch wiring and ordering - do all of the switches work individually?

When you press them individually do they do what you'd expect?

 

Yes they do and even sw3+4 (tuner) and 7+8 (reset) works. When I look at midi monitor everything seems ok for sw 1-8 individually as well as 3+4 and 7+8. When I press 1+2 or 2+3 midi monitor choses to reflect one of the 2 switches I press at once. I downloaded the hxsMidiSwitcher.ino from here: https://github.com/stoonoon/hxsMidiSwitcher . Is this the correct version?

Edited by marilo
completing
Link to comment
Share on other sites

3 hours ago, marilo said:

Or maybe the HX Stomp FS has to be configured in a special way to make this work?

Hang on - aren't the combos you're talking about for pgup / pgdn ? If so - that's setup for changing the page displayed on the footswitch screen to an alternative control layout.... I wouldn't expect it to send any midi to the stomp for those....

Link to comment
Share on other sites

55 minutes ago, stoo said:

Hang on - aren't the combos you're talking about for pgup / pgdn ? If so - that's setup for changing the page displayed on the footswitch screen to an alternative control layout.... I wouldn't expect it to send any midi to the stomp for those....

Not sure I´m following.. How should the stomp be configured to make the midi controller work as intended?`How do I switch to the alternate control layout? :)

Link to comment
Share on other sites

6 hours ago, marilo said:

Not sure I´m following.. How should the stomp be configured to make the midi controller work as intended?`How do I switch to the alternate control layout? :)

Uhhhh fair question..... I dug out my old controller and blew the dust off it to remind myself how it works..... and mine doesn't change pages either!

I'm sure it used to, but it's been a couple of years since I've even looked at the old one. I know with the newer one I ended up finding a button layout I liked and almost never flip pages. Can't remember whether I got to the same point on the v1 and accidentally uploaded the single page version to github or something.

I'll have a play with it and see if I can get it working again, but I'm not likely to get much time on it until the weekend.

Link to comment
Share on other sites

8 hours ago, stoo said:

Uhhhh fair question..... I dug out my old controller and blew the dust off it to remind myself how it works..... and mine doesn't change pages either!

I'm sure it used to, but it's been a couple of years since I've even looked at the old one. I know with the newer one I ended up finding a button layout I liked and almost never flip pages. Can't remember whether I got to the same point on the v1 and accidentally uploaded the single page version to github or something.

I'll have a play with it and see if I can get it working again, but I'm not likely to get much time on it until the weekend.

I understand! Thanks for helping out! :) 

Link to comment
Share on other sites

On 27/05/2021 at 05:13, marilo said:

I understand! Thanks for helping out! :) 

Well this is a bit embarrassing.... On Thursday I did have a quick look at this and thought I'd found the problem. I was going to suggest it to you to try, but then thought I may as well test the change on mine seeing as I'd already dug it out. I made the change, recompiled it, uploaded it and.... no difference.

Since then I've been dreading going back over 2 year old code to try and troubleshoot it. I finally decided to give it a look today. The code looked like it should work. Let's try and upload it again just in case..... BAM! Upload error due to not having the correct type of bootloader selected in the Arduino uploader. D'oh! Must have not noticed that pop up when I tried on Thursday. 

So anyway - the line you're looking for is......

static const byte pageCount =1; // how many pages we have configured

And it needs to be.

static const byte pageCount =2; // how many pages we have configured

Hope this works OK on yours too! :D

Link to comment
Share on other sites

8 hours ago, stoo said:

Well this is a bit embarrassing.... On Thursday I did have a quick look at this and thought I'd found the problem. I was going to suggest it to you to try, but then thought I may as well test the change on mine seeing as I'd already dug it out. I made the change, recompiled it, uploaded it and.... no difference.

Since then I've been dreading going back over 2 year old code to try and troubleshoot it. I finally decided to give it a look today. The code looked like it should work. Let's try and upload it again just in case..... BAM! Upload error due to not having the correct type of bootloader selected in the Arduino uploader. D'oh! Must have not noticed that pop up when I tried on Thursday. 

So anyway - the line you're looking for is......

static const byte pageCount =1; // how many pages we have configured

And it needs to be.

static const byte pageCount =2; // how many pages we have configured

Hope this works OK on yours too! :D

Thank you thank you thank you!!! I would never found out that! I´m a beginner and know basically nothing about programming. Been building stompboxes and suddenly went down this Arduino rabbit hole! Starting to understand a tiny little bit but that's it. Hope I can be helpful in some other way than programming!! :)   🙏

  • Like 1
Link to comment
Share on other sites

  • 3 weeks later...

I happened to see an item in the Line 6 forums which mentioned a change to the MIDI CC messages in v3.10 of the Helix software which is relevant to the various DIY switches that we've got. There is now a dedicated preset up/down CC message, so rather than changing mode, sending a FS1/FS2 message, then changing mode again, you can just send CC 72 with the value 64-127 to increment (preset up) and 0-63 to decrement (preset down). Less messing around and will speed things up a little as there's no need to put in delays after changing mode (that's a whole 200mS it'll save in my switcher).

Link to comment
Share on other sites

  • 2 months later...

@stoo hi there! first i want to say thank you for the arduino program, this project saved my wallet totally!!! 🤣

second thing, i have a question about, i wanted to put the fixed led only on the snapshots frame(we can say frame? lol) like i press snap 1 and boom fixed, cos i can see what snapshot i am using 😵. p.s. i have the first project with the oled. thanks maaaaaan 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...