App Inventor 2終於出了BLE的extension模組,可以減化寫 Android BLE程式的複雜度,

本篇選了一顆市面上的BLE模組來做測試,我想在其他的BLE模組上也可以適用,

由於程式碼的內容有點多,只能等有時間再一一說明,

在這版程式初步可做到:

1. Connect/Disconnect BLE Device 連結/中斷連結BLE裝置

2. Read service UUID 讀取 service UUID

3. Read characteristic UUID 讀取 characteristic UUID

4. Read/Write characteristic  value 讀取/寫入characteristic 數值

BLE extension下載處:

http://appinventor.mit.edu/extensions/

2020.06.05 --> 更新BLE extension: http://iot.appinventor.mit.edu/#/bluetoothle/bluetoothleintro

圖片 2.png

下載BluetoothLE.aix

圖片 3.png

在App Inventor 2介面的Extension選擇import extension

圖片 4.png

可以看到一個BluetoothLE的icon出現在Extension列中

圖片 5.png

將BluetootnLE拉到Design視窗中

圖片 6.png

在Block中有BLE相關程式圖框可以使用

 

圖片 7.png  

最終設計的介面:

 Screenshot_2017-01-02-14-16-10-793_appinventor.ai_labview_net.BLE_Tool  

目前可展示的影片:

我想只要能跟BLE連的上線傳輸資料,未來將有許多的應用可以開發。

arrow
arrow
    文章標籤
    BLE App inventor Arduino
    全站熱搜

    fishark 發表在 痞客邦 留言(3) 人氣()