Alex Rivera | Logout

How can i Open Serial Port of Dock connector in iOS 5.0.1

Asked 2011-12-05T12:18:56.800
13

I can successfully open the serial port of iPhone/iPad in lower version than iOs 5. with the use of

open("/dev/tty.iap", O_RDWR | O_NOCTTY | O_ASYNC))

but i got error "Operation not permitted" in iOS 5 .

(I used the Serial Programming for communicating accessory and iPhone)

Is there any one have idea about this.

Thanks.

Edit
Report

1 Answer

0

Not sure if you got this working, but from what I have read you can not access the iPhone's serial port for communication while your app is in the sandbox. By sandbox, I mean when you click "run" in Xcode and transfer your app to your iDevice the app lives in a sandbox environment. This environment prohibits your app from accessing things such /dev/tty.iap the serial port within the dock connector. One solution I have read is to copy your app /Applications/which is a link to the location /var/stash/Applications.XXXXXX/ which should take your app out the sandbox environment, and give it access to /dev/tty.iap Let me know if this works for you as this is something I am eventually going to have to do with the app I am developing.

answered 2012-07-19T23:01:40.547

Your Answer