I am currently trying to write a python script for a control loop that, on bootup of the control loop, the python script uses win32api to disconnect (eject) all the USB’s connected to the computer and then reconnect them instantaneously.
The function of it should act as if a human simply took out the USB and then plugged it back in, but I am struggling to find the correct resources in win32api to make this possible. Any help or suggestions? Thank you!
I tried looking for the specific tools or functions to aid in this but was unsuccessful so far.
tjlarso is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.