Waveform generation
Turns text, demo frames, or a prebuilt OCT binary frame into binary or Manchester OOK samples and streams a cyclic IQ buffer to the AD9172.
Python DSP | AD9172 DAC | AD9213 ADC | libiio
Desktop transmitter and receiver applications that generate, stream, capture, and decode On-Off Keying signals on real Analog Devices high-speed data converters, with every intermediate DSP stage plotted live.
Demo
The recording shows the TX GUI streaming a Manchester-coded, framed OOK waveform to the AD9172 DAC while the RX GUI captures from the AD9213 ADC, recovers timing, and decodes frames with passing CRC checks.
TX GUI (left) driving the AD9172 and RX GUI (right) showing raw RF samples, the Hilbert envelope, Gardner-recovered samples, decoded bits, the eye diagram, and recovered frames.
Manchester-coded frame transmitted through the AD9172 and recovered on the AD9213. The receiver table shows frames passing CRC, and one corrupted frame flagged BAD, which confirms the CRC check catches bit errors.
Overview
The project connects a Python DSP workflow to AD9172 DAC and AD9213 ADC hardware through the Industrial I/O (IIO) interface. Separate transmitter and receiver GUIs expose the key link parameters, which makes the tool useful for lab testing, algorithm demonstrations, and link debugging.
Turns text, demo frames, or a prebuilt OCT binary frame into binary or Manchester OOK samples and streams a cyclic IQ buffer to the AD9172.
Captures raw AD9213 samples, strips the RF carrier with envelope detection, runs Gardner timing recovery, and reconstructs frames.
Plots raw RF, envelope, recovered clock, bits, and a live eye diagram, and exports CSV vectors for each processing block.
Signal Processing Chain
Encoded frame with preamble, sync word, length, sequence, payload, and CRC regions, plus the DAC I-buffer ready for cyclic transmission.
Raw ADC samples, Hilbert envelope, Gardner 2-SPS output, recovered bits, eye diagram, and a table of decoded frames with CRC status.
TX data -> framing or raw OCT-frame input -> binary/Manchester line coding -> OOK symbol mapping -> upsampling and pulse shaping -> interleaved I/Q samples -> AD9172 DAC AD9213 ADC -> raw sample decoding -> Hilbert-envelope detection -> normalization and resampling to 2 SPS -> Gardner clock recovery -> threshold decision -> binary/Manchester decoding -> preamble synchronization -> recovered frame bytes
Features
Binary and IEEE Manchester coding with rectangular, NRZ, raised-cosine, and root-raised-cosine pulses.
Cyclic IQ transmission with iio_writedev, plus DAC DDS and NCO setup through IIO attributes.
AD9213 sample capture with iio_readdev, feeding the receive DSP chain directly.
OptiCommPy Gardner clock recovery at two samples per symbol with automatic timing-phase selection.
Demo frames with preamble, sync word, sequence number, and CRC16, synchronized and validated on receive.
CSV export of the signal at each processing block for offline analysis and debugging.
Raw OCT-Frame Transport
The TX can load a prebuilt OCT physical frame from a binary file and OOK-modulate it without rebuilding its header, FEC, payload, or CRC. The RX uses Gardner recovery and OCT-preamble synchronization to recover a fixed number of bytes and writes the complete frame back to a binary file.
9472 bits per uncoded OCT frame.
368.64 MSPS TX sample rate at 64 samples per bit.
8,388,608-sample RX capture recommended for cyclic alignment.
Outcome
The project covers frame handling, waveform generation, hardware control, ADC acquisition, DSP recovery, visual diagnostics, and byte-level validation of received data.
Discuss a Project