I have been dealing with this problem for several months now, and nothing has worked so far. In the power plan I have my computer to never go to sleep, but it still does. When I wake it up, my primary monitor doesn't turn on, it's not even detected in the device manager. To fix this, I just restart my computer and it turns back on.