mirror of
https://git.vladimir.cc/vladimir/ewsdr.git
synced 2026-08-25 19:45:09 +00:00
feat: Pluto RX hw-gain control + AD9361 cold-init (FIR via libad9361)
- RX hw-gain (Pluto/AD936x): backend SetRxGain(ModeIdx, GainDb) — gain_control_mode (manual/fast_attack/slow_attack/hybrid) + hardwaregain. Controller FRxGainMode/ FRxGainDb, commands SetRxGainMode/SetRxGain/RxGainBy, rfRxGain event, snapshot, applied in StartRunning. Persisted per-device (rx_gain_mode/rx_gain_db). HPSDR unaffected (backend no-op). - UI: separate "RF AGC" panel below the (unchanged) WDSP AGC block, shown only for Pluto — FAST/SLOW/HYB/MAN mode buttons + manual GAIN slider. LayoutLeftPanel reflows lower panels via RelayoutBelowBands; no layout shift on HPSDR. - Cold-init fix: direct sampling_frequency write doesn't load the AD9361 FIR decimation filter, so a cold-booted Pluto showed a wide centre spike that didn't track tuning (worked only after SDR Console pre-initialised it). Add optional libad9361 binding (dynamic) and call ad9361_set_bb_rate() in ApplySampleRate, which configures BBPLL + loads the FIR; falls back to direct write if absent. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -134,6 +134,9 @@ type
|
||||
procedure SendDUCSpecific(const Pkt: TDUCSpecificPacket); virtual;
|
||||
procedure SendHighPriority(const Pkt: THighPriorityPacket); virtual;
|
||||
procedure SetStepAtten(dB: Byte); virtual;
|
||||
// RX-усиление (Pluto/AD936x). ModeIdx: 0=manual, 1=fast_attack, 2=slow_attack,
|
||||
// 3=hybrid. GainDb применяется только в manual. HPSDR — no-op.
|
||||
procedure SetRxGain(ModeIdx: Integer; GainDb: Integer); virtual;
|
||||
procedure SetAlexConfig(const A: TAlexSettings); virtual;
|
||||
procedure SetXvtrMode(AEnable, ADisablePA: Boolean; ARxAnt: Byte); virtual;
|
||||
procedure SendDDCAudio(const LeftRight: array of SmallInt); virtual;
|
||||
@@ -204,6 +207,10 @@ procedure TRadioBackend.SetStepAtten(dB: Byte);
|
||||
begin
|
||||
end;
|
||||
|
||||
procedure TRadioBackend.SetRxGain(ModeIdx: Integer; GainDb: Integer);
|
||||
begin
|
||||
end;
|
||||
|
||||
procedure TRadioBackend.SetAlexConfig(const A: TAlexSettings);
|
||||
begin
|
||||
end;
|
||||
|
||||
Reference in New Issue
Block a user