UbiquityRobotics / ubiquity_motor

Package that provides a ROS interface for the motors in UbiquityRobotics robots
BSD 3-Clause "New" or "Revised" License
24 stars 23 forks source link

A workaround for issue 83. Insert a delay prior to serial port setup #90

Closed mjstn closed 4 years ago

mjstn commented 4 years ago

Inserts a 2 second ROS delay prior to serial port setup.

Tests so far show this seems to avoid the issue where some OS components sets the serial port to 115200. The odd thing about the defect is stty still shows it as 38.4k but it is in fact 115.2k baud

I am generally against the 'just put a delay in' approach but it is estimated that the root cause here may be extremely complex to find and this bug is impacting a major account thus brute force workaround. So if a kernel/OS expert wishes to really fix the defect, go for it and simply remove this delay. Maybe keep the logs so you can see if something shows up between logs like after we init something shows up. Sadly whatever is doing it is likely NOT going to show up in ros log and would be in an OS log somewhere but at least the timestamps from our logs would get you to the kernel log or perhaps OS log area of interest.

NOTE: This change needs a separate pull request. Earlier I had formed a branch trying to do this but it had other changes. So have made this branch and deleted other branch to clean things up.

mjstn commented 4 years ago

Have completed and tested conversion to simpler delay. Thanks