Using GPIO pin to cycle through pedalboards

:slight_smile: nice one
I’m glad you managed to make it work
hopefully it mounts automatically every time :wink:

1 Like

Fingers crossed man, its drive me a bit crazy to be honest, ha ha ha!
I’m no expert with Linux and this type of stuff, but I’m good enough to know I couldn’t see anything that should give me all this grief ha ha!
Let know if that python midi port code comes in handy, if not I can have a look through other stuff I’ve accumulated.
I’m intrigued by all of your projects, do you have them documented anywhere?

This is a bit vague to me, I am unsure what you are all trying to do with MIDI inputs.

But one comment I have, rising from hard experience and deep theory is if you want performance (quick, useful real time) then you have to not use Python.

Use C, use Rust, but the overhead of Python is just way too high.

Python is from another era when computers were doubling in speed every few months and efficiency meant programmer efficiency. Down on the Raspberry Pi, trying to change software setting inside of tens of milli seconds, we do not have the time to wait for python to wake up and get going

patch@patchbox:~ $ time python3 -c quit

real    0m0.044s
user    0m0.011s
sys     0m0.031s

44ms of waste

As opposed to:

patch@patchbox:~ $ cat /tmp/test.c
int
main(){
}
patch@patchbox:~ $ gcc /tmp/test.c -o /tmp/text
patch@patchbox:~ $ time /tmp/test
-bash: /tmp/test: No such file or directory

real    0m0.003s
user    0m0.002s
sys     0m0.001s

That is not very scientific, but it illustrates that if we want to do live music, python is not going to help

cheers
Worik

For me, the use of python is a creature comfort.
I’m not well versed in using straight C in a headless Linux environment but I can fetch by with Python as it’s the first language I picked up.
I understand that python does indeed have a bigger overhead and added costs with regards to time, but the ability to get something working with a familiar environment with libraries I’m familiar with helps.

Very much in a state of flux. But this is the repository I am using as a backup. Help yourself.

This is the code for driving my pedal.

I am still a long way from a box I can confidently take on stage with me, but getting closer every day.

3 Likes