I have a USB CDC ACM device which appears in the /dev filesystem as /dev/tty.usbmodem... and /dev/cu.usbmodem... . Most of the time, I am able to read from and write to this device using serial port libraries, including the POSIX calls open(), read(), write(), etc.However, if the device is plugged in, then my mac goes to sleep for at least a few minutes (3 seems very repeatable), when the PC wakes up and I try to open the file, the call to open() blocks or hangs forever. This also happens if I use the `O_NONBLOCK` option, which should return immediately. I am not loading any special device drivers, but instead relying on the built-in driver loaded for USB CDC ACM devices.This affects not only my software, but also built-in utilities including `screen` and other common libraries including pyserial. I've tried both the /dev/tty.usbmodem... and /dev/cu.usbmodem.. filepaths. This occurs across multiple versions of macOS including Mojave and High Sierra. I've tried using direct USB-C cable connec
2
0
1.3k