How to get serviceUuid and characteristicUuid when I use the bluetoothLE extension?

Well if you read that documentation, which is very thorough, they have made communication with the buttons as easy as possible.

However, their code is not aimed at block-type coding languages like App Inventor and makes extensive use of structures, which App Inventor does not support.

Their security is good but also difficult to support. For example:

When pairing the button (requires it to be in Public mode), a pairing identifier (32-bit) and pairing key (128-bit) is created. This pair should be stored persistently so communication can continue after a re-connection.

Your App will need to 'grab' those values and store in TinyDb for recall the next time the App is opened.

The BLE extension has the facility to enlarge the MTU (Maximum Transmission Unit) as is required by flic2.

I think the best way to support flic2 is to incorporate the GitHub code provided into an App Inventor extension, or use Android Studio and not App Inventor.

You can suggest a flic2 extension on the App Inventor Extensions forum page.

If you are familiar with coding in Java you could write that extension yourself:

1 Like