![]() To successfully discover apps running in the Simulator, Reveal needs to be able to resolve localhost host name. Kevin has also published a similar app for the iPhone which is available on the iOS App Store for free. You can use Discovery to try and get at the same information we collected via the dns-sd command above, without having to use the command line. Kevin Ballard at TildeSoft provides a simple Mac GUI for showing all the Bonjour services being advertised on your network. Try rebooting your Mac if mDNSResponder is not running. If you are getting errors, there may be something wrong with your network setup: Bonjour may be blocked, or the Bonjour daemon ( mDNSResponder) is not running correctly. Note: The dns-sd commands above should not give you errors and should not need to be run as 'root' (or via sudo). The host may also be listed as an IP address rather than as a hostname. When run on an actual iOS device it will bind to the public network interfaces on that device. When run in the iOS Simulator the Reveal framework always binds to localhost (127.0.0.1). The Reveal framework randomly picks a port number so it will be different each time you run your app. In the example above you will see that the app is listening for connections on port 51441 and host localhost. can be reached at localhost.:51441 (interface 0) Flags: 2ĭevName=iPhone\ Simulator devSysVer=7.1 appName=RevealSample devSysName=iPhone\ OS isSim=true devLocalModel=iPhone\ Simulator appBundleId= protoVer=14 Here is the expected output from dns-sd: Lookup Reveal-bcea6fb9._reveal._tcp.localġ0:47:29.924 Reveal-bcea6fb9._reveal._tcp.local. You will need to substitute your own app's Instance Name (which you got from the previous command) when using this command. You can do this using the following command: dns-sd -L Reveal-93cf9fec _reveal._tcp. Now we need to find out what port your app is listening on for Reveal connections. Press Control-C to stop browsing for services with dns-sd. Your app's Instance Name name will be different. The code at the end of the Instance Name is used to make each Reveal app on your network be unique. You can see in the example above that there is one app being advertised with the instance name Reveal-bcea6fb9. This is also true of the other dns-sd commands listed below. It has not: you need to type Control-C to quit. If it doesn't print out much output it might look like it has just locked up. Reveal-bcea6fb9 Note: dns-sd doesn't exit immediately. Timestamp A/R Flags if Domain Service Type Instance Nameġ0:42:34.746 Add 3 4 local. You should see output similar to this: Browsing for _reveal._tcp.local To do so, open Terminal and issue the following command: dns-sd -B _reveal._tcp local You can use the dns-sd tool on your Mac to list any apps currently running the Reveal framework. Reveal publishes itself as a Bonjour service from within your iOS app using the service type _reveal._tcp. Here are some tips on how to debug network issues relating to Bonjour & Reveal: Reveal Bonjour Service Discovery Reveal is Starting but I still can't connect. See the Integration guide in the Reveal help menu for details on how to link with the Reveal library correctly. If you don't see this message, Reveal is not starting (or you have disabled Reveal's logging via its API). When Reveal starts it logs the following message to the console: 22:11:58.228 RevealSample INFO: Reveal Server started (Protocol Version 18). The first thing to do is check the Reveal library is linked into your app correctly. If you're having trouble connecting to your application with Reveal, the following steps may help diagnose if the issue lies with Bonjour's Service Disovery.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |