Commit cc056ecb authored by Gill Lumer-Klabbers's avatar Gill Lumer-Klabbers
Browse files

Use ros-logger instead of print...

parent a94ddec1
......@@ -32,7 +32,7 @@ def is_nested(field_type):
def msg_to_dict(msg):
msg_structure = msg._fields_and_field_types
print(f"ros msg to dict: Processing message structure {str(msg_structure)}")
# print(f"ros msg to dict: Processing message structure {str(msg_structure)}")
msg_dict = {}
for field_name, field_type in msg_structure.items():
......@@ -55,7 +55,6 @@ def msg_to_dict(msg):
elif is_nested(field_type):
msg_dict[field_name] = msg_to_dict(field_value)
print(f"ros msg to dict: Message dict is {msg_dict}")
return msg_dict
......
......@@ -65,6 +65,7 @@ class RabbitMQPublisher(Node):
def on_msg_received(self, msg, topic_name, fields_to_forward):
msg_dict = msg_to_dict(msg)
self.get_logger().info(f"Converting ros msg to dict: Message dict is {msg_dict}")
# msg_dict = util.msg_conversion.msg_to_dict(msg)
values_to_forward = {}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment