Closer… So, yea I meant what you said about the desktop app and accepting connections…
I'm doing this on the desktop teacher app to start the socket: on mouseUp accept connections on port 5600 with message "someoneConnected" end mouseUp on someoneConnected theIP read from socket theIP until return with message "newMessage" end someoneConnected on newMessage theIp theMessage put theIP & ":" && theMessage & return after field "text" read from socket theIP until return with message "newMessage" end newMessage On the client iOS app the mergeBonjour is working fine, but I don't have the rresocket script down. Here's what I've tried: (two buttons) First button, on mouseUp rreSocketOpen "10.58.0.56:5600" put the result into fld "result" end mouseUp (and assorted variations of that…) Second button, on mouseUp rreSocketWrite field "message" & return, "10.58.0.56:5600" put the result into fld "result" end mouseUp (and also assorted variations of that…) Am I close? Thank you! John Patten SUSD On Dec 21, 2012, at 1:22 PM, Monte Goulding <mo...@sweattechnologies.com> wrote: > Forgot to answer this bit: > On 22/12/2012, at 8:05 AM, JOHN PATTEN <johnpat...@me.com> wrote: > >> I also have mergeBonjour working to discover the new registered service in >> the iOS simulator, so far so good. >> >> My next step is to open a socket on the desktop app with the correct port, >> just like normal: >> >> open socket to "localhost:5600" >> if the Result <> "" then >> put "result:" && the result >> end if > > nope... look at the accept connections command. And you want to accept > connections on the port you advertise the service on. >> >> Then to use the rresocket external to open a connection on the iOS device, >> and write the data/text out to the open port on the desktop app. Not sure >> what to make about the read me in the rresocket folder? Not sure what "Tail >> commands" are and the demo that is included appears to be broken. >> >> What would the rrsecocket commands look like on my iOS app to open a >> connection to my desktop app and then write out some data to that desktop >> app? > > You don't need to worry about if the command is tail or not. That's just for > the external. Basically, get the ip and port from mergBonjour then open a > socket and write to it when you get the callback after opening then close or > read from it when you get the callback after the write. On the desktop you > accept connections with message and when the message is triggered you read > from the socket then close or send a response etc. > > Cheers > > -- > Monte Goulding > > M E R Goulding - software development services > mergExt - There's an external for that! > > > > > > _______________________________________________ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your subscription > preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode _______________________________________________ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode