を使用しnavigator.bluetooth.requestDevice()
て、ネイティブ OSX bluetooth ペアリングを使用して既にペアを設定した bluetooth デバイスにアクセスできますが、属性が私の一般的なクエリと一致する場合でも、以前にペアリングされていないデバイスは表示されません。利用可能なデバイスが Chrome モーダルに表示され、ペアリングへのユーザーの同意が求められますが、表示されるのは既にペアリング済みのデバイスだけです。
ここで意図した使用例を誤解していますか、それとも Chrome から近くの (以前はペアリングされていなかった) デバイスとの接続を確立する別の方法はありますか?
ドキュメント: https://webbluetoothcg.github.io/web-bluetooth/ (例 2 を参照)
function bluetoothConnect() {
navigator.bluetooth.requestDevice({filters: [{services: ['generic_access']}]})
.then(device => {console.log(`Connected to: ${device.name}`)})
.catch(console.error);
}