Bluetooth service search on Motorola L7

Hi,

I'm trying to get Bluetooth service search working on my Motorola MOTOSLVR L7 from a J2ME MIDlet.

I have a test application which searches for all remote devices. For each device it then search for services matching the SPP UUID (0x1101). Every found service is reported.

I have other devices in the surroundings providing SPP services, and I can find them when running the MIDlet on other phones. However when I run it on my L7, the method DiscoveryListener.serviceSearchCompleted() always returns with the response code SERVICE_SEARCH_NO_RECORDS. It never finds any services on remote devices. What could be the problem?

Some brief code pieces:

agent = localDevice.getDiscoveryAgent();

agent.startInquiry(DiscoveryAgent.GIAC,this);

Found devices reported through DiscoveryListener.deviceDiscovered() are added to a vector.

After DiscoveryListener.inquiryCompleted() has been called services are searched for each remote device, sequentially:

remote = (RemoteDevice) devices.elementAt(i);

agent.searchServices(null,new UUID[]{new UUID(0x1101)},

remote,this);

When DiscoveryListener.serviceSearchCompleted() is called, the response code is printed to screen.

Cheers,

Erik

[1459 byte] By [Esdna] at [2007-11-26 16:06:34]
# 1
Try to use this one:private static int[] attrSet;agent.searchServices(attrSet, new UUID[] { new UUID(0x1101) },remote, this);
junaid-shabbira at 2007-7-8 22:28:45 > top of Java-index,Java Mobility Forums,Java ME Technologies...
# 2

Thanks for your reply. I have tested it with the attribute for service names, i.e.

attrSet = new int[]{ 0x0100 }; // Service name

It didn't help, though.

Esdna at 2007-7-8 22:28:45 > top of Java-index,Java Mobility Forums,Java ME Technologies...