Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

About Serial Drivers #82

Open
TonyTnT opened this issue Aug 10, 2022 · 1 comment
Open

About Serial Drivers #82

TonyTnT opened this issue Aug 10, 2022 · 1 comment

Comments

@TonyTnT
Copy link

TonyTnT commented Aug 10, 2022

When using serial driver to communicate with device, after driver launch, if plug out the device, the driver->is_open() still return True

@sven-hoek
Copy link
Contributor

Yes, I realized that, too. It just reaches this line:

RCLCPP_ERROR_STREAM(rclcpp::get_logger("SerialPort::async_receive_handler"), error.message());

Which logs

[SerialPort::async_receive_handler]: End of file

but does nothing more (as mentioned above, is_open() still returns true. When the device connects again (the device file reappears), the driver doesn't do anything. Also in the given client-given callback function m_func, we don't have any possibility to read out the error status and react accordingly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants