Diseño de ALU de 4 Bits
flux
Started implementing a plan
#Goal
- Implement a 4-bit Adder/Subtractor RTL block at 5 V using 2N2222A transistors on a single-sided PCB with jumpers. Expose Arduino test headers and probe points for inputs (A[3:0], B[3:0], SUB) and outputs (SUM[3:0], Carry, Zero, Overflow, and optionally Sign) as per the project context and provided RTL gate templates. This block will handle addition/subtraction operations, with subtraction performed by applying XOR on B inputs using the SUB control and setting Cin0 to SUB.
#Implementation plan
1. **RTL Cell Placement and Annotation**
1. Place RTL cells using 2N2222A NPN transistors and resistors, following provided RTL gate templates for basic logic functions (INV, AND, OR, XOR).
2. Annotate all RTL cells with their respective functions.
2. **1-Bit Full Adder Construction**
1. Build a 1-bit full adder using the annotated RTL cells.
2. Chain four 1-bit adders to form the 4-bit Adder/Subtractor, ensuring proper connection for A0–A3, B0–B3, and carry propagation (C0 to C4).
3. Implement subtraction by wiring B inputs through XOR gates with the SUB signal and setting the initial carry (Cin0) to the SUB control signal.
3. **Flag Generation and Output Headers**
1. Generate flags based on the adder outputs: Carry (C4), Zero (using a NOR network on S0, S1, S2, S3), Overflow (C3 XOR C4), and optionally Sign (S3).
2. Expose these flags on dedicated header pins.
3. Place Arduino test headers for A[3:0], B[3:0], SUB, SUM[3:0], and flags (C, Z, V, N) along with designated timing probe pads.
4. **PCB Layout Design**
1. Ensure the block is implemented on a single-sided PCB with jumpers, meeting the size constraints (120–150 cm²).
2. Prepare dedicated 5 V and GND rails for the block.
3. Partition and label the Adder/Subtractor region in the layout.
#Success criteria
- Successful implementation of the RTL 4-bit Adder/Subtractor circuit with proper RTL gate cell placements.
- Correct chaining of 1-bit full adders, with dedicated wiring for addition and subtraction modes.
- Proper generation and output of flags (Carry, Zero, Overflow, optionally Sign) and exposed test headers for Arduino and probe points.
- Layout satisfies single-sided PCB design criteria with jumpers and defined 5 V/GND rails.
Working on your request...
0:13
Task unable_to_complete.
4:15
flux
flux
flux
Flux stopped