gorans Posted November 2, 2022 Share Posted November 2, 2022 (edited) Hi, I upgraded to Monterey and now I have a problem that WOL and USB wakes to darkwake, requiring double key press or mouse click. DarkWake from Normal Sleep [CDN] : due to XDCI CNVW PEG2 PEG3 RP04/ Using AC second keypress: DarkWake to FullWake from Normal Sleep [CDNVA] : due to UserActivity Assertion Using AC I found my XHC with gfxutil: 00:14.0 8086:06ed /PCI0@0/XHC@14 = PciRoot(0x0)/Pci(0x14,0x0) And put this into config.plist DeviceProperties/Add/: <key>PciRoot(0x0)/Pci(0x14,0x0)</key> <dict> <key>acpi-wake-type</key> <data>AQ==</data> </dict> However, it doesn't help, first wake is still darkwake with no display. I also tried darkwake=0 and darkwake=8 in boot args but nothing changed. Is there a way to disable darkwake on Monterey? pmset -g: standby 0 Sleep On Power Button 1 womp 1 hibernatefile /var/vm/sleepimage proximitywake 0 powernap 0 networkoversleep 0 disksleep 0 standbydelayhigh 86400 sleep 10 (sleep prevented by bluetoothd) hibernatemode 0 ttyskeepawake 0 displaysleep 15 tcpkeepalive 0 highstandbythreshold 50 standbydelaylow 86400 config.plist Edited November 14, 2022 by gorans added config and other info Link to comment Share on other sites More sharing options...
Slice Posted November 3, 2022 Share Posted November 3, 2022 My computer wake up to light in Monterey as well as in Ventura. Link to comment Share on other sites More sharing options...
gorans Posted November 3, 2022 Author Share Posted November 3, 2022 6 hours ago, Slice said: My computer wake up to light in Monterey as well as in Ventura. I don't see that any of Your configurations is similar to mine, but thanks for the info. Link to comment Share on other sites More sharing options...
miliuco Posted November 3, 2022 Share Posted November 3, 2022 @gorans This can fix your problem, try it and comment. https://github.com/osy/USBWakeFixup 1 Link to comment Share on other sites More sharing options...
deeveedee Posted November 3, 2022 Share Posted November 3, 2022 (edited) In my experience, if you are able to wake your screen by an extra mouse or keyboard click, then boot-arg darkwake may be the culprit. You could try different values of boot-arg darkwake (1, 2). I think that the the two values that you tried ( 0 and 8 )are actually the same. This reference might help to explain darkwake. Edited November 3, 2022 by deeveedee 1 Link to comment Share on other sites More sharing options...
Slice Posted November 3, 2022 Share Posted November 3, 2022 3 hours ago, gorans said: I don't see that any of Your configurations is similar to mine, but thanks for the info. I just said it is not Monterey problem. Link to comment Share on other sites More sharing options...
dMatik Posted November 3, 2022 Share Posted November 3, 2022 Quote Link to comment Share on other sites More sharing options...
gorans Posted November 3, 2022 Author Share Posted November 3, 2022 4 hours ago, miliuco said: @gorans This can fix your problem, try it and comment. https://github.com/osy/USBWakeFixup Didn't help. 3 hours ago, deeveedee said: In my experience, if you are able to wake your screen by an extra mouse or keyboard click, then boot-arg darkwake may be the culprit. You could try different values of boot-arg darkwake (1, 2). I think that the the two values that you tried ( 0 and 8 )are actually the same. This reference might help to explain darkwake. Yeah, I read that but there is no conclusive results, especially for Monterey. I started with no darkwake boot arg but I didn't try darkwake=2. 1 hour ago, dMatik said: That script actually works! Hack now fully wakes on USB and WOL. Thank You! 1 1 Link to comment Share on other sites More sharing options...
dMatik Posted November 4, 2022 Share Posted November 4, 2022 @gorans I'm glad to hear it, I think our hacks suffer from "PMCS.PM_Status" and for me untill catalina USBWAKEFIXUP worked flawlessly, i think in big sur were some changes made under the hood and they moved from kernel handling the wake to iokit, is just a theory i had but i did not have the expertise to make a fix. Even for this script I found it accidentally after searching for a script to turn off bluetooth when i sleep and turn back on when I wake (bluetoothd high cpu usage after wake and no bluetooth on my fenvi t919 with BCM943602CS chip inside). For me now all forks perfectly on ventura 13.0 aside of continuity camera, and there i think is a whitelist thing from apple servers "com.apple.bluetooth.services.cloud" is updated everyday in /Users/User/Library, i had continuity camera without video from b3 (when i bought the fenvi) till b8, after that, only on cable (without video). I read on the prerelease forum that someone made a experiment changing from original apple card to a intel, and when he put back the original apple card he lost continuity camera (all other continuity services and airdrop keep working, only continuity camera lost". What is funny about this is that after a discution with apple support about my macbook, my "iMacPro" hack is visible on checkcovereage apple page, maybe after some updates continuity camera will start to work "like magic" 2 Link to comment Share on other sites More sharing options...
miliuco Posted November 4, 2022 Share Posted November 4, 2022 (edited) @gorans @dMatik Sometimes old things come in handy again 🙂 In 2009 we were already trying to fix sleep problems in Leopard 10.5.8 with a script created by @Thireus based on the SleepWatcher app (by bernhard-baehr). This method with some changes is the one that has now been useful to @gorans. Shortly after that, the SleepEnabler.kext extension was released which did the same function as the script but gave errors on some systems. I'm glad the issue has been resolved. EDIT: of course credits to @dMatik for the new app, including BT off and on as extra. Edited November 4, 2022 by miliuco 2 Link to comment Share on other sites More sharing options...
gorans Posted November 4, 2022 Author Share Posted November 4, 2022 It seems for me that every OS update I have sleeping problems on hacks. What was working perfectly in 10.6, stopped working in 10.9. And I sort it out. Then an update to 10.11. and again sleep/wake problems. And I sort it out.... I think that only update that went without problems was 10.14 -> 10.15. Or maybe just WOL issues. I'm not happy with this solution but I tried all other ways with no luck, so It'll have to do. 2 hours ago, dMatik said: @gorans I'm glad to hear it, I think our hacks suffer from "PMCS.PM_Status" and for me untill catalina USBWAKEFIXUP worked flawlessly, i think in big sur were some changes made under the hood and they moved from kernel handling the wake to iokit, is just a theory i had but i did not have the expertise to make a fix. That's a good info. Not for me, as I'm no expert either, but maybe a pointer for someone with more knowledge. Thanks guys. 2 Link to comment Share on other sites More sharing options...
Recommended Posts