Cleanup function to ensure Dynamixels are disconnected properly.
()
| 31 | |
| 32 | |
| 33 | def dynamixel_cleanup_handler(): |
| 34 | """Cleanup function to ensure Dynamixels are disconnected properly.""" |
| 35 | open_clients = list(DynamixelClient.OPEN_CLIENTS) |
| 36 | for open_client in open_clients: |
| 37 | if open_client.port_handler.is_using: |
| 38 | logging.warning('Forcing client to close.') |
| 39 | open_client.port_handler.is_using = False |
| 40 | open_client.disconnect() |
| 41 | |
| 42 | |
| 43 | def signed_to_unsigned(value: int, size: int) -> int: |
nothing calls this directly
no test coverage detected