Completed keypress addition for state machine test4.