Skip to content

Ignored frequencies may be bypassed in some detection scenarios #134

Description

@AxisRay

Summary

auto_sdr logs show that an ignored range can be loaded correctly, but transmissions at that frequency may still be detected and recorded in some scenarios.

Environment

  • Config example:
    • ignored_frequencies: { "frequency": 439787500, "bandwidth": 12500 }

Expected behavior

If a frequency is included in ignored_frequencies, transmissions centered at that frequency should not trigger recording.

Actual behavior

auto_sdr reports the ignored range is active, but still starts recorder for 439.787.500 Hz.

Evidence from logs

From log/sdr_scanner_stdout.log:

  1. Ignored range loaded:

    • 2026-04-28 19:16:13
    • [scanner] ignored range: 439.781.250 Hz - 439.793.750 Hz
  2. Same range still recorded later:

    • 2026-04-28 19:18:09
    • [transmission] signal: 439.791.308 Hz, start: 439.787.500 Hz, ...
    • [recorder] start recorder ... frequency: 439.787.500 Hz, bandwidth: 12.500 Hz

Problem Statement

ignored_frequencies is parsed correctly, but ignore filtering is only applied to the initial candidate FFT bin (index), not the final refined bin (bestIndex).
Therefore, a signal can still be inserted and recorded if bestIndex falls into an ignored range.

Code Locations

1) Config is parsed correctly

File: sources/file_config.h

  • IgnoredFrequency is defined with frequency and bandwidth.
  • FileConfig includes ignored_frequencies.

File: sources/config.cpp

  • Config::ignoredRanges() converts each ignored frequency into a range:
    • start = frequency - bandwidth / 2
    • stop = frequency + bandwidth / 2

This confirms the config field itself is wired and used.

2) Ignore filtering is applied only to initial candidate index

File: sources/radio/blocks/transmission.cpp

In Transmission::addSignals, candidate bins are collected with:

  • !isIndexIgnored(i) (for the original i only)

So far this is correct for initial filtering.

3) Candidate is refined to bestIndex but not re-validated

File: sources/radio/blocks/transmission.cpp

Still in Transmission::addSignals:

  • const auto bestIndex = getBestIndex(index);
  • then directly:
    • m_signals.insert({bestIndex, ...});

There is no second check:

  • missing isIndexIgnored(bestIndex) before insertion.

Why It Fails

bestIndex may shift to a nearby stronger/stabler FFT bin.
Even if original index is outside ignored ranges, bestIndex can fall inside an ignored range.
Because bestIndex is not checked again, the signal is still inserted and can trigger recording.

Expected Fix

In Transmission::addSignals (sources/radio/blocks/transmission.cpp), add a second guard after computing bestIndex:

  • If isIndexIgnored(bestIndex) is true, skip insertion for this candidate.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions