Available service types in WifiP2pDnsSdServiceInfo.newInstance

I am programming an Android application that uses Wifi Direct. I am trying to start a service and I am calling WifiP2pDnsSdServiceInfo.newInstance. However, I was looking for different types of services that I could use, and so far I only found "_presence._tcp".

I understand that I need to somehow find a type of service that "makes sense" with what my application is trying to execute. Can I just β€œinvent” it? Is there a list of protocols available?

Thank you so much!

+2
android service wifi-direct
source share
1 answer

The Android documentation contains some information to get you started in Using Network Services Discovery . Accordingly, the type of service indicates which protocol and transport layer the application uses. Syntax _<protocol>._<transportlayer> . Thus, you should use only existing transports in the second part. The most commonly used are tcp and udp , of course.

As for the first part, there are many application-level protocols. For example, presence is the messaging protocol from xmpp.org, and ipp is the printer service. You can find a more or less complete list of registered protocols at dns-sd.org . You can also look at the registry of service names at iana.org .

Because the DNS-based discovery service is part of a zero-configuration network that has many implementations, additional protocol lists can be found at specific vendors. For example, here is a list of Apple Bonjour service types .

I do not think that there is one exhaustive list of protocols used around the world. However, I assume that you could come up with your name with a fairly permeable basic structure (acronyms and / or semantics) - just do a search on the Internet and make sure your name does not appear with respect to Zeroconf and DNS-SD.

+4
source share

All Articles