Anzeige
Anzeige

Más contenido relacionado

Anzeige

Bluetooth Development with .NET

  1. http://www.32feet.NET - Personal Area Networking for .NET Bluetooth Development with .NET Peter Foot
  2. http://www.32feet.NET - Personal Area Networking for .NET 32feet.NET • Collection of libraries for .NET • For Desktop, Embedded and Mobile devices • Currently Bluetooth and IrDA transports and Object Exchange protocol support • Designed to complement existing network support in .NET • Online forums and documentation
  3. http://www.32feet.NET - Personal Area Networking for .NET Supported Platforms • Windows XP SP1 (And later) – Running Microsoft Bluetooth Stack • Windows CE 4.1 (And later) – Including Windows Mobile 2003 and up – Running Microsoft Bluetooth Stack • Broadcom (Widcomm) stack not currently supported - http://www.high-point.com
  4. http://www.32feet.NET - Personal Area Networking for .NET Bluetooth Tasks • Manage device radio state • Find available devices • Make connections • Host a service • Send objects
  5. http://www.32feet.NET - Personal Area Networking for .NET BluetoothRadio • Windows CE supports single radio BluetoothRadio.PrimaryRadio • Windows XP supports multiple radios BluetoothRadio.AllRadios • .Mode – Off, On & Discoverable • .IsSupported – Detect whether Microsoft Bluetooth stack is installed
  6. http://www.32feet.NET - Personal Area Networking for .NET Discover • BluetoothClient class • .DiscoverDevices() – Default will return all devices – Optionally return only previously bonded devices, or only unknown devices – Returns collection of BluetoothDeviceInfo objects
  7. http://www.32feet.NET - Personal Area Networking for .NET Choose a Device • SelectBluetoothDeviceDialog
  8. http://www.32feet.NET - Personal Area Networking for .NET Demo • Discovering Devices
  9. http://www.32feet.NET - Personal Area Networking for .NET Connecting • Use the BluetoothClient class • Specify the unique service id • BluetoothService class contains standard service ids • Read and write data via a NetworkStream object • Close stream when finished
  10. http://www.32feet.NET - Personal Area Networking for .NET Demo • Connect to GPS
  11. http://www.32feet.NET - Personal Area Networking for .NET Host a Service • Use the BluetoothListener class • Create a unique service id (Guid) • Start() to publish your service • AcceptSocket() or AcceptBluetoothClient() – Block until incoming connection is made • Send and receive data • Stop() to unregister the service
  12. http://www.32feet.NET - Personal Area Networking for .NET Send Objects • ObexWebRequest • Works just like an HttpWebRequest • Send any file or object • Some devices may only accept common object types – vCard, vCalendar etc • Common Mime types are in InTheHand.Net.Mime namespace
  13. http://www.32feet.NET - Personal Area Networking for .NET Demo • Send a vCard
  14. http://www.32feet.NET - Personal Area Networking for .NET Receive Objects • ObexListener • Works like HttpListener (.NET 2.0) • Receive incoming objects • Sample included in the download
  15. http://www.32feet.NET - Personal Area Networking for .NET Call to Action • Easy to add Personal Area Networking to your .Net applications • Download the latest version:- – http://www.32feet.net • Start developing exciting applications • Let me know how you get on:- – peter.foot@gmail.com
  16. http://www.32feet.NET - Personal Area Networking for .NET Demo • Receiving beamed images
  17. http://www.32feet.NET - Personal Area Networking for .NET Any Questions?
Anzeige