Nested GEN patches and LED control question


I am working on creating a sub gen patch that would manage LEDs for me.
To start with I used the base Daisy Field template.
In the main ~gen patch I have it setup to press B1-B4 and turn on the LED.
I have a sub gen patch called B5to8 that allows me to press B5-B8 and turn on the LED.

Main ~gen patch:

Sum gen patch:

Any thoughts, feedback, or ideas to help this type of thing work would be greatly appreciated.


Try removing “param leds” from the subpatcher (this will confuse gen~ – is leds a param or a data? it shoudl be a data.)

Also remove the “setparam leds” from the top-level patcher, since they only work with param, and we’re working with a data here.

The [data leds] should be already in global namespace from the top-level, so the subpatcher pokes should find it.

Sweet, thanks!

Very helpful and much appreciated.