FPGA DAC control
A simple manual control interface for the FPGA: 16 DAC voltages and 32 TTL bitmask settings.
Overview
quatm/GUI/entries/fpga_controller.py provides simple manual FPGA control for debugging and
calibration: each DAC voltage is set with a labelled -10 … +10 V spin box, and the 32 TTL outputs
are set with a grid of checkboxes.
Components
| Component | Description |
|---|---|
dacv(v) | Converts -10..+10 V into the 16-bit raw DAC code used by the FPGA |
DACsingle | A single DAC channel: a labelled -10..+10 V spin box, effective as soon as it is written |
DACvalues | All 16 DAC channels stacked vertically |
TTLQW | The 32 TTL outputs: an 8×4 grid of checkboxes, written as a single 32-bit mask |
simple_page | The DAC + TTL manual control page |
centralWidget / mainQMW | Tab container and simple main window (with a File/quit menu) |
Usage
from quatm.GUI.entries.fpga_controller import DACvalues, TTLQW
# obtain the low-level FPGA driver handle (controller) from the device database
page = DACvalues(controller)
# TTL: checkbox states are combined into a mask by the "Apply/state change" callback and written to the FPGA
ttl = TTLQW(controller)
If the hardware is missing or a write fails, it only prints an error instead of crashing, which makes the interface easy to debug without hardware.