gr-rylr998/python/rylr998/__init__.py
Ryan Malloy 3660f139ec Add channelizer and fix FrameSync for real SDR captures
- Add Channelizer class for wideband capture processing (2 MHz → 125 kHz)
  - FIR low-pass filter with scipy.firwin (or fallback windowed-sinc)
  - Proper decimation for anti-aliasing
- Fix FrameSync preamble detection to accept any CFO
  - Real captures have significant carrier frequency offset
  - Preamble bins appear at arbitrary values, not just near 0
  - Now accepts any strong signal as first preamble, validates consistency
- Add decode_capture.py example script for processing raw BladeRF captures
- PHYDecode verified to match existing lora_phy decoder output
2026-02-05 14:00:17 -07:00

46 lines
1.2 KiB
Python

"""gr-rylr998: GNU Radio OOT module for RYLR998 LoRa modems.
Provides complete TX/RX blocks for RYLR998 LoRa modems with support for
the reverse-engineered NETWORKID → sync word mapping.
Blocks:
- css_demod: CSS demodulator (FFT peak detection)
- css_mod: CSS modulator (chirp generation)
- frame_sync: Preamble + sync word detection
- frame_gen: Header + preamble + SFD generation
- phy_decode: Gray decode → deinterleave → Hamming → dewhiten
- phy_encode: Whiten → Hamming → interleave → Gray encode
Utilities:
- networkid: NETWORKID ↔ sync word conversion
"""
from .networkid import (
networkid_to_sync_word,
sync_word_to_networkid,
sync_word_byte_to_deltas,
)
from .css_demod import CSSDemod
from .css_mod import CSSMod
from .phy_decode import PHYDecode, LoRaFrame
from .phy_encode import PHYEncode
from .frame_sync import FrameSync
from .frame_gen import FrameGen
from .channelizer import Channelizer, channelize
__version__ = "0.1.0"
__all__ = [
"networkid_to_sync_word",
"sync_word_to_networkid",
"sync_word_byte_to_deltas",
"CSSDemod",
"CSSMod",
"PHYDecode",
"PHYEncode",
"FrameSync",
"FrameGen",
"LoRaFrame",
"Channelizer",
"channelize",
]