Author Topic: wakeup pc from sleep  (Read 1339 times)

shlomik

  • Newbie
  • *
  • Posts: 1
wakeup pc from sleep
« on: December 13, 2018, 07:52:45 am »
hi
looking for code that can wake up pc from sleep mode when digispark connect by usb port
tried keyboard sketch and send key press but it seems the the send key it stuck when pc is in sleep mode (i tried LED blinking so the usb is not in sleep)

thanks

PeterF

  • Hero Member
  • *****
  • Posts: 881
Re: wakeup pc from sleep
« Reply #1 on: December 29, 2018, 09:08:15 pm »
I would guess that the USB HID device that the digispark says it is when pretending to be a keyboard probably doesn't set the right bits for the OS to want to keep the USB port active when it goes to sleep - either that or the clock isn't going, so the USB emulation on the digispark gives up when the computer goes to sleep. I don't know what settings would need changing (if it is possible to fix in software).