ofSerial headache.

I will start by saying that about 6 months ago with a build of OpenFrameworks I downloaded perhaps about a year ago so 6.1 perhaps and with an older version of Xcode and with a different iPhone running on older firmware this worked beautifully.

Ok to the problem, I have an iPhone an RFID reader some circuity and then OF opening up the serial port taking the data and processing it how I needed. (I am a PhD student at Tokyo Institute of Technology using it for a rather specific purpose). Now I used it for my MSc in England on the older architectures and as I said it worked fine, now I have moved to Japan, purchased a Japanese iPhone a Japanese Mac and am using the updated versions of both OF and Xcode its throwing a few errors.

What is meant to happen is it takes the data sent by the RFID reader converts it into a string then does a string compare to specified cards in a database. So the code has not changed however to save space I just saved and brought with me the actual coding not the old architecture. So I downloaded Xcode downloaded OF and tried applying the code to an example.

Huge EDIT,

I found a copy of an old working version of my code that worked fine and once installed on the iPhone acts different than it used to. This leads me to believe there is something different with either the Japanese iPhone the jailbreak that has been applied or the new firmware does something different with the iPhone data.

Still any help appreciated.

Thanks, Z

hi Zaffro,

welcome to the openFrameworks forum! glad you found us, this is the main place for getting support with using openFrameworks. sorry we took a little while to respond to your earlier queries, many of us are super busy with projects ourselves :wink:

there’s also an IRC channel #openframeworks on freenode, you can use a web interface to access it here http://en.irc2go.com/webchat/?net=freenode&room=openframeworks . it’s not always very full but you can try asking for help there also. and there’s documentation and tutorials on the website at http://openframeworks.cc although i guess you’ve found those already. and for programming problems not specific to openFrameworks but more about, how would i achieve this effect in code in general, you could try also asking your question in the Processing forums at http://forum.processing.org/ (Processing and openFrameworks are very similar so a solution that works in Processing can usually be adapted to work in openFrameworks) and StackOverflow at http://stackoverflow.com .

so, for your question: what exactly is happening differently this time that wasn’t happening before? it’s a little bit unclear from your message how the iPhone is accessing the serial port, as the iPhone doesn’t officially have a serial connection. or is the ‘circuit’ that you mention include an RS232 device that allows you to talk to a serial port on a separate computer?

in any case i would suggest using the newest version of openFrameworks if you can. if you’re not using any addons you can copy the emptyExample project files from the new version and use that as the basis for rebuilding your project. any errors related to new version of openFrameworks can be a pain to deal with but they are always fixable.

I’ve only ever been able to get serial working properly on a jailbroken phone or by using something like this: http://www.makershed.com/Redpark-Serial-Cable-for-iOS-p/msrp01.htm

I’m a bit fuzzy on how iOS prevents you from using Serial without an authorized device, but I think it isn’t something that you can do natively in your code unless you have some kind of UID that iOS accepts as a valid authorized device. That might have worked in previous versions of iOS, but I’ve been under the impression that the phone either needed to be jailbroken or using an authorized device for Serial.