poland
Posts: 24
Joined: Thu Apr 02, 2009 6:22 pm

Send file without discovery any device

Fri Apr 03, 2009 12:35 am

I have one more question. Is this possible to connect and push some file to device without discovery device? If i only have MAC address and name of device how can I do that?

Jonas
Posts: 2319
Joined: Mon Jan 09, 2006 2:20 pm
Location: Sweden

RE: Send file without discovery any device

Fri Apr 03, 2009 8:38 am

Yes, look at the ObexFTPClient. It shows how to do Connect to a device without device discovery.

Regards,
Jonas

poland
Posts: 24
Joined: Thu Apr 02, 2009 6:22 pm

RE: Send file without discovery any device

Fri Apr 03, 2009 1:38 pm

so why it doesnt work?

object mac = "00:17:83:B4:8B:94";
Franson.BlueTools.Address mac1 = (Franson.BlueTools.Address)mac;
art[1] = (RemoteDevice)m_network.ConnectDevice(mac1, "HTC_TyTN_II");

Jonas
Posts: 2319
Joined: Mon Jan 09, 2006 2:20 pm
Location: Sweden

RE: Send file without discovery any device

Fri Apr 03, 2009 3:28 pm

Because the syntax isn't like that. An Address object isn't simply a text string. Look at the ObexFTPClient.

Regards,
Jonas

poland
Posts: 24
Joined: Thu Apr 02, 2009 6:22 pm

RE: Send file without discovery any device

Fri Apr 03, 2009 4:41 pm

I saw this example, but i still dont understand how the right syntax is:( Please give mi some example how to link together MAC address of given device and this one :

art[1] = (RemoteDevice)m_network.ConnectDevice(mac1, "HTC_TyTN_II");

Jonas
Posts: 2319
Joined: Mon Jan 09, 2006 2:20 pm
Location: Sweden

RE: Send file without discovery any device

Fri Apr 03, 2009 5:00 pm

Again, look at the sample it's very simple or read the manual.
You can even step through the ObexFTPClient sample and see where it inputs the MAC-address.

Regards,
Jonas

Return to “BlueTools”