Hello, it is quite clear to me how to use an op-amp in inverting mode, to get 0 or -5V with a 0 or +5V input and, as well, it is clear how to get 0 or +5V with a 0 or +5V input with noninverting mode. It is also clear how to get, for instance, -12V or +12V output with the appropriate supply and the correct resistors but my need is to achieve both functions simultaneously. I.E. I need to generate an output of +12V, 0V and -12V, presumably using TWO input wires (A, B) that can be 0V or +5V. I am pretty sure I can do this: A=0V B=0V out = 0V, A=5V B=0V out=+12V, A=0V B=5V out=-12V (A=5V B=5V undefined) but I cannot figure how. Can someone give a suggestion? Thanks