There are times you want to test your program that has to wake up the phone and disable Keyguard. It is always better to test in emulator first. But, the emulator, by default, is only dimmed after minutes of no actions. You can make the screen off by sending ac off command in the console,
telnet localhost [emulator-port] # 5554 by default power ac off