Is there any way to create a background service (or driver or anything else) can control the mouse or keyboard or touch screen event of the android? I saw there was some remote controlled android TV, so how did they achieve that which is using remote controller to show mouse cursor and others?
I'm pretty sure this is specific to Google TV. Mouse events are faked. Check out the Anymote Protocol documentation for details on how to remotely control your GTV device.
It's also discussed a bit in this GTV doc.