Leigh Hunt
Leigh Hunt

Reputation: 1

Invoke keystroke on my mac laptop from my iPad app

I am struggling at the moment to find any documentation regarding how one might invoke keystrokes from my iPad app to my laptop.

I have a good understanding of connecting to my laptop via wifi, to this point transmitting and receiving midi and osc messages, but after a two days of searching the net and dev documentation I just cannot figure where to start with the keystroke emulation and transmission.

I know this can be done as I have the touchpad app, which is great, but I simply need to be able to handle a few specific keystrokes from within my app, i.e. tab key, esc key.

I can see that it could be implemented by creating a small 'receiver' app on my laptop, but this seems like a cumbersome way of going about things.

If anyone can point me in the right direction for documentation or resources to help me, I should be eternally grateful!

Thanks

Upvotes: 0

Views: 306

Answers (2)

AnonymousPlayer
AnonymousPlayer

Reputation: 106

If you want a simple app that will do this you can use the following paid apps for the iPad that will do VNC, and you don't have to worry about the programming. Right out of the box you can send any keystrokes and mouse clicks. 1.-iTapVNC or similar 2.-iTeleport There are many more, just search VNC on the app store in the iPad.

There is another simple way of doing it without VNC but with Networking, using Networking and Bonjour to connect your iPad to another program in the Mac. iPad acts as client and Mac acts as Server. Use could also try using gameCenter, which simplifies a lot of the overhead in Networking. n This method will be much faster because you don't need the overhead of getting the screen in your iPad.

There is a very good tutorial with a complete working applications in the following link. http://mobileorchard.com/tutorial-networking-and-bonjour-on-iphone/

If you want to check out gamecenter that has peer to peer connectivity her is the initial guides. https://developer.apple.com/library/ios/#documentation/NetworkingInternet/Conceptual/GameKit_Guide/Introduction/Introduction.html

Hope this helps.

Upvotes: 0

Peter M
Peter M

Reputation: 7513

OS X includes a VNC server (which in effect acts as you "small receiver app"), so all you have to do is implement the part of the Virtual Network Computing (VNC) stack that transmits key strokes.

VNC uses the RFB protocol of which lots of information can be found at Real VNC® documentation

Upvotes: 1

Related Questions