Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,20 @@ const csRoleKeywords: Record<string, string[]> = {
plan: ['qgc mission', 'qgroundcontrol', 'mission plan', 'mission control', 'unmanned mission', 'unmanned control mission'],
roverPlan: ['rover mission', 'rover plan', 'ground mission', 'ugv mission'],
takeoff: ['takeoff', 'take off', 'take-off'],
land: ['landing', 'land control', 'land command'],
land: ['landing', 'land control', 'land command', 'landing control'],
pause: ['pause', 'pause mission'],
rtl: ['rtl', 'return to launch', 'return home', 'return to home'],
rtl: ['rtl', 'return to launch', 'return home', 'return to home', 'return'],
offboard: ['offboard', 'off-board', 'offboard control'],
arm: ['arming', 'arm control', 'arm command', 'arm/disarm'],
driveVelocity: ['drive velocity', 'velocity control'],
driveLocation: ['drive to location', 'drive location'],
arm: ['arming', 'arm control', 'arm command', 'arm/disarm', 'arming control'],
driveVelocity: ['drive velocity', 'velocity control', 'drive velocity control'],
driveLocation: ['drive to location', 'drive location', 'drive location control'],
reboot: ['reboot', 'reboot control'],
hold: ['hold control', 'hold command', 'loiter'],
homePos: ['home position', 'home pos', 'set home'],
driveMode: ['flight mode', 'drive mode', 'mode control'],
homePos: ['home position', 'home pos', 'set home', 'home position control'],
driveMode: ['flight mode', 'drive mode', 'mode control', 'drive mode control'],
video: ['video', 'camera', 'image', 'stream'],
// vid
ptz: ['ptz control', 'ptzcontrol', 'ptz', 'pan tilt', 'pan-tilt-zoom', 'camera control'],
ptz: ['ptz control', 'ptzcontrol', 'ptz', 'pan tilt', 'pan-tilt-zoom', 'camera control', 'control'],
// geoptz
lla: ['location', 'lla', 'gps', 'position', 'platform location'],
flyToLocation: ['location'],
Expand Down
11 changes: 7 additions & 4 deletions src/modules/visualization/services/autoMapDataStreams.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,14 @@ const dsRoleKeywords: Record<string, string[]> = {
video: ['video', 'camera', 'image', 'stream'],
// chart
x: ['time', 'timestamp'],
y: [], //tbd
// lob
bearing: ['bearing', 'azimuth', 'angle', 'line of bearing'],
// text
stream: [], //tbd
bearing: ['bearing', 'azimuth', 'angle', 'line of bearing', 'LOB'],
// ellipse
semiMajorAxis: ['ellipse major', 'ellipse axis 1'],
semiMinorAxis: ['ellipse minor', 'ellipse axis 0'],
// audio
sampleRate: ['audio', 'samples', 'AAC', 'AMR-NB', 'AMR-WB', 'FLAC', 'VORBIS', 'OPUS', 'PCM'],
samples: ['audio', 'samples', 'AAC', 'AMR-NB', 'AMR-WB', 'FLAC', 'VORBIS', 'OPUS', 'PCM'],
};

export function autoMapDataStreams(
Expand Down
12 changes: 11 additions & 1 deletion src/modules/visualization/visualizations/audio/Config.vue
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const props = withDefaults(
optional: false,
}
);
const { checkedRoles, validRoles, valid, include } = useConfig(props.configRoles, !props.optional);
const { checkedRoles, validRoles, valid, include, autoMap } = useConfig(props.configRoles, !props.optional);
// Validation
const emit = defineEmits<VisualizationComponentEmits>();
const effectiveValid = computed(() => {
Expand All @@ -35,6 +35,16 @@ useComponentValidation(effectiveValid, emit);
</v-container>
<v-expand-transition>
<div v-if="include">
<v-container class="pb-0">
<v-btn
variant="tonal"
color="primary"
prepend-icon="mdi-auto-fix"
@click="autoMap"
>
Auto Map Streams
</v-btn>
</v-container>
<v-container v-for="config in props.configRoles">
<RoleCheckbox
v-model="checkedRoles[config.role]"
Expand Down