[RFC] broadcast parameter changes and ModuleParams skip full updateParams() when possible

This commit is contained in:
Daniel Agar
2022-12-19 21:14:04 -05:00
parent b6157c89a0
commit 9586ad0006
54 changed files with 289 additions and 549 deletions
+6 -14
View File
@@ -122,21 +122,13 @@ def generate_output_from_file(format_idx, filename, outputdir, package, template
for field in spec.parsed_fields():
field_name_and_type.update({field.name: field.type})
# assert if the timestamp field exists
try:
assert 'timestamp' in field_name_and_type
except AssertionError:
print("[ERROR] uORB topic files generator:\n\tgenerate_output_from_file:\tNo 'timestamp' field found in " +
spec.short_name + " msg definition!")
exit(1)
# assert if the timestamp field is of type uint64
try:
assert field_name_and_type.get('timestamp') == 'uint64'
except AssertionError:
print("[ERROR] uORB topic files generator:\n\tgenerate_output_from_file:\t'timestamp' field in " + spec.short_name +
" msg definition is not of type uint64 but rather of type " + field_name_and_type.get('timestamp') + "!")
exit(1)
# try:
# assert field_name_and_type.get('timestamp') == 'uint64'
# except AssertionError:
# print("[ERROR] uORB topic files generator:\n\tgenerate_output_from_file:\t'timestamp' field in " + spec.short_name +
# " msg definition is not of type uint64 but rather of type " + field_name_and_type.get('timestamp') + "!")
# exit(1)
topics = get_topics(filename)