Welcome ![]()
Look at the bottom of this page, it may help you wiring and coding
http://www.ladyada.net/learn/sensors/pir.html
For the keystroke I suppose you will have to use Serial.write and also write your own key simulation library, shouldn't be too hard, but I don't know, I'm also a beginner ![]()