×

Discussion Board

Results 1 to 2 of 2
  1. #1
    Registered User
    Join Date
    Dec 2005
    Posts
    4

    Service registering problem with 6600

    I use the code beneath to register my service, this works fine on a 6680. But when i try to use it on a nokia 6600 the server could not connect to it.

    The first message to the server includes the connection string to the service on the client obtained by the following code
    ServiceRecord sr = localDevice.getRecord(notifier);
    connectionString = sr.getConnectionURL(ServiceRecord.NOAUTHENTICATE_NOENCRYPT, false);

    The Server uses this connection string but couldn't connect to the 6600. It gets: java.io.IOException: Failed to connect socket

    Registration code:
    ...
    private static final String clientUuid = "3def3def3def3def3def3def3def3de0";
    private static final String serviceName = "BlueMusicClient";
    ...
    // install Bluetooth service
    String url = "btspp://localhost:" + clientUuid + ";name=" + serviceName;
    try {
    notifier = (StreamConnectionNotifier) Connector.open(url);
    } catch (IOException e) {
    // TODO ERROR Handling
    e.printStackTrace();
    }

    StreamConnection con = null;
    acceptConnections = true;

    ByteArrayOutputStream message = new ByteArrayOutputStream();
    InputStream is;

    int b;

    while (acceptConnections) {
    try {
    // block until client connects
    con = notifier.acceptAndOpen();

    is = con.openInputStream();
    message = new ByteArrayOutputStream();

    while ((b = is.read()) != -1) {
    message.write(b);
    }

    is.close();
    con.close();

    } catch (IOException e) {
    // TODO error handling
    }
    }
    }


    Any help highly appreciated
    woodi

  2. #2
    Registered User
    Join Date
    Mar 2006
    Posts
    11

    Re: Service registering problem with 6600

    Did you ever get this working? I am having the same problem, but on a 6630. It works on 6680 though.

Similar Threads

  1. 6600 PC Suite Install problem
    By pcarew in forum PC Suite API and PC Connectivity SDK
    Replies: 2
    Last Post: 2006-08-10, 21:08
  2. Nokia 6600 Socket Server send delay Problem
    By dicson_hu in forum Mobile Java Networking & Messaging & Security
    Replies: 1
    Last Post: 2005-10-31, 07:37
  3. 6680 and bluetooth service profiles
    By ceruault in forum Mobile Java Networking & Messaging & Security
    Replies: 1
    Last Post: 2005-10-08, 22:24
  4. J2ME, JSR-82, Nokia 6600, SPP problem.
    By bokiteam2001 in forum Mobile Java Networking & Messaging & Security
    Replies: 0
    Last Post: 2005-08-24, 10:01
  5. Replies: 3
    Last Post: 2004-04-26, 14:58

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×