Skip to content

Commit 08a6218

Browse files
committed
Track default platform GPS
1 parent 3cfc6dc commit 08a6218

File tree

1 file changed

+20
-1
lines changed
  • clearpath_generator_common/clearpath_generator_common/param

1 file changed

+20
-1
lines changed

clearpath_generator_common/clearpath_generator_common/param/platform.py

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
from clearpath_config.common.utils.dictionary import merge_dict, replace_dict_items
3939
from clearpath_config.platform.battery import BatteryConfig
4040
from clearpath_config.sensors.types.cameras import BaseCamera, IntelRealsense
41-
from clearpath_config.sensors.types.gps import BaseGPS
41+
from clearpath_config.sensors.types.gps import BaseGPS, NMEA
4242
from clearpath_config.sensors.types.imu import BaseIMU, PhidgetsSpatial
4343
from clearpath_config.sensors.types.lidars_2d import BaseLidar2D
4444
from clearpath_config.sensors.types.lidars_3d import BaseLidar3D
@@ -323,6 +323,13 @@ def generate_parameters(self, use_sim_time: bool = False) -> None:
323323
'contains': ['imu']
324324
}
325325

326+
if self.clearpath_config.get_platform_model() == Platform.J100:
327+
sensor_analyzers['gps'] = {
328+
'type': 'diagnostic_aggregator/GenericAnalyzer',
329+
'path': 'GPS',
330+
'contains': ['gps']
331+
}
332+
326333
# List all topics to be monitored from each launched sensor
327334
for sensor in self.clearpath_config.sensors.get_all_sensors():
328335

@@ -476,6 +483,18 @@ def generate_parameters(self, use_sim_time: bool = False) -> None:
476483
}
477484
})
478485

486+
if platform_model == Platform.J100:
487+
self.param_file.update({
488+
self.DIAGNOSTIC_UPDATER_NODE: {
489+
'topics': {
490+
'sensors/gps_0/fix': {
491+
'type': NMEA.TOPICS.TYPE[NMEA.TOPICS.FIX],
492+
'rate': 10.0
493+
}
494+
}
495+
}
496+
})
497+
479498
# List all topics to be monitored from each launched sensor
480499
for sensor in self.clearpath_config.sensors.get_all_sensors():
481500

0 commit comments

Comments
 (0)