问题
I've got some bluetooth speakers (similar) and would really like to be able to play to more than one of them concurrently however I can't find a way to do it.
I can deploy my own applications so it doesn't necessarily have to be accomplished through public APIs, but does the iPhone hardware support it?
回答1:
You can connect to multiple speakers, but only play to one at a time. There isn't enough bandwidth in BT to really send two high quality stereo streams at the same time. Also, I don't think there's a path for you to write your own app to do something like this.
回答2:
A master Bluetooth device can communicate with a maximum of seven devices in a piconet (an ad-hoc computer network using Bluetooth technology), though not all devices reach this maximum. The devices can switch roles, by agreement, and the slave can become the master (for example, a headset initiating a connection to a phone will necessarily begin as master, as initiator of the connection; but may subsequently prefer to be slave). The Bluetooth Core Specification provides for the connection of two or more piconets to form a scatternet, in which certain devices simultaneously play the master role in one piconet and the slave role in another.
At any given time, data can be transferred between the master and one other device (except for the little-used broadcast mode). The master chooses which slave device to address; typically, it switches rapidly from one device to another in a round-robin fashion. Since it is the master that chooses which slave to address, whereas a slave is (in theory) supposed to listen in each receive slot, being a master is a lighter burden than being a slave. Being a master of seven slaves is possible; being a slave of more than one master is difficult.
Bonjour, also known as zero-configuration networking, enables automatic discovery of devices and services on a local network using industry standard IP protocols. Bonjour makes it easy to discover, publish, and resolve network services with a sophisticated, yet easy-to-use, programming interface that is accessible from Cocoa, Ruby, Python, and other languages.
(void)discoverServices:(NSArray *)serviceUUIDs
, use this to discover the list of devices..
connect to the device and check status of connectivity with
@property(readonly) BOOL isConnected
then use cbroadcast to communicate to , for that please use https://developer.apple.com/bonjour/
reference : Apple Ref and also wiki , refernce image from apple doc
回答3:
You can use 2 Airport Express on the same network to stream to both speakers. Each speaker is connect ed to one Airport Express...
Another option you can try is App for iOS called TuneMob that can stream music between iPhones and iPads via Bluetooth and each acts as as speaker. You can connect other speakers as outputs for secondary iPhones/iPads as well...
来源:https://stackoverflow.com/questions/16693033/ios-playing-audio-to-multiple-bluetooth-devices-concurrently