怎么可以利用Python唤醒睡眠/休眠的电脑

PC进入睡眠或者休眠模式,我用同一台PC,Python怎么唤醒,

博主解决了吗,我也想实现python控制休眠和唤醒休眠

用python的os执行命令行试试,,比如os.system('shutdown -h'),或者python执行bat脚本
休眠:shutdown -h
关机:shutdown -s -t 0
具体命令行执行可以参考