Midi CC message coding for a MIDI Foot controller HELP!!

Hey all! this is the first post I think I have ever made on a forum as I am stuck with how to proceed with my project.

I'm looking to build a USB MIDI foot controller for my iPad. I am a guitarist and need a footboard to change between patches on the app that I use (BIAS FX).

These midi signals as far as I am aware are in the form of (CC#) messages.

I have already learnt how to flash the Hiduino USB_Midi. Hex on to my Arduino Uno R3 (genuine before anyone asks) so that any device can recognise it as a native MIDI device. and I now understand the process required to upload sketches to the Uno as well.

That being said I am having trouble with the code required to make this work :(.
I have done numerous hours of researching, looking at other peoples code and trying to adapt it to my needs but unfortunately my efforts have been less than fruitful.

In a nutshell I would prefer to understand the code that I am writing, so wouldn't expect someone to just write it for me. that being said... any help at all would be greatly appreciated :slight_smile:

summary of what I need to achieve

The buttons I am using are momentary metal buttons. when a button is stepped on, a CC message Is sent to the iPad from the Arduino Via USB to change to a different patch.

I have read some where that I need 10k resistors and 470nF capacitors to make this happen

so I have 10 resistors, 10 capacitors and 10 buttons. and would preferably like to use them all if possible.

if it simple enough to implement then I also have an expression pedal too, this is connected by a 1/2" jack. (same as any guitar lead). and have the female housing for this cable. I believe the expression pedal is just essentially a potentiometer attached to a gear system.

I have attached a picture of what the app is asking me to do in order to program a button in to the the device.

I'm hoping someone on this forum will know something or someone that may be able to help me :slight_smile:

Many thanks for any and all help in advance.

Aaron :slight_smile: