add powerswitch in flash script