feat(dmr): add diagnostic capture probes

This commit is contained in:
2026-07-14 19:09:35 +03:00
parent 70486d901b
commit 39b4627c2b
9 changed files with 662 additions and 3 deletions
+16 -2
View File
@@ -3591,7 +3591,8 @@ var
begin
if not FController.GetDMRStatus(S) then Exit('DMR unavailable');
if not S.Enabled then Exit('DMR off');
if not S.Synced then Exit(Format('DMR sync... %.3f', [S.SignalRMS]));
if not S.Synced then
Exit(Format('DMR sync d%d %.3f', [S.BestSyncDistance, S.SignalRMS]));
if S.Inverted then Inv := ' INV' else Inv := '';
Details := '';
if S.LinkControlValid then Details := Format(' TS%d', [S.LCSlot + 1])
@@ -4930,10 +4931,23 @@ begin
end;
procedure TMainForm.BtnModeClick(Sender: TObject);
var
Mode: Integer;
Path: string;
begin
Mode := (Sender as TFlatButton).Tag;
if (Mode = MODE_DMR) and (FController.FMode = MODE_DMR) then
begin
Path := FController.StartDMRDiagnostics(15);
if Path <> '' then
ShowMessage('DMR diagnostic capture started for 15 seconds.' +
LineEnding + 'Transmit from the radio now.' + LineEnding + LineEnding +
'Files: ' + Path + '.*');
Exit;
end;
// Логика (FMode, дефолтный фильтр, DSP SetMode/TUN/ApplyModeFilter, band cache)
// — в контроллере; рендер кнопок/фильтра/спектра — в OnControllerState(rfMode).
FController.SetMode((Sender as TFlatButton).Tag);
FController.SetMode(Mode);
end;
procedure TMainForm.BtnFilterClick(Sender: TObject);