Programming help - Tilt switches as keyboard

Do you want to output a stream of characters while the A lever IS pressed? Or do you want to output one character when the A lever BECOMES pressed (or released)? If you want one character when the lever changes position, see the state change detection example.