Author Topic: Bluesoleil wclOPPServer issue  (Read 26891 times)

robple11

  • Guest
Bluesoleil wclOPPServer issue
« on: June 29, 2010, 08:45:33 AM »
Hi,

I tried to create an wclOPPServer using a custom UUID and a channel number of 20, this works fine in Microsoft BT stack but when i try the same code on Bluesoleil it creates an SPP profile instead of an OBEX one and doesnt give me channel 20 but some other one it allocates.
I have written a J2ME app for a phone to search services, when i search for my custom service and its running Microsoft it returns "btgoep://....." (which is OBEX), but when i use Bluesoleil it returns "btspp://...." and this is not an OBEX service!

Any ideas why this is happening?

I tried this on both Bluesoleil 1.6 and the latest 6.4.314.0

here is the code for my wclOPPServer:
                    wclOPPServer.Transport = wcl.wclServerTransport.stBluetooth;
                    wclOPPServer.BluetoothParams.Radio = m_radio;
                    wclOPPServer.BluetoothParams.Name = "OBEXTest";
                    Guid gd = new Guid("{34db2a3e-f13a-8bc1-e341-2ab6e4fd11ae}");
                    wclOPPServer.BluetoothParams.Service = gd;
                    wclOPPServer.BluetoothParams.Channel = 20;
                    wclOPPServer.BluetoothParams.Authentication = false;
                    wclOPPServer.BluetoothParams.Encryption = false;
                    wcl.wclErrors.wclShowError(wclOPPServer.Listen());


robple11

  • Guest
Re: Bluesoleil wclOPPServer issue
« Reply #1 on: June 29, 2010, 09:29:18 AM »
Another problem i just found related to this issue, i tried to send a text file using FTPClient to the standard FTP service of the phone using Buesoleil and it just times out in the end.
The code is shown below:

                    wclFTPClient.BluetoothParams.Address = wclClient.BluetoothParams.Address;
                    wclFTPClient.BluetoothParams.Radio = m_radio;
                    wclFTPClient.BluetoothParams.Service = wcl.wclUUIDs.OBEXFileTransferServiceClass_UUID;
                    wclFTPClient.BluetoothParams.Authentication = false;
                    wclFTPClient.BluetoothParams.Encryption = false;
                    wclFTPClient.Transport = wcl.wclClientTransport.ctBluetooth;
                    wcl.wclErrors.wclShowError(wclFTPClient.Connect());

        private void wclFTPClient_OnConnect(object sender, wcl.wclConnectEventArgs e)
        {
            int ret = wclFTPClient.OpenOBEXSession();
            if (ret > 0)
            {
                // phone denied it or ignored it
                this.m_inboxnotify = true;
            }

        }

        private void wclFTPClient_OnOBEXConnect(object sender, wcl.wclConnectEventArgs e)
        {
            m_cmdbuff = Encoding.ASCII.GetBytes("Testing the FTP to phone feature!");
            System.IO.MemoryStream Stream = new MemoryStream(m_cmdbuff);
            String AFile = "TestMsg.txt";
            wcl.wclErrors.wclShowError(wclFTPClient.Put(AFile, Stream));
        }
 
Using the Microsoft BT Stack this all works fine.

Any ideas?

Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Bluesoleil wclOPPServer issue
« Reply #2 on: June 29, 2010, 10:09:13 AM »
First problem is here: wclFTPClient.BluetoothParams.Authentication = false;
Phone must be paired.

robple11

  • Guest
Re: Bluesoleil wclOPPServer issue
« Reply #3 on: July 01, 2010, 03:28:23 AM »
Hi,

The phone is paired with the computer. I double checked this, but still doesnt work.
I see the bluetooth icon in the tray go green and the phone's bluetooth icon changes to a transferring data symbol, so obviously they are connecting, but nothing is sent.
Then after a while it comes up with a "WCL error: OBEX session not active".

I also tried changing wclFTPClient.BluetoothParams.Authentication = true and also removing it completely but all failed as well.

Any other ideas?

Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Bluesoleil wclOPPServer issue
« Reply #4 on: July 01, 2010, 03:32:39 AM »
Hi,

Of course. First idea is in error message. Open OBEX session first. Second one: this thread was about wclServer, it is very bad idea to post questions about wclClient int wclServer thread.

Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Bluesoleil wclOPPServer issue
« Reply #5 on: July 01, 2010, 03:34:19 AM »
What is your BS version?

robple11

  • Guest
Re: Bluesoleil wclOPPServer issue
« Reply #6 on: July 01, 2010, 03:55:17 AM »
BS version is 6.4.314.0

I do open an OBEXsession, but i thought you have to connect first.

This is what i do first:
wclErrors.wclShowError(wclFTPClient.Connect());

Then in the onConnect function i do:
int ret = wclFTPClient.OpenOBEXSession();

Then in the onOBEXConnect i do:
            m_cmdbuff = Encoding.ASCII.GetBytes("Testing file transfer!");
            System.IO.MemoryStream Stream = new MemoryStream(m_cmdbuff);
            String AFile = "TestMsg.txt";
            wcl.wclErrors.wclShowError(wclFTPClient.Put(AFile, Stream));

Dont forget that this code works on Microsoft Stack perfectly.
I also tried using wclClient and wclOPPClient with same problem, and also tried wcl.wclUUIDs.OBEXObjectPushServiceClass_UUID instead of FTP but still same problem.

Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Bluesoleil wclOPPServer issue
« Reply #7 on: July 01, 2010, 10:26:45 PM »
Thanks, going to download your BS version and test. I'll back to you soon.

Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Bluesoleil wclOPPServer issue
« Reply #8 on: July 02, 2010, 02:50:29 PM »
Hi,

Have tested and could reproduce the issue. Not sure why but sending data back from BS to PC does not work. Looking on it now and hope to get it fixed in a couple of days.

Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Bluesoleil wclOPPServer issue
« Reply #9 on: July 03, 2010, 11:35:47 PM »
Hi,

The issue has been fixed. Contact us on support@btframework.com with your order # and we will send you a fixed copy.

Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Bluesoleil wclOPPServer issue
« Reply #10 on: July 04, 2010, 09:17:07 AM »
Ok, the issue has been fixed for SPP only. BluSoleil allows to connect to SPP only now (without using there high-level APIs). But it is not applicable for WCL as it does not allow to support any won services as well as OPP/FTP. So we will think about workaround but I afraid it is not possible as each next version of BS adds lots of new BUGS but no one previouse fixed.

robple11

  • Guest
Re: Bluesoleil wclOPPServer issue
« Reply #11 on: July 05, 2010, 06:17:17 AM »
Did you find out why the OPPServer was coming up on the phone as a "btspp" service and not a "btgoep" service?


Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Bluesoleil wclOPPServer issue
« Reply #12 on: July 05, 2010, 09:45:58 AM »
No one service shows as GOEP as it is GENERAL Object Exhcange Profile. It has only Specification - nothing more.
OPPServer can not appears as SPP as it is OBEX (on BS it can as BS does not creat valid SDP records for service).
And of course, all supported by WCL profiles are RFCOMM based. But DO NOT mix RFCOMM and SPP. It is very different things.
And I DID NOT looking on it as all "normal" stacks do all it should to create VALID SDP. BlueSoileil is worst one and we are thing about stop support it in future versions.

robple11

  • Guest
Re: Bluesoleil wclOPPServer issue
« Reply #13 on: July 05, 2010, 11:12:13 AM »
Sorry if you have explained this already but i just need to clarify this:

if the wclOPPServer service shows as a "btspp:\\" service on the phone, can i still connect to the service and send OBEX data across the link successfully?

I have done this before between two phones, sending OBEX data across an SPP service.

I will send an email tomorrow to get the new version because the order# is on my work PC.

Thanks again.

Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Bluesoleil wclOPPServer issue
« Reply #14 on: July 05, 2010, 11:18:17 AM »
You are mixing different things but yes, you can do so if use valid channel number. (In Java all RFCOMM is btspp - that is why we do not use Java in our development as well as any other managed languages).

 

Sitemap 1 2 3 4 5 6 7