FreeCalypso > hg > fc-small-hw
diff mmtb1/schem+bom/vsrc/led_circuit.v @ 0:0f9bdd60ce50
fc-small-hw separated from old freecalypso-schem repo
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Mon, 21 Oct 2019 00:53:38 +0000 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mmtb1/schem+bom/vsrc/led_circuit.v Mon Oct 21 00:53:38 2019 +0000 @@ -0,0 +1,17 @@ +/* + * This module captures the circuit for showing the state of a digital signal + * on a LED without loading that digital signal by driving the LED from VBAT + * and using a MOSFET to control it. + */ + +module led_circuit (GND, VBAT, Signal); + +input GND, VBAT, Signal; + +wire R_to_LED, LED_to_Q; + +resistor R (VBAT, R_to_LED); +diode led (.A(R_to_LED), .C(LED_to_Q)); +mosfet Q (.G(Signal), .S(GND), .D(LED_to_Q)); + +endmodule