view venus/src/periph/bl_current_select.v @ 96:ae6951a70d2b

U403: change from 74LVC2G125 to 74LVC2G126 The two parts have the same footprint and pinout, but '126 3-state buffers have active-high OE inputs instead of active-low. The change is purely for software benefit: having GPIO 11/12 set to 1 correspond to that current contribution being enabled will be much more intuitive for developers and tinkerers.
author Mychaela Falconia <falcon@freecalypso.org>
date Mon, 09 May 2022 19:27:11 +0000
parents 9f5a3567d699
children
line wrap: on
line source

module bl_current_select (GND, Vio, BL_GPIO11, BL_GPIO12, SET);

input GND, Vio;
input BL_GPIO11, BL_GPIO12;
output SET;

wire buf_out_GPIO11, buf_out_GPIO12;

/* U403 buffer common part */
logic_ic_common U403_common (.Vcc(Vio), .GND(GND));

/* bypass capacitor */
capacitor U403_bypass (Vio, GND);

/* buffer slots */
buffer_slot_3state buf_GPIO11 (.A(Vio), .nOE(BL_GPIO11), .Y(buf_out_GPIO11));
buffer_slot_3state buf_GPIO12 (.A(Vio), .nOE(BL_GPIO12), .Y(buf_out_GPIO12));

/* MAX1916 current control resistors */
resistor R_fixed  (Vio, SET);
resistor R_GPIO11 (buf_out_GPIO11, SET);
resistor R_GPIO12 (buf_out_GPIO12, SET);

endmodule