Returns the index which is enabled
()
| 78 | |
| 79 | // Returns the index which is enabled |
| 80 | func (d *Decoder3x8) Index() int { |
| 81 | for i := range d.outputs { |
| 82 | if d.outputs[i].Get() { |
| 83 | return i |
| 84 | } |
| 85 | } |
| 86 | |
| 87 | return 0 |
| 88 | } |
| 89 | |
| 90 | func (d *Decoder3x8) Update(inputA, inputB, inputC bool) { |
| 91 | d.inputA.Update(inputA) |