Key power circuit design for portable devices