Ask HN:在 iOS 上,你们如何实现无需服务器的 P2P 发现?
5 分•作者: redgridtactical•5 个月前
我正在开发一款应用,当没有蜂窝网络服务时,它可以通过蓝牙在手机之间同步数据。Android 有 Nearby Connections API,可以很好地处理设备发现和数据传输。iOS 有 Multipeer Connectivity,但它不太稳定,而且 Apple 已经多年没有更新它了。CoreBluetooth 也能用,但设备发现速度慢,而且你只能广播 28 个字节的数据。有没有人找到一种可靠的跨平台蓝牙低功耗(BLE)设备发现方法,不需要中央服务器或预共享标识符?
查看原文
I'm building an app that syncs between phones over Bluetooth when there's no cell service. Android has Nearby Connections API which handles discovery and transport nicely. iOS has Multipeer Connectivity but it's flaky and Apple hasn't updated it in years. CoreBluetooth works but discovery is slow and you're limited to advertising 28 bytes. Has anyone found a reliable cross-platform approach to BLE device discovery that doesn't require a central server or pre-shared identifiers?