Add ability to add tracked stations via a message to TACTICAL
As per: http://xastir.org/index.php/Search_and_Rescue_(SAR)#Tactical_Callsigns, also compatible with APRSISCE/32
This commit is contained in:
parent
c669fde8bd
commit
26968a8a00
@ -10,7 +10,7 @@
|
||||
</tr>
|
||||
|
||||
<StationRow
|
||||
v-for="(tactical, callsign) in config.trackedStations"
|
||||
v-for="(tactical, callsign) in trackedStations"
|
||||
:key="callsign"
|
||||
:callsign="callsign"
|
||||
:tactical="tactical"
|
||||
@ -34,12 +34,12 @@ export default {
|
||||
components: { StationRow },
|
||||
data() {
|
||||
return {
|
||||
config: config,
|
||||
aprsStream: null,
|
||||
parser: new aprs.APRSParser(),
|
||||
messages: [],
|
||||
messagesFromStation: {},
|
||||
now: new Date()
|
||||
now: new Date(),
|
||||
trackedStations: config.trackedStations
|
||||
};
|
||||
},
|
||||
|
||||
@ -86,6 +86,20 @@ export default {
|
||||
} else {
|
||||
this.$set(this.messagesFromStation, callsign, [message]);
|
||||
}
|
||||
|
||||
// message to TACTICAL setting a tactical nickname from an
|
||||
// authorized call, so add/update it in trackedStations
|
||||
if (
|
||||
message.data &&
|
||||
message.data.addressee &&
|
||||
message.data.addressee.call === "TACTICAL" &&
|
||||
config.TACTICAL_whitelist.includes(message.from.toString())
|
||||
) {
|
||||
message.data.text.split(";").map(tac_assoc => {
|
||||
let [call, tac] = tac_assoc.split("=", 2);
|
||||
this.trackedStations[call] = tac;
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
@ -1,6 +1,10 @@
|
||||
timeoutLength: 600000 # 10 * 60 * 1000 = 10 minutes
|
||||
lowVoltage: 11.9
|
||||
|
||||
TACTICAL_whitelist:
|
||||
- KC1GDW-7
|
||||
- W1FN
|
||||
|
||||
trackedStations:
|
||||
# Digis/iGates
|
||||
W1FN-1:
|
||||
|
Loading…
Reference in New Issue
Block a user