my solution for primaries: 4 buttons, of the first 3, each one activates/deactivates a bank when pressed, the fourth toggles between banks in a cycle from top to bottom and to all three before going back to the first bank. Use of the fourth button automatically diactivates 2 and 3 and activates 1 on the first stroke. So if you have banks 1 and 3 enabled, you press the fourth button once, only the 1st bank is now enabled, press it again and only the second is, press it again only the third, press it a fourth time and 1 2 and 3 are all enabled, press it a fifth time and you're back to just 1. From any of these, you can activate or deactivate using the other 3 keys.
How to implement this i have no idea.