6 lines driven by 3 wires.
(here is improved version: https://everycircuit.com/circuit/5492142679785472)
The schema is developed to work with some controllers (Arduino-like). By default, left terminals have level 1, right terminals have level 0.
Turning on some line is a combination of one 0 on the left side and one 1 on the right side.
Only one 0 is allowed on left terminals and one 1 on right terminals simultaneously.
For:
aa
bb
cc
only following combinations allowed:
aB, aC, bA, bC, cA, cB