Platform Features

Building an Autonomous Frequency Scanner

One of the most powerful aspects of the Mycelium framework is its ability to automate mundane, time-consuming tasks. In traditional RF testing, finding an active transmission in a wide band often requires an operator to stare at a waterfall plot for hours. With Mycelium's Directive System, we can automate this completely.

In this walkthrough, we will build a headless script that sweeps a 10 MHz block of spectrum, stops when it detects a transmission exceeding a specific power threshold, records the raw IQ data, and then resumes sweeping.

Step 1: Initializing the Scanner Tool

First, we create a tool configured with a generic `Raw` protocol and our target SDR. We'll start sweeping at 430 MHz.

Step 2: Defining the Scan Logic

Next, we instruct the tool to receive a chunk of samples. Once received, we evaluate the signal power. If it is too low (just background noise), we increment the frequency by 100 kHz. If it exceeds our threshold, we save the data.

Step 3: Logging the Hits

Finally, we need to handle the case where the signal is strong. We use the Signal_Power_GT condition combined with the Save_IQ and Report_CSV actions to document the hit.

Execution Flow

digraph { graph [bgcolor="transparent" fontname="Inter" rankdir=TB pad=0.4] node [fontname="Inter" fontsize=12 fontcolor="#e2e8f0" style=filled fillcolor="#1a1033" color="#8b5cf6" penwidth=1.5 margin="0.2,0.15" shape=box] edge [color="#8b5cf6" fontcolor="#a78bfa" fontname="Inter" fontsize=10 arrowsize=0.8] start [label="Start: 430 MHz" shape=ellipse] receive [label="Receive 100,000 IQ Samples"] power [label="Signal Power > 0.1?" shape=diamond fillcolor="#2d1b69"] save [label="Save IQ to File"] log [label="Log Metadata to CSV"] freq_check [label="Frequency > 440 MHz?" shape=diamond fillcolor="#2d1b69"] reset [label="Reset Freq to 430 MHz"] increment [label="Increment Freq by 100 kHz"] start -> receive -> power power -> save [label="Yes"] power -> freq_check [label="No"] save -> log -> freq_check freq_check -> reset [label="Yes"] freq_check -> increment [label="No"] reset -> receive increment -> receive }

Execution

With those five directives loaded, simply type execute. The `auto_scanner` tool will continuously pull in samples, evaluate them, step the frequency, and save off any spikes it finds into neatly organized, timestamped files.

This entire process happens autonomously, allowing the engineer to focus on analyzing the captured IQ data rather than babysitting the spectrum analyzer.



← Back to Blog