Power management API?

Discussion in 'Mac Programming' started by staticfloat, Dec 13, 2009.

  1. staticfloat macrumors newbie

    Joined:
    Dec 13, 2009
    #1
    Hey guys, I'm a fairly new developer to mac, and this may not be the best forum to ask this on, but here goes;

    I need to write an application that will wake my macbook pro up from sleep every so often, and then put it to sleep again. Something very similar to the SleepX program that is included with the Xcode dev tools. I tried using the Power Management DDK sample "wakein", but it seems it cannot find a PMU in my macbook pro, therefore there must be some other way of doing this. Does anyone know how SleepX does this/can anyone point me to a place where someone might know?

    Thanks!
     
  2. larkost macrumors 6502a

    Joined:
    Oct 13, 2007
    #2
    I don't know about true programatic access, but from the command line you can do this with 'pmset'. 'man pmset' for more information.
     

Share This Page