From 4a34f2b9325bfab37284523c03cdf053c180049c Mon Sep 17 00:00:00 2001 From: Peli de Halleux Date: Wed, 30 Nov 2016 10:35:42 -0800 Subject: [PATCH] support for specifying different pairings --- libs/bluetooth/pxt.json | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) diff --git a/libs/bluetooth/pxt.json b/libs/bluetooth/pxt.json index 43f75849..a1af7eda 100644 --- a/libs/bluetooth/pxt.json +++ b/libs/bluetooth/pxt.json @@ -38,7 +38,33 @@ } }, "gatt_table_size": "0x700" - } + }, + "userConfigs": [ + { + "description": "No pairing: Anyone can connect via Bluetooth.", + "config": { + "microbit-dal": { + "bluetooth": { + "open": 1, + "pairing_mode": null, + "security_level": null + } + } + } + }, + { + "description": "Passkey pairing: Button press and 6 digit key to pair via Bluetooth.", + "config": { + "microbit-dal": { + "bluetooth": { + "open": 0, + "pairing_mode": 1, + "security_level": "SECURITY_MODE_ENCRYPTION_WITH_MITM" + } + } + } + } + ] }, "installedVersion": "vzlhfd" } \ No newline at end of file