Default
Default

Reputation: 11

How to send file from iPhone to mac over bluetooth

I have created universal device application to transfer any kind of files via bluetooth using GameKit Framework. My question is how to create on Desktop Application with same process or there any Framework? That can communicate also on the device. Can i have any sample please or tips how to do it.

There is Core Bluetooth that used low energy protocol. But i don't know how? Anyone please give some idea or anything that i can use it.

Thank you

Upvotes: 1

Views: 964

Answers (1)

Frederik
Frederik

Reputation: 719

The Bluetooth functionality of the GameKit framework is iOS-only (see GKSession), so you won’t be able to use that on a Mac.

The CoreBluetooth framework on the other hand is available on both Mac and iOS devices supporting Bluetooth LE, with the one difference that the CBPeripheralManager is not available on Mac, so you can’t advertise a service on Mac. However you can have your iOS device act as a peripheral and connect from the Mac acting as a central. Data transfer should still work both ways.

The BTLE Central Peripheral Transfer sample code should be a good starting point.

Upvotes: 2

Related Questions