Research-Stack/4-Infrastructure/hardware/q16_lut_top.v
Brandon Schneider a3b298230b feat: wire pipeline into VCN substrate + FPGA bitstream for Q16 LUT
Pipeline wiring:
- vcn_compute_substrate.py: Delta+RLE → RS ECC → ChaCha20 now in live path
- encode_braid_strand/crossing/mountain_merge accept key + compress params
- New CLI: encode_enhanced/decode_enhanced for full pipeline
- 67/67 tests pass

FPGA synthesis:
- q16_lut_core → Tang Nano 9K (GW1NR-9C)
- 266 LUTs, 68 FFs, 2 DSPs, 1 BRAM
- 3.4MB bitstream (q16_lut_top.fs)
- Constraint file + build script + wrapper module
2026-05-28 15:02:13 -05:00

28 lines
725 B
Verilog

// Wrapper for q16_lut_core that maps valid to result[31]
// This reduces the pin count to fit the Tang Nano 9K
module q16_lut_top (
input wire clk,
input wire rst,
input wire [2:0] op_select,
input wire [15:0] a,
input wire [15:0] b,
output wire [31:0] result
);
wire [31:0] core_result;
wire core_valid;
q16_lut_core u_core (
.clk (clk),
.rst (rst),
.op_select (op_select),
.a (a),
.b (b),
.result (core_result),
.valid (core_valid)
);
// Map valid into result[31] bit for external observation
assign result = {core_valid, core_result[30:0]};
endmodule