diff --git a/docs/imagesForWeb.pptx b/docs/imagesForWeb.pptx deleted file mode 100644 index 03b3953faf50..000000000000 Binary files a/docs/imagesForWeb.pptx and /dev/null differ diff --git a/pxt-jacdac b/pxt-jacdac index c4280eaadc59..78e2c68b8536 160000 --- a/pxt-jacdac +++ b/pxt-jacdac @@ -1 +1 @@ -Subproject commit c4280eaadc592075dcdc4288250cb998b89ae842 +Subproject commit 78e2c68b85363e580cc4c757fdce89a032e990f9 diff --git a/src/pages/clients/makecode/user-guide.mdx b/src/pages/clients/makecode/user-guide.mdx index f2a3da527476..a70dd7056ae7 100644 --- a/src/pages/clients/makecode/user-guide.mdx +++ b/src/pages/clients/makecode/user-guide.mdx @@ -39,6 +39,20 @@ The micro:bit in dongle mode does not execute the user's program. In pxt-jacdac v1.8.41 and earlier, the dongle behaved a bit differently where both physical and simulated device could become dongle. The new behavior is designed to provide a better user experience. +## Client role binding + +You can provide hints in the client role name in the form of URL query arguments to influence the binding algorithm: + +```sts +export const btnB = new modules.ButtonClient("A?dev=self&srvo=1") +``` + +Supported arguments are: + +- `dev=[id]` where `[id]` is the full device id or shortid. `self` is a special name that refers to the micro:bit device itself, it is used for servers. +- `srvi=[index]` where `[index]` is the service index +- `srvo=[index]` where `[index]` is the service offset, an index that only takes into account services of the same type. + ## Multiple Roles When running your code, Jacdac binds the modules detected on the bus with the **roles** defined in your program.