pub struct CallRecord {Show 52 fields
pub call_num: u64,
pub transmission_id: String,
pub freq: u64,
pub freq_error: i64,
pub signal: Option<f64>,
pub noise: Option<f64>,
pub snr: Option<f64>,
pub clean_voice_pct: Option<f64>,
pub source_num: i64,
pub recorder_num: i64,
pub tdma_slot: i64,
pub phase2_tdma: bool,
pub start_time: i64,
pub stop_time: i64,
pub start_time_ms: i64,
pub stop_time_ms: i64,
pub emergency: bool,
pub priority: i64,
pub mode: bool,
pub duplex: bool,
pub encrypted: bool,
pub algid: i64,
pub key_id: i64,
pub decrypted: bool,
pub clock_off: bool,
pub call_length: f64,
pub call_length_ms: i64,
pub talkgroup: u32,
pub talkgroup_ota: Option<u32>,
pub talkgroup_tag: String,
pub talkgroup_description: String,
pub talkgroup_group_tag: String,
pub talkgroup_group: String,
pub nac: String,
pub color_code: i64,
pub ran: i64,
pub tone_mode: String,
pub tone_detected: String,
pub tone_confidence: f64,
pub audio_type: String,
pub system_type: String,
pub voice_mode: String,
pub short_name: String,
pub site: String,
pub patched_talkgroups: Vec<u32>,
pub freq_list: Vec<FreqEntry>,
pub error_list: Vec<ErrorInterval>,
pub src_list: Vec<SrcEntry>,
pub tones: Vec<ToneEntry>,
pub tone_patterns: Vec<TonePattern>,
pub signals: Vec<String>,
pub extra: Map<String, Value>,
}Expand description
A call’s JSON, in Trunk Recorder’s format: the .json file beside its
audio. The recorder makes one of these for every call and writes it as
it serialises (field order, flags as 0/1, levels to a tenth of a dB);
read back, it accepts Trunk Recorder’s own files too (flags as 0/1 or
booleans). Fields neither writes are kept in extra. Its default is the
recorder’s for what wasn’t heard (-1, "off", "digital").
Serialise it as JSON with serde_json (CallRecord::to_json): its
numbers are written through serde_json’s raw values, which other serde
formats don’t take.
Fields§
§call_num: u64§transmission_id: StringThe same on every copy of one transmission (a system’s sites, each
recording it): <system>-<talkgroup>-<radio>-<start ms>, the radio
the first known to talk (0: none), the start the first copy’s. With
conversation mode on, a call’s first transmission names it.
freq: u64Hz.
freq_error: i64How far off its channel the voice carrier came in, Hz (the mean over the call).
signal: Option<f64>Levels while it was heard, dB (null: not measured).
noise: Option<f64>§snr: Option<f64>§clean_voice_pct: Option<f64>Voice frames decoded without errors, % (null: no digital voice).
source_num: i64§recorder_num: i64§tdma_slot: i64§phase2_tdma: bool§start_time: i64Unix seconds.
stop_time: i64§start_time_ms: i64Unix ms.
stop_time_ms: i64§emergency: bool§priority: i64§mode: boolPacket mode.
duplex: bool§encrypted: bool§algid: i64The cipher its encryption sync named (-1: none heard).
key_id: i64§decrypted: boolIts encrypted voice was decrypted, at least in part (this recorder’s addition).
clock_off: boolIts times may be off: when it ended, the recorder’s clock was measured a quarter second or more off, or the operating system said it wasn’t synchronized (this recorder’s addition; absent when the clock was fine).
call_length: f64Seconds of audio.
call_length_ms: i64§talkgroup: u32§talkgroup_ota: Option<u32>Conventional P25 / DMR / NXDN: the talkgroup the air named (this
recorder’s addition, like site). talkgroup is what the call is
filed under, which a channel row may set to another number; none
for analog, trunked calls, or a call whose air named none.
talkgroup_tag: String§talkgroup_description: String§talkgroup_group_tag: String§talkgroup_group: String§nac: StringP25: the NAC its voice carried on a conventional channel, its site’s
on a trunked system, in hex as radios and channel files write it
("293"; empty: none; this recorder’s addition).
color_code: i64DMR: its colour code (-1: none).
ran: i64NXDN: its RAN (-1: none).
tone_mode: StringAn analog call’s tone (Trunk Recorder’s): “ctcss”, “dcs”, “search” (identified, not matched) or “off”.
tone_detected: String§tone_confidence: f64§audio_type: String“digital” | “digital tdma” | “analog”
system_type: StringThe kind of system it came on, as SystemInfo::kind has it: “p25” |
“smartnet” | “dmr” | “nxdn” | “edacs” | “conventional” (this recorder’s addition).
voice_mode: StringWhat its voice was: “p25” | “p25_phase2” | “dmr” | “nxdn48” | “nxdn96”
| “provoice” | “fm” | “am” — a conventional channel’s mode, or a trunked grant’s
(this recorder’s addition).
short_name: String§site: StringThe site its copy was kept from (this recorder’s addition; a system of one site: its short name; none for a conventional system’s).
patched_talkgroups: Vec<u32>Every talkgroup patched with this one during the call, its own included; absent (empty) when it wasn’t patched with another.
freq_list: Vec<FreqEntry>§error_list: Vec<ErrorInterval>Voice frame errors over the call, in stretches of its audio.
src_list: Vec<SrcEntry>§tones: Vec<ToneEntry>In-band tones sent in its voice (DTMF, KNOX, call progress, single tones), in order. This recorder’s: Trunk Recorder has none.
tone_patterns: Vec<TonePattern>What its tones make up: pages, alerts, digit strings, in order.
signals: Vec<String>The system’s signals it carried (their ids), in the order first heard.
extra: Map<String, Value>Implementations§
Source§impl CallRecord
impl CallRecord
Sourcepub fn error_count(&self) -> u64
pub fn error_count(&self) -> u64
Voice frames with bit errors, over the call.