Main controls - voxo22/hackrf-spectrum-analyzer GitHub Wiki

Frequency selector

The Frequency selector consists of a pair of fields Frequency start [MHz] and Frequency stop [MHz]. They show the current start and end of the frequency range. The + and - buttons above and below each digit allow you to set the units, tens, hundreds and thousands sequentially. The minimum lower frequency (start) is 0 MHz and the maximum upper frequency (stop) is 7250 MHz. The minimum range of the frequency spectrum is 1 MHz.

Arrow buttons (<-- -->)

Arrow buttons allow you to conveniently step through the spectrum. Each key press moves the frequency range backward - forward to set the new previous or next frequency range. 10% overlap preserves partial frequency ranges at the boundaries, so that you do not miss these frequencies. The function of these arrow buttons corresponds to the function of keyboard arrow keys, when spectrum chart is mouse focused.

Frequency presets

Frequency presets is a fully customizable menu of preset frequency ranges with descriptions. The content is loaded from the presets.csv file in the root directory, where the spectrum analyzer executable .jar file is also located. The presets.csv file has the following format (e.g.):

Preset Name; Freq Min; Freq Max; RBW; Freq Shift; Amplitude Offset
AM radio w/ SpyVerter;0;26;10;-120;7
CB radio;26;28;3;0;5
FM radio;88;108;20;0;3
DAB+;174;240;50;0;2
ISM 433;431;435;3;0;12
DVB-T;470;694;200;0;-5
ISM 868;863;870;3;0;12
DECT;1880;1900;10;0;5
Wi-Fi 2.4 / Bluetooth;2400;2483;100;0;-1
SAT TV LNB low;10700;11700;1000;9750;-10

You can set your own preset by simply adding new line between or after other ones. Semicolon is the field delimiter. Specify custom preset name, frequency start, frequency end, resolution bandwidth (see options), frequency shift in case of use up-/down-converter (see options) and amplitude offset (in dBm) to maintain idle amplitude line at desired level, e.g. -100 dBm.

HW status line

The status line shows the current status of the hackRF. If its presence is detected by the spectrum analyzer (hackRF is connected to the computer, or PortaPack is in HackRF mode), it shows "HW connected". Otherwise, it shows "HW disconnected".

Pause button (⏸ ►)

The Pause/Play button stops/starts the spectrum scan. After pressing Pause, the screen remains frozen with the data from the last scan.

VIDEO recording button

The VIDEO button starts/stops recording the spectrum analyzer screen to a video file. Since the image data can be very large, it uses compression either to MPEG4 (H.264) format or to GIF animated format. The format, screen resolution, number of frames per second and a specific area of the screen can be adjusted on the Waterfall/REC tab. You can record only spectrum area, or spectrum with waterfall, or the full screen, incl. control panel. Note: during recording, the screen can be resized or restyled to achieve the optimal conditions. This is normal. After recording, you can resize the screen back to your needs.

The video file is saved into the root dir. Name of the file has the following format:

# <video area> <start_freq>-<stop_freq> MHz <date> <time>.<gif/mp4>

Note: the GIF format is more suitable for small, a few-second recordings, for publishing e.g. on websites. The GIF format preserves the original color of the image, usually automatically plays endlessly and you can publish it as a regular image. However, the file has large size after a few seconds and the spectrum analyzer saves it sequentially to the buffer. Therefore, do not use GIF for several-minute or hour-long recordings, the buffer may overflow and the system may crash.

Warning: even after turning off the recording to GIF, it may take a while before the file is accessible (the buffer must be completely flushed to the file).

DATA recording button

The DATA button starts/stops recording the PEAK curve summary parameters to a CSV file. You can adjust record interval on the Waterfall/REC tab (once per minute, once per second, once per fraction of second).

The file has following content (e.g. once per second):

Timestamp, Total Spectrum Power [dBm], Power Flux Density [µW/m²], Max Amplitude [dBm], Frequency [MHz]
2025-04-20 11:19:16,-60.1,12.0,-68.3,951.80
2025-04-20 11:19:17,-59.6,14.0,-66.2,951.80
2025-04-20 11:19:18,-59.9,13.0,-67.8,951.80
2025-04-20 11:19:19,-60.0,13.0,-68.2,951.75

Note: Power Flux Density value is based on PEAK curve calculations and Power Calibration (see SCAN tab). Max Amplitude represents the value for the entire displayed spectrum and refers to the next Frequency parameter. All these data is also displayed continuously on the information panel.

The CSV file is saved into the root dir. Name of the file has the following format:

# DATA <start_freq>-<stop_freq> MHz <date> <time>.csv

The CSV file can then be easily imported into a spreadsheet or other commercial web-based statistical analyzer/plotter.

Note: As all the information is obtained from the PEAK curve, turning off the PEAK curve in control panel also disables DATA recording feature and DATA button disappears.

⚠️ **GitHub.com Fallback** ⚠️