Code snippet showing typical switch statement for hardware.wakereason(). In this example we're just logging the reason to the debug window, but we *could* be performing various tasks based on how the imp was woken up.