2.1.1.2 NAND Gate

To get a HIGH(1) output from a NAND gate, one or more of the inputs must be LOW(0). If all inputs are HIGH(1), the output will be LOW(0). Looking at the truth table, all except TRUTH[7] fulfill this requirement. This means that TRUTH[0] to TRUTH[6] must be HIGH(1) and TRUTH[7] must be LOW(0), giving the hex value 0x7F to put into the TRUTHn register.

Figure 2-4. NAND Gate