This commit handles the situation when NCP(USB CDC ACM) performs hard reset after receiving SPINEL_CMD_RESET.
When NCP is connected by USB CDC ACM and we reset it, the NCP device is reattached to the host operating system. So far for NCP(USB CDC ACM) pseudo reset has been performing meaning only specific parts of firmware were reset. It is error-prone solution for bare metal device and almost unreachable for devices working under RTOS. But what's most important it does not guarantee the clean init state of the NCP device. It's far easier and better to hard reset NCP and properly handle the USB connection on the host side.
It uses udev library to check if device enumeration has ended.
It works based on symlink to the NCP device created by udev in /dev/serial/by-id/ directory.
This commit handles the situation when NCP(USB CDC ACM) performs hard reset after receiving SPINEL_CMD_RESET.
When NCP is connected by USB CDC ACM and we reset it, the NCP device is reattached to the host operating system. So far for NCP(USB CDC ACM) pseudo reset has been performing meaning only specific parts of firmware were reset. It is error-prone solution for bare metal device and almost unreachable for devices working under RTOS. But what's most important it does not guarantee the clean init state of the NCP device. It's far easier and better to hard reset NCP and properly handle the USB connection on the host side.
It uses udev library to check if device enumeration has ended.
It works based on symlink to the NCP device created by udev in /dev/serial/by-id/ directory.