Skip to content

Struct dll_state_t

ClassList > dll_state_t

DLL state. More...

  • #include <dll_core.h>

Public Attributes

Type Name
float _Complex acc_e
float _Complex acc_l
float _Complex acc_o
float _Complex acc_p
double aid_alpha
size_t aid_best
uint64_t aid_count
uint64_t aid_last_end
size_t aid_len
size_t aid_nhyp
double * aid_power
size_t aid_ring
float _Complex * aid_ring_e
float _Complex * aid_ring_l
float _Complex * aid_ring_o
float _Complex * aid_ring_p
double bn
double chip_pos
float _Complex * chunk_e
float _Complex * chunk_l
float _Complex * chunk_p
const uint8_t * code
nco_state_t code_nco
double code_rate
int have_prev_epoch
double inv_sps
double inv_tsamps
double inv_tsamps2
double inv_tsamps_sf
double inv_upd
float _Complex * last_backward_p
float _Complex * last_e
double last_error
float _Complex * last_l
loop_filter_state_t lf
lockdet_state_t lock
double lock_alpha
size_t lock_count
size_t lock_nz
double lock_stat
double lock_sum
size_t n_looks
double noise_ema
double noise_guard
double off_chips
int owns_code
double rate_aid
uint32_t rng
double seed_chip
double seg_chips
size_t seg_idx
double seg_norm
size_t segments
size_t sf
double spacing
size_t sps
float _Complex * sums
double sym_period
dll_tlm_t tlm
double zeta

Detailed Description

Allocate with dll_create() (copies the code), or embed by value and dll_init() (borrows the caller's code). The loop filter lf is a public sub-component so the inline composition helpers can drive it; treat the correlator accumulators and code-phase fields as internal.

Public Attributes Documentation

variable acc_e

float _Complex dll_state_t::acc_e;

early correlator accumulator.


variable acc_l

float _Complex dll_state_t::acc_l;

late correlator accumulator.


variable acc_o

float _Complex dll_state_t::acc_o;

offset (noise) correlator accumulator.


variable acc_p

float _Complex dll_state_t::acc_p;

prompt correlator accumulator.


variable aid_alpha

double dll_state_t::aid_alpha;

EMA over symbols of each window's power.


variable aid_best

size_t dll_state_t::aid_best;

current best hypothesis (the timing).


variable aid_count

uint64_t dll_state_t::aid_count;

partials seen since enable (ring index).


variable aid_last_end

uint64_t dll_state_t::aid_last_end;

one past the last look's last partial; the next look's window must start there or later, so no two looks share noise (the best hypothesis flips between overlapping neighbours on noise, #1264).


variable aid_len

size_t dll_state_t::aid_len;

coherent window length L, partials.


variable aid_nhyp

size_t dll_state_t::aid_nhyp;

boundary-phase hypotheses Q = ceil(P).


variable aid_power

double* dll_state_t::aid_power;

per-hypothesis window-power EMA (Q).


variable aid_ring

size_t dll_state_t::aid_ring;

ring capacity, partials (power of two).


variable aid_ring_e

float _Complex* dll_state_t::aid_ring_e;

last aid_ring early partials.


variable aid_ring_l

float _Complex* dll_state_t::aid_ring_l;

last aid_ring late partials.


variable aid_ring_o

float _Complex* dll_state_t::aid_ring_o;

last aid_ring offset (noise) partials.


variable aid_ring_p

float _Complex* dll_state_t::aid_ring_p;

last aid_ring partial prompts.


variable bn

double dll_state_t::bn;

loop noise bandwidth (retained).


variable chip_pos

double dll_state_t::chip_pos;

current prompt code phase, chips; DERIVED from code_nco.phase on every dll_accumulate, never independently accumulated.


variable chunk_e

float _Complex* dll_state_t::chunk_e;

this epoch's per-chunk early sums.


variable chunk_l

float _Complex* dll_state_t::chunk_l;

this epoch's per-chunk late sums.


variable chunk_p

float _Complex* dll_state_t::chunk_p;

this epoch's per-chunk prompt sums; Python's partial_sums.


variable code

const uint8_t* dll_state_t::code;

spreading code, one period (0/1 chips).


variable code_nco

nco_state_t dll_state_t::code_nco;

fixed-point code-phase NCO (phase/phase_inc).


variable code_rate

double dll_state_t::code_rate;

chips advanced per nominal chip (~1.0).


variable have_prev_epoch

int dll_state_t::have_prev_epoch;

0 until one full epoch has completed.


variable inv_sps

double dll_state_t::inv_sps;

1 / sps (per-sample chip advance scale).


variable inv_tsamps

double dll_state_t::inv_tsamps;

1 / (sf*sps) the nominal phase_inc, cycles/sample; precomputed once (sf/sps are create-time invariants) so the tracking loop never divides by tsamps.


variable inv_tsamps2

double dll_state_t::inv_tsamps2;

1 / (sf*sps)^2 segments>1's ctrl scale.


variable inv_tsamps_sf

double dll_state_t::inv_tsamps_sf;

1 / (sf*sps*sf) segments<=1's kp*e/(sf) ctrl term's scale.


variable inv_upd

double dll_state_t::inv_upd;

1 / lf.t: one over the loop's update interval in epochs (1 per epoch; the symbol period in epochs once the aid is on). The filter's output is a correction per update; this turns it into the rate held over the interval. Precomputed with the gains, never in the loop.


variable last_backward_p

float _Complex* dll_state_t::last_backward_p;

prev epoch's reversed-cumsum prompt; Python's backward_sums, saved from the PREVIOUS epoch's call.


variable last_e

float _Complex* dll_state_t::last_e;

prev epoch's per-chunk early sums.


variable last_error

double dll_state_t::last_error;

last discriminator output (loop stress).


variable last_l

float _Complex* dll_state_t::last_l;

prev epoch's per-chunk late sums.


variable lf

loop_filter_state_t dll_state_t::lf;

2nd-order code PI loop.


variable lock

lockdet_state_t dll_state_t::lock;

decision rule: thresholds + verify counters stepped on R at each N-look decision.


variable lock_alpha

double dll_state_t::lock_alpha;

EMA coefficient 1/L_eff (L_eff >> n_looks).


variable lock_count

size_t dll_state_t::lock_count;

looks accumulated in the current window.


variable lock_nz

size_t dll_state_t::lock_nz;

noise looks folded in (cumulative-mean boot).


variable lock_stat

double dll_state_t::lock_stat;

last statistic R = sqrt(2 sum|P|^2/E|O|^2).


variable lock_sum

double dll_state_t::lock_sum;

running sum|P_k|^2 over the current window.


variable n_looks

size_t dll_state_t::n_looks;

non-coherent integration depth N.


variable noise_ema

double dll_state_t::noise_ema;

EMA of offset power; estimates E|O|^2.


variable noise_guard

double dll_state_t::noise_guard;

chips around P/E/L the offset must avoid.


variable off_chips

double dll_state_t::off_chips;

this look's offset code phase, whole chips.


variable owns_code

int dll_state_t::owns_code;

1 if dll_destroy() frees code.


variable rate_aid

double dll_state_t::rate_aid;

carrier-aiding code-rate deviation (ratio, 0 = off): a fixed fractional bias summed into the sample-and-hold phase_inc every epoch, on top of the loop's own ctrl. For physically-coupled Doppler, the caller sets this to carrier_offset/carrier_freq so the code NCO rides the code-rate dilation the code discriminator alone can't pull in at low SNR. See dll_set_rate_aid().


variable rng

uint32_t dll_state_t::rng;

xorshift32 state for the random offset.


variable seed_chip

double dll_state_t::seed_chip;

create-time code phase, for reset.


variable seg_chips

double dll_state_t::seg_chips;

code phase per partial segment = sf/segments.


variable seg_idx

size_t dll_state_t::seg_idx;

samples integrated into the current chunk.


variable seg_norm

double dll_state_t::seg_norm;

nominal samples per segment (prompt scale).


variable segments

size_t dll_state_t::segments;

partial correlations per epoch (1 = full).


variable sf

size_t dll_state_t::sf;

code length (chips per period).


variable spacing

double dll_state_t::spacing;

early/late tap offset, chips (e.g. 0.5).


variable sps

size_t dll_state_t::sps;

samples per chip.


variable sums

float _Complex* dll_state_t::sums;

this epoch's running cumulative sum of chunk_p; Python's partial_sums .cumsum(). Pure scratch (rebuilt every epoch boundary, never read across calls) not part of the serialized state.


variable sym_period

double dll_state_t::sym_period;

data-symbol period, partials (0 = off).


variable tlm

dll_tlm_t dll_state_t::tlm;

live telemetry attachment; zeroed in blobs


variable zeta

double dll_state_t::zeta;

damping factor (retained).



The documentation for this class was generated from the following file native/inc/dll/dll_core.h