Menu system and vtables

I have looked into several general menu libraries available. A bit steep curve to use, because you will need to provide a renderer and pin button connections to start off. Or you will have to use a general display driver like u2g or adafruit instead off the provided midiboy SH1106 library…

Then, they are still hard to use and take time to judge. In the end, they did not seem to provide the functionality i needed. So i ended up building one myself. Bloated OOP.

Which brings up two issues.

  1. Without a decent modern IDE, it is hard to read and use all these nice c++ programs/libraries
  2. The OOP eats a lot of dynamic memory. You can store only so much in PROGMEM, vtables end up in dynamic memory.

I have tried the flash-vtable compiler plugin, but it seems to be related to a compiler that does not fully comply with AVR/midiboy.

https://forum.arduino.cc/t/put-avr-vtables-into-the-flash/639611

The sketch compiles and uploads (with or without the plugin enabled), and the sketch runs, … until it hangs. I have tried several of the AVR-GCC versions, all with the same result.

Anybody has any experience with putting vtables in PROGMEM?

I was thinking of putting up the menu system itself in the patch bay. Probably a bit to much for some others in terms of memory consumption, but at least it will allow you to quickly build a prototype.