pluto-siege 2.0.3__tar.gz → 2.1.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- pluto_siege-2.1.1/PKG-INFO +206 -0
- pluto_siege-2.1.1/README.md +184 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/__init__.py +1 -19
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/__main__.py +1 -1
- pluto_siege-2.1.1/pluto_siege/cli.py +1407 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/config.py +139 -62
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/constants.py +22 -11
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/device.py +160 -19
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/engine.py +313 -37
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/gps.py +23 -1
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/settings.py +0 -2
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/sigmf.py +41 -26
- pluto_siege-2.1.1/pluto_siege/ui/screens/capture.py +311 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/ui/screens/loopback.py +5 -2
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/ui/screens/main_menu.py +121 -51
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/ui/screens/settings.py +259 -141
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/ui/screens/transmit.py +62 -22
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/ui/widgets/framework.py +130 -127
- pluto_siege-2.1.1/pluto_siege.egg-info/PKG-INFO +206 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege.egg-info/SOURCES.txt +1 -0
- pluto_siege-2.1.1/pluto_siege.egg-info/entry_points.txt +2 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pyproject.toml +4 -5
- pluto_siege-2.1.1/tests/test_config.py +398 -0
- pluto_siege-2.1.1/tests/test_engine_and_ui.py +907 -0
- pluto_siege-2.1.1/tests/test_gps.py +214 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/tests/test_sigmf.py +41 -5
- pluto_siege-2.0.3/PKG-INFO +0 -187
- pluto_siege-2.0.3/README.md +0 -165
- pluto_siege-2.0.3/pluto_siege/ui/screens/capture.py +0 -226
- pluto_siege-2.0.3/pluto_siege.egg-info/PKG-INFO +0 -187
- pluto_siege-2.0.3/pluto_siege.egg-info/entry_points.txt +0 -2
- pluto_siege-2.0.3/tests/test_config.py +0 -92
- pluto_siege-2.0.3/tests/test_engine_and_ui.py +0 -306
- pluto_siege-2.0.3/tests/test_gps.py +0 -102
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/LICENSE +0 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/dsp.py +0 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/sound.py +0 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/ui/__init__.py +0 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/ui/screens/__init__.py +0 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege/ui/widgets/__init__.py +0 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege.egg-info/dependency_links.txt +0 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege.egg-info/requires.txt +0 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/pluto_siege.egg-info/top_level.txt +0 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/setup.cfg +0 -0
- {pluto_siege-2.0.3 → pluto_siege-2.1.1}/tests/test_dsp.py +0 -0
|
@@ -0,0 +1,206 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: pluto_siege
|
|
3
|
+
Version: 2.1.1
|
|
4
|
+
Summary: RF Capture & Replay Tool for PlutoSDR
|
|
5
|
+
Author: SketchTurnerDev
|
|
6
|
+
License-Expression: GPL-3.0-or-later
|
|
7
|
+
Project-URL: Homepage, https://github.com/SketchTurnerDev/pluto_siege
|
|
8
|
+
Project-URL: Repository, https://github.com/SketchTurnerDev/pluto_siege.git
|
|
9
|
+
Project-URL: Issues, https://github.com/SketchTurnerDev/pluto_siege/issues
|
|
10
|
+
Keywords: 433mhz,868mhz,adalm-pluto,ham-radio,pentesting,pluto-sdr,pluto-siege,plutosdr,plutosiege,python,radio-frequency,red-team,rf-hacking,sdr,security-tools,sigmf,subghz,wireless,wireless-security
|
|
11
|
+
Classifier: Programming Language :: Python :: 3
|
|
12
|
+
Classifier: Operating System :: POSIX :: Linux
|
|
13
|
+
Classifier: Environment :: Console :: Curses
|
|
14
|
+
Classifier: Topic :: Communications :: Ham Radio
|
|
15
|
+
Requires-Python: >=3.9
|
|
16
|
+
Description-Content-Type: text/markdown
|
|
17
|
+
License-File: LICENSE
|
|
18
|
+
Requires-Dist: pyadi-iio>=0.0.16
|
|
19
|
+
Requires-Dist: pylibiio<1.0
|
|
20
|
+
Requires-Dist: numpy>=1.20.0
|
|
21
|
+
Dynamic: license-file
|
|
22
|
+
|
|
23
|
+
<h1 align="center">PlutoSiege</h1>
|
|
24
|
+
|
|
25
|
+
<p align="center">
|
|
26
|
+
<strong>RF Capture & Replay Tool for PlutoSDR</strong>
|
|
27
|
+
</p>
|
|
28
|
+
|
|
29
|
+
<p align="center">
|
|
30
|
+
<a href="https://pypi.org/project/pluto-siege/"><img src="https://img.shields.io/pypi/v/pluto-siege?style=for-the-badge&logo=pypi&logoColor=white&color=blue" alt="PyPI"></a>
|
|
31
|
+
<img src="https://img.shields.io/badge/Python-3.9+-3776AB?style=for-the-badge&logo=python&logoColor=white" alt="Python">
|
|
32
|
+
<a href="https://github.com/SketchTurnerDev/pluto_siege/blob/main/LICENSE"><img src="https://img.shields.io/badge/License-GPL--3.0-blueviolet.svg?style=for-the-badge" alt="License"></a>
|
|
33
|
+
<img src="https://img.shields.io/badge/Hardware-ADALM--Pluto-0099FF?style=for-the-badge" alt="Hardware">
|
|
34
|
+
<img src="https://img.shields.io/badge/Format-SigMF-orange?style=for-the-badge" alt="SigMF">
|
|
35
|
+
</p>
|
|
36
|
+
|
|
37
|
+
<p align="center">
|
|
38
|
+
<img src="https://raw.githubusercontent.com/SketchTurnerDev/pluto_siege/main/assets/screenshot.png" alt="PlutoSiege Screenshot" width="100%">
|
|
39
|
+
</p>
|
|
40
|
+
|
|
41
|
+
> **REGULATORY DISCLAIMER**
|
|
42
|
+
> RF transmission is regulated by local authorities. Replay only signals you own or are permitted to transmit, into a dummy load or at the lowest power required.
|
|
43
|
+
|
|
44
|
+
## About
|
|
45
|
+
|
|
46
|
+
**PlutoSiege** is a terminal and command-line tool for recording and replaying short RF bursts at 433 MHz, 868 MHz, and nearby frequencies from car remotes, garage doors, doorbells, and wireless sensors.
|
|
47
|
+
|
|
48
|
+
Built for ADALM-Pluto SDR hardware, it saves captures in the standard SigMF format so recordings can be opened directly in URH, IQEngine, GNU Radio, or Inspectrum.
|
|
49
|
+
|
|
50
|
+
### Hardware Compatibility
|
|
51
|
+
Supports official Analog Devices ADALM-Pluto Rev. B and Rev. C boards as well as compatible AD9363 and AD9361 clones such as Pluto Nano, Pluto Plus, and custom PlutoSDR hardware.
|
|
52
|
+
|
|
53
|
+
## Features
|
|
54
|
+
|
|
55
|
+
- **Single & Continuous Capture**: Capture single RF bursts or enable **Auto capture** (`--auto-capture true`) to loop continuously and save numbered multi-burst recordings with collision-safe filenames.
|
|
56
|
+
- **Level Metering**: Real-time dBFS level meter with saturation (`SAT!`) warning.
|
|
57
|
+
- **Threshold Detection**: Automated noise floor estimation (with optional periodic recalibration for mobile capture) or manual threshold setting.
|
|
58
|
+
- **Pre-Trigger Buffer**: Keeps a ring buffer of history before trigger so preambles are not missed.
|
|
59
|
+
- **SigMF Format**: Saves `.sigmf-meta` and `.sigmf-data` pairs in a configurable recordings directory.
|
|
60
|
+
- **GPS Geotagging**: Records precise coordinates in SigMF metadata via `gpsd` and displays geotags during replay.
|
|
61
|
+
- **Digital Loopback Test**: Built-in internal digital BIST loopback test (at 1 GHz) to check hardware health and SNR without external antennas.
|
|
62
|
+
- **Full CLI & Headless Mode**: Launch any mode or override any setting from the command line, list available recordings, or run completely headless without curses.
|
|
63
|
+
- **Linux Native**: Built and optimized specifically for Linux environments (supports all major distribution families: Debian-based, RPM-based, Arch-based, etc.).
|
|
64
|
+
|
|
65
|
+
## Installation
|
|
66
|
+
|
|
67
|
+
### 1. System Drivers
|
|
68
|
+
Install the required IIO system drivers for your distribution family:
|
|
69
|
+
|
|
70
|
+
**Debian-based:**
|
|
71
|
+
```bash
|
|
72
|
+
sudo apt update && sudo apt install -y libiio0 libiio-dev libiio-utils
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
**RPM-based:**
|
|
76
|
+
```bash
|
|
77
|
+
sudo dnf install -y libiio python3-iio libiio-utils
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
**Arch-based:**
|
|
81
|
+
```bash
|
|
82
|
+
sudo pacman -S libiio
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
### 2. Optional: GPS Support
|
|
86
|
+
If you plan to use GPS geotagging for SigMF recordings, install the `gpsd` daemon and tools:
|
|
87
|
+
|
|
88
|
+
**Debian-based:**
|
|
89
|
+
```bash
|
|
90
|
+
sudo apt install -y gpsd gpsd-clients
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
**RPM-based:**
|
|
94
|
+
```bash
|
|
95
|
+
sudo dnf install -y gpsd gpsd-clients
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
**Arch-based:**
|
|
99
|
+
```bash
|
|
100
|
+
sudo pacman -S gpsd
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
> **Note:** Configure and start the `gpsd` service according to your specific GPS receiver hardware (USB dongle, UART module, Bluetooth, or virtual source) so that it listens on `127.0.0.1:2947`. Once running, enable GPS in PlutoSiege **Settings** (`Enable GPS (gpsd): yes`) or via CLI (`--enable-gps true`).
|
|
104
|
+
|
|
105
|
+
### 3. Install & Run PlutoSiege
|
|
106
|
+
|
|
107
|
+
#### Option A: Via pip / pipx (Recommended)
|
|
108
|
+
Install directly from PyPI:
|
|
109
|
+
```bash
|
|
110
|
+
pipx install pluto_siege
|
|
111
|
+
# or: pip install pluto_siege
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
Launch from any terminal:
|
|
115
|
+
```bash
|
|
116
|
+
pluto_siege
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
#### Option B: From Source
|
|
120
|
+
Clone the repository and install dependencies:
|
|
121
|
+
```bash
|
|
122
|
+
git clone https://github.com/SketchTurnerDev/pluto_siege.git
|
|
123
|
+
cd pluto_siege
|
|
124
|
+
pip install -r requirements.txt
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
Launch via the main script:
|
|
128
|
+
```bash
|
|
129
|
+
python pluto_siege.py
|
|
130
|
+
# or: python -m pluto_siege
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
## Demo
|
|
134
|
+
|
|
135
|
+
<p align="center">
|
|
136
|
+
<img src="https://raw.githubusercontent.com/SketchTurnerDev/pluto_siege/main/assets/demo.gif" alt="PlutoSiege Demo" width="100%">
|
|
137
|
+
</p>
|
|
138
|
+
|
|
139
|
+
## Application Menu
|
|
140
|
+
|
|
141
|
+
### 1. Capture
|
|
142
|
+
Listens for incoming RF bursts on the configured receiver frequency (`rx_freq`).
|
|
143
|
+
- Captures a single burst by default, or loops continuously (numbering saved bursts `[#1]`, `[#2]`, ... until stopped with `Esc` / `Q` in TUI or `Ctrl+C` in headless mode) when **Auto capture** (`--auto-capture true`) is enabled.
|
|
144
|
+
- Real-time dBFS level meter with saturation (`SAT!`) warnings.
|
|
145
|
+
- Automated noise floor estimation or manual threshold detection.
|
|
146
|
+
- Pre-trigger history ring buffer to preserve signal preambles.
|
|
147
|
+
- Saves captures as standard SigMF (`.sigmf-meta` and `.sigmf-data`) pairs with optional GPS geolocation tags.
|
|
148
|
+
|
|
149
|
+
### 2. Transmit
|
|
150
|
+
Browse and replay saved SigMF recordings from the configured recordings directory (`records_dir`).
|
|
151
|
+
- Displays recorded timestamp, center frequency, sample rate, sample count, and GPS coordinates.
|
|
152
|
+
- Replays signals via the PlutoSDR transmitter at the exact frequency (`core:frequency`) and sample rate (`core:sample_rate`) stored in `.sigmf-meta`.
|
|
153
|
+
- In-place deletion of unwanted recordings (`D` or `Delete`).
|
|
154
|
+
|
|
155
|
+
### 3. Loopback Test
|
|
156
|
+
Internal hardware diagnostic to verify the SDR transceiver and USB/DMA pipeline.
|
|
157
|
+
- Enables the AD936x internal digital BIST loopback (`loopback = 1`) at 1 GHz without transmitting over the air.
|
|
158
|
+
- Calculates received Signal-to-Noise Ratio (SNR) to confirm hardware health.
|
|
159
|
+
|
|
160
|
+
### 4. Settings & CLI Parameters
|
|
161
|
+
Configures radio parameters, trigger behavior, GPS integration, and interface preferences. All settings can be edited interactively in the TUI **Settings** screen or passed via command-line flags.
|
|
162
|
+
|
|
163
|
+
| Flags / Parameter | Type | Default | Description |
|
|
164
|
+
| :--- | :--- | :--- | :--- |
|
|
165
|
+
| `--pluto-uri`<br>`--pu` | `str` | `usb:` | PlutoSDR `libiio` context URI (`usb:`, `usb:1.4.5`, `ip:192.168.2.1`, `local:`). |
|
|
166
|
+
| `--rx-freq`<br>`--rf` | `int` | `433.92M` | Receiver center frequency in Hz; supports `k`/`M`/`G` suffixes and bare MHz shorthand (`70M - 6G`; e.g. `433`, `868`). |
|
|
167
|
+
| `--sample-rate`<br>`--sr` | `int` | `2.1M` | Sample rate in SPS; supports `k`/`M` suffixes (`521k - 61.44M`). |
|
|
168
|
+
| `--rf-bandwidth`<br>`--rb` | `int` | `0` | Analog RF filter bandwidth in Hz, or `0`/`auto` to follow `--sample-rate`; supports `k`/`M` suffixes (`0` or `200k - 56M`). |
|
|
169
|
+
| `--rx-gain`<br>`--rg` | `float` | `15.0` | Manual RX hardware gain in dB (`-10.0 .. 74.5`). |
|
|
170
|
+
| `--tx-gain`<br>`--tg` | `float` | `0.0` | Manual TX hardware gain in dB (`-89.75 .. 0.0`). |
|
|
171
|
+
| `--tx-repeats`<br>`--tr` | `int` | `1` | Number of consecutive burst transmissions per replay (`1 .. 100`). |
|
|
172
|
+
| `--auto-capture`<br>`--ac` | `bool` | `false` | Enable continuous multi-burst capture loop (`true` or `false`). |
|
|
173
|
+
| `--auto-threshold`<br>`--at` | `bool` | `true` | Enable automatic noise floor threshold detection (`true` or `false`). |
|
|
174
|
+
| `--auto-trigger-margin`<br>`--atm` | `float` | `8.0` | Trigger margin above noise floor in dB (`1.0 .. 30.0`; unused when `--auto-threshold` is `false`). |
|
|
175
|
+
| `--auto-recal-seconds`<br>`--ars` | `float` | `0.0` | Periodic noise floor recalibration interval in seconds while listening, or `0` to disable; supports `ms`/`s` suffixes (`0.0 .. 600.0`; unused when `--auto-threshold` is `false`). |
|
|
176
|
+
| `--manual-threshold`<br>`--mt` | `float` | `-30.0` | Fixed trigger threshold in dBFS (`-120.0 .. 0.0`; unused when `--auto-threshold` is `true`). |
|
|
177
|
+
| `--pre-trigger-buffers`<br>`--ptb` | `int` | `2` | Number of pre-trigger history buffers kept in memory (`1 .. 50`). |
|
|
178
|
+
| `--min-burst-seconds`<br>`--mbs` | `float` | `0.0` | Minimum active burst duration in seconds to filter short noise spikes, or `0` to disable; supports `ms`/`s` suffixes (`0.0 .. 5.0`). |
|
|
179
|
+
| `--silence-seconds`<br>`--ss` | `float` | `0.8` | Continuous silence duration in seconds to stop recording; supports `ms`/`s` suffixes (`0.01 .. 10.0`). |
|
|
180
|
+
| `--max-post-trigger-seconds`<br>`--mpts` | `float` | `4.0` | Maximum recording duration in seconds after trigger; supports `ms`/`s` suffixes (`0.1 .. 30.0`). |
|
|
181
|
+
| `--rx-buffer-size`<br>`--rbs` | `int` | `32768` | DMA receive buffer size in samples (`1024 .. 1048576`). |
|
|
182
|
+
| `--enable-gps`<br>`--eg` | `bool` | `false` | Enable GPS geolocation tagging via `gpsd` daemon (`true` or `false`). |
|
|
183
|
+
| `--gpsd-host`<br>`--gh` | `str` | `127.0.0.1` | `gpsd` daemon hostname or IP address (unused when `--enable-gps` is `false`). |
|
|
184
|
+
| `--gpsd-port`<br>`--gp` | `int` | `2947` | `gpsd` daemon TCP port (`1 .. 65535`; unused when `--enable-gps` is `false`). |
|
|
185
|
+
| `--records-dir`<br>`--rd` | `str` | `./recordings` | Directory path for saving and loading SigMF recordings (`~/.pluto_siege/recordings` when installed via `pip`/`pipx`). |
|
|
186
|
+
| `--enable-sound`<br>`--es` | `bool` | `true` | Enable acoustic sound effect cues (`true` or `false`). |
|
|
187
|
+
| `--enable-mouse`<br>`--em` | `bool` | `true` | Enable terminal mouse support in the TUI (`true` or `false`). |
|
|
188
|
+
|
|
189
|
+
### CLI-Only Options
|
|
190
|
+
|
|
191
|
+
| Flags | Description |
|
|
192
|
+
| :--- | :--- |
|
|
193
|
+
| `--capture`<br>`-c` | Start in Capture mode. |
|
|
194
|
+
| `--transmit`<br>`--tx` | Start in Transmit mode (pass a recording `#` from `--list`, `.sigmf-data` path, `'latest'`, or omit in TUI). |
|
|
195
|
+
| `--loopback`<br>`--lb` | Run the internal digital Loopback Test. |
|
|
196
|
+
| `--list`<br>`-l` | List available SigMF recordings in `records-dir` and exit. |
|
|
197
|
+
| `--show-config`<br>`--sc` | Show current configuration and exit. |
|
|
198
|
+
| `--headless`<br>`--hl` | Run in console text mode without the curses TUI (outputs plain logs without colors or live meter when redirected to a file/pipe; supports `NO_COLOR` / `FORCE_COLOR`). |
|
|
199
|
+
| `--save`<br>`-s` | Persist CLI setting changes to `settings.json`. |
|
|
200
|
+
| `--reset`<br>`-r` | Reset configuration to defaults and save to `settings.json`. |
|
|
201
|
+
| `--version`<br>`-v` | Show program version and exit. |
|
|
202
|
+
| `--help`<br>`-h` | Show help message and exit. |
|
|
203
|
+
|
|
204
|
+
## License
|
|
205
|
+
|
|
206
|
+
Distributed under the **GNU General Public License v3.0** (GPL-3.0). See [`LICENSE`](https://github.com/SketchTurnerDev/pluto_siege/blob/main/LICENSE) for details.
|
|
@@ -0,0 +1,184 @@
|
|
|
1
|
+
<h1 align="center">PlutoSiege</h1>
|
|
2
|
+
|
|
3
|
+
<p align="center">
|
|
4
|
+
<strong>RF Capture & Replay Tool for PlutoSDR</strong>
|
|
5
|
+
</p>
|
|
6
|
+
|
|
7
|
+
<p align="center">
|
|
8
|
+
<a href="https://pypi.org/project/pluto-siege/"><img src="https://img.shields.io/pypi/v/pluto-siege?style=for-the-badge&logo=pypi&logoColor=white&color=blue" alt="PyPI"></a>
|
|
9
|
+
<img src="https://img.shields.io/badge/Python-3.9+-3776AB?style=for-the-badge&logo=python&logoColor=white" alt="Python">
|
|
10
|
+
<a href="https://github.com/SketchTurnerDev/pluto_siege/blob/main/LICENSE"><img src="https://img.shields.io/badge/License-GPL--3.0-blueviolet.svg?style=for-the-badge" alt="License"></a>
|
|
11
|
+
<img src="https://img.shields.io/badge/Hardware-ADALM--Pluto-0099FF?style=for-the-badge" alt="Hardware">
|
|
12
|
+
<img src="https://img.shields.io/badge/Format-SigMF-orange?style=for-the-badge" alt="SigMF">
|
|
13
|
+
</p>
|
|
14
|
+
|
|
15
|
+
<p align="center">
|
|
16
|
+
<img src="https://raw.githubusercontent.com/SketchTurnerDev/pluto_siege/main/assets/screenshot.png" alt="PlutoSiege Screenshot" width="100%">
|
|
17
|
+
</p>
|
|
18
|
+
|
|
19
|
+
> **REGULATORY DISCLAIMER**
|
|
20
|
+
> RF transmission is regulated by local authorities. Replay only signals you own or are permitted to transmit, into a dummy load or at the lowest power required.
|
|
21
|
+
|
|
22
|
+
## About
|
|
23
|
+
|
|
24
|
+
**PlutoSiege** is a terminal and command-line tool for recording and replaying short RF bursts at 433 MHz, 868 MHz, and nearby frequencies from car remotes, garage doors, doorbells, and wireless sensors.
|
|
25
|
+
|
|
26
|
+
Built for ADALM-Pluto SDR hardware, it saves captures in the standard SigMF format so recordings can be opened directly in URH, IQEngine, GNU Radio, or Inspectrum.
|
|
27
|
+
|
|
28
|
+
### Hardware Compatibility
|
|
29
|
+
Supports official Analog Devices ADALM-Pluto Rev. B and Rev. C boards as well as compatible AD9363 and AD9361 clones such as Pluto Nano, Pluto Plus, and custom PlutoSDR hardware.
|
|
30
|
+
|
|
31
|
+
## Features
|
|
32
|
+
|
|
33
|
+
- **Single & Continuous Capture**: Capture single RF bursts or enable **Auto capture** (`--auto-capture true`) to loop continuously and save numbered multi-burst recordings with collision-safe filenames.
|
|
34
|
+
- **Level Metering**: Real-time dBFS level meter with saturation (`SAT!`) warning.
|
|
35
|
+
- **Threshold Detection**: Automated noise floor estimation (with optional periodic recalibration for mobile capture) or manual threshold setting.
|
|
36
|
+
- **Pre-Trigger Buffer**: Keeps a ring buffer of history before trigger so preambles are not missed.
|
|
37
|
+
- **SigMF Format**: Saves `.sigmf-meta` and `.sigmf-data` pairs in a configurable recordings directory.
|
|
38
|
+
- **GPS Geotagging**: Records precise coordinates in SigMF metadata via `gpsd` and displays geotags during replay.
|
|
39
|
+
- **Digital Loopback Test**: Built-in internal digital BIST loopback test (at 1 GHz) to check hardware health and SNR without external antennas.
|
|
40
|
+
- **Full CLI & Headless Mode**: Launch any mode or override any setting from the command line, list available recordings, or run completely headless without curses.
|
|
41
|
+
- **Linux Native**: Built and optimized specifically for Linux environments (supports all major distribution families: Debian-based, RPM-based, Arch-based, etc.).
|
|
42
|
+
|
|
43
|
+
## Installation
|
|
44
|
+
|
|
45
|
+
### 1. System Drivers
|
|
46
|
+
Install the required IIO system drivers for your distribution family:
|
|
47
|
+
|
|
48
|
+
**Debian-based:**
|
|
49
|
+
```bash
|
|
50
|
+
sudo apt update && sudo apt install -y libiio0 libiio-dev libiio-utils
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
**RPM-based:**
|
|
54
|
+
```bash
|
|
55
|
+
sudo dnf install -y libiio python3-iio libiio-utils
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
**Arch-based:**
|
|
59
|
+
```bash
|
|
60
|
+
sudo pacman -S libiio
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
### 2. Optional: GPS Support
|
|
64
|
+
If you plan to use GPS geotagging for SigMF recordings, install the `gpsd` daemon and tools:
|
|
65
|
+
|
|
66
|
+
**Debian-based:**
|
|
67
|
+
```bash
|
|
68
|
+
sudo apt install -y gpsd gpsd-clients
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
**RPM-based:**
|
|
72
|
+
```bash
|
|
73
|
+
sudo dnf install -y gpsd gpsd-clients
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
**Arch-based:**
|
|
77
|
+
```bash
|
|
78
|
+
sudo pacman -S gpsd
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
> **Note:** Configure and start the `gpsd` service according to your specific GPS receiver hardware (USB dongle, UART module, Bluetooth, or virtual source) so that it listens on `127.0.0.1:2947`. Once running, enable GPS in PlutoSiege **Settings** (`Enable GPS (gpsd): yes`) or via CLI (`--enable-gps true`).
|
|
82
|
+
|
|
83
|
+
### 3. Install & Run PlutoSiege
|
|
84
|
+
|
|
85
|
+
#### Option A: Via pip / pipx (Recommended)
|
|
86
|
+
Install directly from PyPI:
|
|
87
|
+
```bash
|
|
88
|
+
pipx install pluto_siege
|
|
89
|
+
# or: pip install pluto_siege
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
Launch from any terminal:
|
|
93
|
+
```bash
|
|
94
|
+
pluto_siege
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
#### Option B: From Source
|
|
98
|
+
Clone the repository and install dependencies:
|
|
99
|
+
```bash
|
|
100
|
+
git clone https://github.com/SketchTurnerDev/pluto_siege.git
|
|
101
|
+
cd pluto_siege
|
|
102
|
+
pip install -r requirements.txt
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
Launch via the main script:
|
|
106
|
+
```bash
|
|
107
|
+
python pluto_siege.py
|
|
108
|
+
# or: python -m pluto_siege
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
## Demo
|
|
112
|
+
|
|
113
|
+
<p align="center">
|
|
114
|
+
<img src="https://raw.githubusercontent.com/SketchTurnerDev/pluto_siege/main/assets/demo.gif" alt="PlutoSiege Demo" width="100%">
|
|
115
|
+
</p>
|
|
116
|
+
|
|
117
|
+
## Application Menu
|
|
118
|
+
|
|
119
|
+
### 1. Capture
|
|
120
|
+
Listens for incoming RF bursts on the configured receiver frequency (`rx_freq`).
|
|
121
|
+
- Captures a single burst by default, or loops continuously (numbering saved bursts `[#1]`, `[#2]`, ... until stopped with `Esc` / `Q` in TUI or `Ctrl+C` in headless mode) when **Auto capture** (`--auto-capture true`) is enabled.
|
|
122
|
+
- Real-time dBFS level meter with saturation (`SAT!`) warnings.
|
|
123
|
+
- Automated noise floor estimation or manual threshold detection.
|
|
124
|
+
- Pre-trigger history ring buffer to preserve signal preambles.
|
|
125
|
+
- Saves captures as standard SigMF (`.sigmf-meta` and `.sigmf-data`) pairs with optional GPS geolocation tags.
|
|
126
|
+
|
|
127
|
+
### 2. Transmit
|
|
128
|
+
Browse and replay saved SigMF recordings from the configured recordings directory (`records_dir`).
|
|
129
|
+
- Displays recorded timestamp, center frequency, sample rate, sample count, and GPS coordinates.
|
|
130
|
+
- Replays signals via the PlutoSDR transmitter at the exact frequency (`core:frequency`) and sample rate (`core:sample_rate`) stored in `.sigmf-meta`.
|
|
131
|
+
- In-place deletion of unwanted recordings (`D` or `Delete`).
|
|
132
|
+
|
|
133
|
+
### 3. Loopback Test
|
|
134
|
+
Internal hardware diagnostic to verify the SDR transceiver and USB/DMA pipeline.
|
|
135
|
+
- Enables the AD936x internal digital BIST loopback (`loopback = 1`) at 1 GHz without transmitting over the air.
|
|
136
|
+
- Calculates received Signal-to-Noise Ratio (SNR) to confirm hardware health.
|
|
137
|
+
|
|
138
|
+
### 4. Settings & CLI Parameters
|
|
139
|
+
Configures radio parameters, trigger behavior, GPS integration, and interface preferences. All settings can be edited interactively in the TUI **Settings** screen or passed via command-line flags.
|
|
140
|
+
|
|
141
|
+
| Flags / Parameter | Type | Default | Description |
|
|
142
|
+
| :--- | :--- | :--- | :--- |
|
|
143
|
+
| `--pluto-uri`<br>`--pu` | `str` | `usb:` | PlutoSDR `libiio` context URI (`usb:`, `usb:1.4.5`, `ip:192.168.2.1`, `local:`). |
|
|
144
|
+
| `--rx-freq`<br>`--rf` | `int` | `433.92M` | Receiver center frequency in Hz; supports `k`/`M`/`G` suffixes and bare MHz shorthand (`70M - 6G`; e.g. `433`, `868`). |
|
|
145
|
+
| `--sample-rate`<br>`--sr` | `int` | `2.1M` | Sample rate in SPS; supports `k`/`M` suffixes (`521k - 61.44M`). |
|
|
146
|
+
| `--rf-bandwidth`<br>`--rb` | `int` | `0` | Analog RF filter bandwidth in Hz, or `0`/`auto` to follow `--sample-rate`; supports `k`/`M` suffixes (`0` or `200k - 56M`). |
|
|
147
|
+
| `--rx-gain`<br>`--rg` | `float` | `15.0` | Manual RX hardware gain in dB (`-10.0 .. 74.5`). |
|
|
148
|
+
| `--tx-gain`<br>`--tg` | `float` | `0.0` | Manual TX hardware gain in dB (`-89.75 .. 0.0`). |
|
|
149
|
+
| `--tx-repeats`<br>`--tr` | `int` | `1` | Number of consecutive burst transmissions per replay (`1 .. 100`). |
|
|
150
|
+
| `--auto-capture`<br>`--ac` | `bool` | `false` | Enable continuous multi-burst capture loop (`true` or `false`). |
|
|
151
|
+
| `--auto-threshold`<br>`--at` | `bool` | `true` | Enable automatic noise floor threshold detection (`true` or `false`). |
|
|
152
|
+
| `--auto-trigger-margin`<br>`--atm` | `float` | `8.0` | Trigger margin above noise floor in dB (`1.0 .. 30.0`; unused when `--auto-threshold` is `false`). |
|
|
153
|
+
| `--auto-recal-seconds`<br>`--ars` | `float` | `0.0` | Periodic noise floor recalibration interval in seconds while listening, or `0` to disable; supports `ms`/`s` suffixes (`0.0 .. 600.0`; unused when `--auto-threshold` is `false`). |
|
|
154
|
+
| `--manual-threshold`<br>`--mt` | `float` | `-30.0` | Fixed trigger threshold in dBFS (`-120.0 .. 0.0`; unused when `--auto-threshold` is `true`). |
|
|
155
|
+
| `--pre-trigger-buffers`<br>`--ptb` | `int` | `2` | Number of pre-trigger history buffers kept in memory (`1 .. 50`). |
|
|
156
|
+
| `--min-burst-seconds`<br>`--mbs` | `float` | `0.0` | Minimum active burst duration in seconds to filter short noise spikes, or `0` to disable; supports `ms`/`s` suffixes (`0.0 .. 5.0`). |
|
|
157
|
+
| `--silence-seconds`<br>`--ss` | `float` | `0.8` | Continuous silence duration in seconds to stop recording; supports `ms`/`s` suffixes (`0.01 .. 10.0`). |
|
|
158
|
+
| `--max-post-trigger-seconds`<br>`--mpts` | `float` | `4.0` | Maximum recording duration in seconds after trigger; supports `ms`/`s` suffixes (`0.1 .. 30.0`). |
|
|
159
|
+
| `--rx-buffer-size`<br>`--rbs` | `int` | `32768` | DMA receive buffer size in samples (`1024 .. 1048576`). |
|
|
160
|
+
| `--enable-gps`<br>`--eg` | `bool` | `false` | Enable GPS geolocation tagging via `gpsd` daemon (`true` or `false`). |
|
|
161
|
+
| `--gpsd-host`<br>`--gh` | `str` | `127.0.0.1` | `gpsd` daemon hostname or IP address (unused when `--enable-gps` is `false`). |
|
|
162
|
+
| `--gpsd-port`<br>`--gp` | `int` | `2947` | `gpsd` daemon TCP port (`1 .. 65535`; unused when `--enable-gps` is `false`). |
|
|
163
|
+
| `--records-dir`<br>`--rd` | `str` | `./recordings` | Directory path for saving and loading SigMF recordings (`~/.pluto_siege/recordings` when installed via `pip`/`pipx`). |
|
|
164
|
+
| `--enable-sound`<br>`--es` | `bool` | `true` | Enable acoustic sound effect cues (`true` or `false`). |
|
|
165
|
+
| `--enable-mouse`<br>`--em` | `bool` | `true` | Enable terminal mouse support in the TUI (`true` or `false`). |
|
|
166
|
+
|
|
167
|
+
### CLI-Only Options
|
|
168
|
+
|
|
169
|
+
| Flags | Description |
|
|
170
|
+
| :--- | :--- |
|
|
171
|
+
| `--capture`<br>`-c` | Start in Capture mode. |
|
|
172
|
+
| `--transmit`<br>`--tx` | Start in Transmit mode (pass a recording `#` from `--list`, `.sigmf-data` path, `'latest'`, or omit in TUI). |
|
|
173
|
+
| `--loopback`<br>`--lb` | Run the internal digital Loopback Test. |
|
|
174
|
+
| `--list`<br>`-l` | List available SigMF recordings in `records-dir` and exit. |
|
|
175
|
+
| `--show-config`<br>`--sc` | Show current configuration and exit. |
|
|
176
|
+
| `--headless`<br>`--hl` | Run in console text mode without the curses TUI (outputs plain logs without colors or live meter when redirected to a file/pipe; supports `NO_COLOR` / `FORCE_COLOR`). |
|
|
177
|
+
| `--save`<br>`-s` | Persist CLI setting changes to `settings.json`. |
|
|
178
|
+
| `--reset`<br>`-r` | Reset configuration to defaults and save to `settings.json`. |
|
|
179
|
+
| `--version`<br>`-v` | Show program version and exit. |
|
|
180
|
+
| `--help`<br>`-h` | Show help message and exit. |
|
|
181
|
+
|
|
182
|
+
## License
|
|
183
|
+
|
|
184
|
+
Distributed under the **GNU General Public License v3.0** (GPL-3.0). See [`LICENSE`](https://github.com/SketchTurnerDev/pluto_siege/blob/main/LICENSE) for details.
|
|
@@ -14,25 +14,7 @@
|
|
|
14
14
|
# You should have received a copy of the GNU General Public License
|
|
15
15
|
# along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
16
16
|
|
|
17
|
-
"""
|
|
18
|
-
|
|
19
|
-
A full-screen terminal application that records brief RF transmissions - car
|
|
20
|
-
remotes, doorbells, weather stations and similar OOK/ASK devices - and replays
|
|
21
|
-
them. Recordings are written as SigMF pairs so they can be opened in other
|
|
22
|
-
tools as well.
|
|
23
|
-
|
|
24
|
-
Usage:
|
|
25
|
-
python3 -m pluto_siege
|
|
26
|
-
|
|
27
|
-
Requires Python 3.9+, an interactive terminal, an ADALM-Pluto (or compatible
|
|
28
|
-
AD936x device) and:
|
|
29
|
-
pip install -r requirements.txt
|
|
30
|
-
|
|
31
|
-
Transmitting is regulated. Replay only signals you are licensed or permitted to
|
|
32
|
-
emit, into a dummy load or at the lowest gain that does the job.
|
|
33
|
-
|
|
34
|
-
Author: SketchTurnerDev
|
|
35
|
-
"""
|
|
17
|
+
"""RF Capture & Replay Tool for PlutoSDR."""
|
|
36
18
|
|
|
37
19
|
from pluto_siege.constants import AUTHOR, LICENSE, VERSION
|
|
38
20
|
|