Skip to main content

ZeroConf/Bonjour/multicast on CLDC1.1/MIDP2.0?

5 replies [Last post]
luposlip
Offline
Joined: 2007-05-13
Points: 0

Hi there gurus,

Does anyone know if it is somehow possible - using 3rd party api's or in any other way - to let a CLDC1.1/MIDP2.0 compatible phone (Nokia N95) support multicast IP/multicast DNS as used in such frameworks as Apple's ZeroConf/Bonjour API?

What I need seems like what is contained in JSR 259 (http://jcp.org/en/jsr/detail?id=259), but it's very hard to tell when the JSR and it's RI will be done, not to mention when devices will be shipped with it.

I know that it is possible to make the hardware support multicast DNS (as specified in JSR 259), but I don't know how to do it from Java.

Anyone?

Thanks in advance.

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
kathy1
Offline
Joined: 2010-04-22
Points: 0

> No, I haven't tried the multicast socket on two
> phones, because according to CLDC documentation, the
> standard doesn't support multicast, and therefore it
> shouldn't work.

I am trying to find the CLDC documentation on the multicast. Can you send me the link? Thanks a lot

sfitzjava
Offline
Joined: 2003-06-15
Points: 0

Hi,
Have you tried setting up a Multicast socket on two phones under the same provider? (I would be interested in the results). However looking at JSR-259 they are talking in the JXTA style P2P, which is really P to some server(s) that I've told it about to another P that also knows of these same servers... doesn't sound to p2p to me. ;)

I've looked at this concept a bit, and the issue is going to be firewalls that the operators setup. And this is the same hurdle you have with any multicast IP setup, when you jump subnets you loose visibility.

A possible solution might be to use something like SIP. Again you have to have a central server that everyone talks with, but you might be able to use that as your multicast/broadcast point back out to the listening phones, then either switch to a point2point socket for 2 devices to talk, or conference via the sip server.

I hear Ericsson has a IMS server they open sourced or something that runs on glassfish. :) FYI..IMS is a telco type of SIP server. You might be able to just use a SIP server.


let us know your findings...sounds like an interesting concept.

-Shawn

luposlip
Offline
Joined: 2007-05-13
Points: 0

No, I haven't tried the multicast socket on two phones, because according to CLDC documentation, the standard doesn't support multicast, and therefore it shouldn't work.

In my current physical setup, I can't have a physical server with SIP/IMS. So it's not a possible solution in my case. Good idea though.

Thanks for the reply anyway.

sfitzjava
Offline
Joined: 2003-06-15
Points: 0

Yes there are some definite hurdles there, and as defined in JavaSE, true there is no multicast support, however there is UDPDatagramConnections. Now you might want to try and setup a socket to a multicast IP address. You might try running them both as clients, or the server device run it to mask off anything from an IP other than the multicast ip you are using.

As for SIP/IMS servers, you don't have to have access to one yourself. You could use a public available one...like AIM, YahooIM, Gizmoproject. All of these have a type of sip protocol, and gizmoproject is a sip server. If devices can get to an outside network and make a connection on those sip socket then you have a stable sip server at your disposal. :)

Now looking back at your original post this project may be what you are looking for: http://jxta-jxme.dev.java.net/

Never say die!! :)

-Shawn

luposlip
Offline
Joined: 2007-05-13
Points: 0

Well, I might just try that, with the UDPDatagramConnection. But I still don't think I can have the true peer-to-peer networking work in CLDC1.1/MIDP2.0 environments.

The SIP server idea is good. But unfortunately not applicable for my purposes, as no internet/WAN network is available during runtime of the application.

I've looked at JXTA-ME. It only works when the device is connected to a rendezvouz (in other words: JXTA-ME only works _proxied_ on CLDC devices, and _proxyless_ on CDC devices).

When the JXTA-ME team can't get JXTA to work on CLDC, I don't think I can either. But; if it is possible to "hack" a CLDC device, and add the CDC functionality to a CLDC device (which has all the needed hardware in place), it could be the solution I'm looking for.