ecl_tools: use pyulog built in function to get dataset

This commit is contained in:
CarlOlsson 2018-10-08 10:07:56 +02:00 committed by Daniel Agar
parent 431bcbe642
commit 3424e73aa3
1 changed files with 6 additions and 15 deletions

View File

@ -38,23 +38,14 @@ args = parser.parse_args()
ulog = ULog(args.filename, None)
data = ulog.data_list
# extract data from innovations and status messages
for d in data:
if d.name == 'estimator_status':
estimator_status_data = d.data
print('found estimator_status data')
for d in data:
if d.name == 'ekf2_innovations':
ekf2_innovations_data = d.data
print('found ekf2_innovation data')
# extract data from EKF status message
estimator_status_data = ulog.get_dataset('estimator_status').data;
# extract data from EKF innovations message
ekf2_innovations_data = ulog.get_dataset('ekf2_innovations').data;
# extract data from sensor preflight check message
sensor_preflight = {}
for d in data:
if d.name == 'sensor_preflight':
sensor_preflight_data = d.data
print('found sensor_preflight data')
sensor_preflight_data = ulog.get_dataset('sensor_preflight').data;
if args.check_level_thresholds:
check_level_dict_filename = args.check_level_thresholds