locked
win8.1 bluetooth server service, the difference abput paired the bluetooth between before starting the server and after the bluetooth

    Question

  • when I write a bluetooth server on the win8.1 pc , I want know that , 

    if I paired the device before the bluetooth server start , does the cilent could find the server service ?

    or if I paired the device after the bluetooth server start , does the cilent could find the server service ?

    so , could you tell me the difference between before and after start the bluetooth server on win8.1 pc?

    Tuesday, November 18, 2014 4:32 PM

Answers

  • Hi RainGuy,

    Please do not post duplicate questions in the forum.

    I would like to ask how you test the app, I shared with you a Bluetooth Rfcomm chat sample and I don't know if you have tried that.

    Let's make things more clear, in your PC(server side), we should run the C# sample, because it can be treat as a server, and I deploy the HTML sample on my phone(client side), so that I can talk to my server.

    I would make screenshot for you for how the sample works

    Server side:

    Client Side

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Wednesday, November 19, 2014 6:52 AM
    Moderator
  • For the pairing, we should do following steps:

    1, Pairing the PC and Device before running the app.

    2, Start the Server side, click the "start listening" button.

    3, Start the Client side, click the "pairing" button

    4, here we go, we can communicate now.

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Wednesday, November 19, 2014 6:56 AM
    Moderator
  • A possibility is you host both server and client app on the same device, but the device only have one Bluetooth access point, that could be the problem.

    Could you tell us your environment in detail? The capability looks fine I cannot see any problem. Besides, in the server sample, the m2:Function Type is something like this, but I think name should be fine ref to How to specify device capabilities for Bluetooth:

        <m2:DeviceCapability Name="bluetooth.rfcomm">
          <m2:Device Id="any">
            <m2:Function Type="serviceId:34B1CF4D-1069-4AD6-89B6-E161D79BE4D8" />
          </m2:Device>
        </m2:DeviceCapability>

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Wednesday, November 19, 2014 7:00 AM
    Moderator

All replies

  • I use peerfinder to find my my devices service on my win8.1 PC, but the method return "access denied error " ,

    I have done the Capabilities like this :

      <Capabilities>
        <Capability Name="internetClientServer" />
        <Capability Name="privateNetworkClientServer" />
        <DeviceCapability Name="proximity" />
      </Capabilities>

    so , does anyone could give me some advise about this error ?

    Tuesday, November 18, 2014 9:26 AM
  • when I build the bluetooth  rfcomm app  , I debugging the client and server app on the visual studio  at the same time , but the client couldn't find the server service . I add the capabilities like this both the server and the client :

        <Capability Name="internetClientServer" />
        <Capability Name="privateNetworkClientServer" />
        <DeviceCapability Name="proximity" />
        <m2:DeviceCapability Name="bluetooth.rfcomm">
          <m2:Device Id="any">
            <m2:Function Type="name:obexObjectPush" />
          </m2:Device>
        </m2:DeviceCapability>

    could help me to let the client app to  find the server app servie over the bluetooth on win 8.1 

    Tuesday, November 18, 2014 12:57 PM
  • could you tell me that what's the meaning about the pairing action ?

    Tuesday, November 18, 2014 4:34 PM
  • Hi RainGuy,

    Please do not post duplicate questions in the forum.

    I would like to ask how you test the app, I shared with you a Bluetooth Rfcomm chat sample and I don't know if you have tried that.

    Let's make things more clear, in your PC(server side), we should run the C# sample, because it can be treat as a server, and I deploy the HTML sample on my phone(client side), so that I can talk to my server.

    I would make screenshot for you for how the sample works

    Server side:

    Client Side

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Wednesday, November 19, 2014 6:52 AM
    Moderator
  • For the pairing, we should do following steps:

    1, Pairing the PC and Device before running the app.

    2, Start the Server side, click the "start listening" button.

    3, Start the Client side, click the "pairing" button

    4, here we go, we can communicate now.

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Wednesday, November 19, 2014 6:56 AM
    Moderator
  • A possibility is you host both server and client app on the same device, but the device only have one Bluetooth access point, that could be the problem.

    Could you tell us your environment in detail? The capability looks fine I cannot see any problem. Besides, in the server sample, the m2:Function Type is something like this, but I think name should be fine ref to How to specify device capabilities for Bluetooth:

        <m2:DeviceCapability Name="bluetooth.rfcomm">
          <m2:Device Id="any">
            <m2:Function Type="serviceId:34B1CF4D-1069-4AD6-89B6-E161D79BE4D8" />
          </m2:Device>
        </m2:DeviceCapability>

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Wednesday, November 19, 2014 7:00 AM
    Moderator
  • Hi James ,

    Thanks very much , finally I resolved the problem ,

    I declared a new serviceId  by the server , but I paired the Bluetooth before the server start ,

    so the Bluetooth couldn't get the service from the server ,

    I paired the Bluetooth after the server start , then the client could find the service ,

    so the issue fixed .

    Friday, November 28, 2014 2:29 AM