mirror of
https://github.com/dptech-corp/Uni-Lab-OS.git
synced 2025-12-19 05:51:17 +00:00
fix device_id
This commit is contained in:
@@ -351,6 +351,9 @@ def convert_to_ros_msg(ros_msg_type: Union[Type, Any], obj: Any) -> Any:
|
|||||||
else:
|
else:
|
||||||
setattr(ros_msg, key, []) # FIXME
|
setattr(ros_msg, key, []) # FIXME
|
||||||
elif "array.array" in str(type(attr)):
|
elif "array.array" in str(type(attr)):
|
||||||
|
if attr.typecode == "f":
|
||||||
|
setattr(ros_msg, key, [float(i) for i in value])
|
||||||
|
else:
|
||||||
setattr(ros_msg, key, value)
|
setattr(ros_msg, key, value)
|
||||||
else:
|
else:
|
||||||
nested_ros_msg = convert_to_ros_msg(type(attr)(), value)
|
nested_ros_msg = convert_to_ros_msg(type(attr)(), value)
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
string res_id
|
string res_id
|
||||||
|
string device_id
|
||||||
string class_name
|
string class_name
|
||||||
string parent
|
string parent
|
||||||
geometry_msgs/Point bind_locations
|
geometry_msgs/Point bind_locations
|
||||||
|
|||||||
Reference in New Issue
Block a user