How lmesserstep/libresdrb210 works
Project type and purpose
• This is not a web or backend service but an FPGA-based firmware project targeting the USRP B210 (XC7A100T + AD9361).
• The README describes swapping out the stock FPGA image with a custom bitstream (usrp_b210_fpga.bin) that embodies your custom HDL design.
File structure
• Top-level Vivado project files:
• libreSDR_b210.xpr, .hw, .sim, .srcs, .gen folders, constraint files, project logs, etc.
• HDL sources under lib/… (control, dsp, fifo, gpif2, vita_200, wishbone), and a top-level wrapper in esdr_b210/top/libresdr_b210.v and b200_core.v.
• IP cores auto-generated in fifo_4k_2clk, fifo_short_2clk, gen_clks, clk_wiz_0, vio_0, etc.
README for additional insights
• Purpose: build and load a custom FPGA image for UHD (USRP Hardware Driver).
Main components
a. External interfaces
• AD9361 analog RF front-end (RX/TX ADC & DAC)
• USB3 (GPIF2 or other) host interface to PC running UHD
• I²C EEPROM (configuration store)
• JTAG / VIO for debug
b. Clock and reset infrastructure
• MMCM / PLL (gen_clks, clk_wiz_0) generating reference clocks
• Reset synchronizers
c. Control plane
• Wishbone or simple SPI control logic for register access (user_settings.v, serial_to_settings.v)
• uC-style control block in b200_core.v
d. Data plane (two symmetric paths)
• RX path: ADC → CIC decimator → DDC chain (cordic, down-conversion) → VITA-49 framer → AXI-FIFO → USB
• TX path: USB → AXI-FIFO → VITA-49 deframer → DUC chain → DAC
e. Clock-domain crossing
• FIFO IP cores (fifo_4k_2clk, fifo_short_2clk) between RF clock, processing clock, and USB clock domains
f. Miscellaneous IP and user modules
• AES-FPGA (for encryption/decryption tests)
• I²C EEPROM model for simulation
• DSP primitives (add, clip, round, MAC, decimator, interpolator)
Relationships and interactions
• Within FPGA, group blocks by clock domain (e.g., RF domain on left, processing domain in center, USB domain on right).
Architectural patterns and design principles
• Modular HDL library structure (lib/dsp, lib/control, lib/fifo, etc.)
• Clear separation of control vs. data planes.
• Pipeline and streaming design using AXI-stream-style FIFOs.
• Clock-domain crossing handled by parameterized FIFO IP.
• Top-level composition in esdr_b210/top/libresdr_b210.v.
Technologies, frameworks, and libraries
• Xilinx Vivado IP integrator for clocking, FIFOs, VIO.
• Verilog/VHDL sources under lib/…
• SSDR packet format via VITA-49 modules under lib/vita_200.
• Simulation scripts under libresdr_b210.sim.
Essential architectural elements
• Do not merely list files – show how FIFO blocks link processing pipelines across clock domains.
• Top-level wrapper module and how it instantiates core submodules.
• Path from PC⟶USB⟶AXI-FIFO⟶DDC⟶RF and bidirectional for TX.
• AD9361 DEVICE interface, I²C config chain, and system clocks feeding all sub-blocks.