Bluetooth Mobile App - Pair with Digital Pen

Hi!

First a short Introduction:

For a project I have to stream data from Maxell Penit DP201(4.1) to a mobile device (over a midlet). Data Connection is built up over Bluetooth.

My Questions are: Is btl2cap the right method for connecting digital pen and mobile phone?

If yes, is the btl2cap string correct?

The pens device adress is 00-07-CF-56-05-5D

Does anyone know a sample application like this I want to program?

Structure;

package /

Midlet

Class extending thread

Here's the code:

publicvoid run(){

[...]

//Bluetooth

//String connString = "btspp://0007808303AA:1;master=false";

String connString ="btl2cap://localhost:0007cf56055d;ReceiveMTU=512;TransmitMTU=512";

System.out.println(connString);

try{

LocalDevice local = LocalDevice.getLocalDevice( ) ;

// build ServiceRecord

local.setDiscoverable(DiscoveryAgent.GIAC);

L2CAPConnectionNotifier service = (L2CAPConnectionNotifier)

Connector.open(connString);

ServiceRecord sr = local.getRecord(service);

// accept Connection

L2CAPConnection connection = (L2CAPConnection ) service.acceptAndOpen( );

}catch (Exception e){

e.printStackTrace();

}

Thanks to all who can help me to reach the next step in my project.

Best regards

[1792 byte] By [Sha-dowlia] at [2007-11-27 5:16:40]
# 1
Hi,I am trying to do exactly the same, did you got any further with this issue?Would be very grateful for any helpThx
Julodnika at 2007-7-12 10:39:27 > top of Java-index,Java Mobility Forums,Java ME Technologies...
# 2
Hi Julodnik.Sorry, but I did not get any further. Even intensive google searches were useless.Seems that no one has a java sample for streaming bt data from a digital pen
Sha-dowlia at 2007-7-12 10:39:27 > top of Java-index,Java Mobility Forums,Java ME Technologies...