Skip to content

File wfm_defaults.h

File List > inc > wfm > wfm_defaults.h

Go to the documentation of this file

/*
 * wfm_defaults.h — GENERATED by scripts/gen_wfm_defaults.py
 *
 * Do not edit. `just-makeit.toml` is the one declaration of a
 * default; this is that declaration rendered for C, so the CLI, a
 * C caller and Python cannot disagree about one (doppler#1142).
 *
 * Only NON-ZERO defaults appear: a zero is what a zero-initialised
 * struct already gives, and spelling it would say nothing.
 *
 * An enum-valued default is rendered as the index of its name in
 * the field's OWN declared [[enum]], with the name in a comment, so
 * reordering that enum moves this file rather than silently
 * changing what the value means.
 */
#ifndef WFM_DEFAULTS_H
#define WFM_DEFAULTS_H

/* Non-zero defaults for a wfm_source_t. */
#define WFM_SOURCE_DEFAULTS \
  { \
    .snr = 100.0, \
    .sps = 1, \
    .pn_length = 15, \
    .modulation = 1 /* bitmod: bpsk */, \
    .rrc_beta = 0.35, \
    .rrc_span = 8, \
    .acq_reps = 1, \
    .crc = 1 /* crc: crc16 */ \
  }

/* Non-zero defaults for a wfm_segment_t. */
#define WFM_SEGMENT_DEFAULTS \
  { \
    .fs = 1.0, \
    .num_samples = 1024, \
    .repeats = 1 \
  }

#endif /* WFM_DEFAULTS_H */