1. Home
  2. Docs
  3. How-To
  4. H23R1x – Bluetooth ...
  5. Update smartBASIC Scripts on the BT900 Module

Update smartBASIC Scripts on the BT900 Module

Using UwTerminalX and an Array Port

H23R10 module is based on Laird BT900 dual-mode Bluetooth/BLE V4 module, which runs special scripts called smartBASIC. These scripts control the BT900 module internal operations.  Check these documents for more details about this scripting language (smartBASIC core and extensions).

Here’s a step-by-step guide to update smartBASIC scripts on H23R10 modules:

  1. Load the latest firmware on H23R10 module. Check this article for firmware update instructions.
  2. Connect to H23R10 module CLI from any array port and delete the current smartBasic script by typing the following command:

    And then reboot the H23R10 module. You should see a solid green LED if the script was deleted successfully.

  3. If you already have a pre-compiled smartBasic script (binary .uwc file), skip to step 4. If not, navigate to this website to compile it online. Choose the appropriate smartBasic source code (.sb file). Select BT900 device from the list and as firmware version. Then click XCompile. The webpage generates and downloads a .uwc file, which is the binary smartBasic script.
  4. Download the UwTerminalX tool from Laird website. Click Accept if you get the help screen. Setup both Config and Terminal tabs as shown in the picture below. Make sure you set Baud rate to 115200, Handshaking to None and uncheck all RTS, DTR, BREAK, LoalEcho and LinMode options.
  5. Use the CLI and your favorite terminal software, connect to H23R10 module again (using any array port) and type in the following command
    bt-download-script uart                                                        
  6. Close this port from your terminal software.
  7. In UwTerminalX, click OK on Config tab, it will switch to Terminal tab and open the port. Right click and choose Load and choose your compiled smartBasic script (.uwc file). The file will be sent to the BT900 script. There’s 30 seconds timeout between entering the bt-download-script CLI command and sending the script file via UwTerminalX.
  8. Reboot the H23R10 module again, and you should see a bright green LED blink and then the LED turns off, meaning a smartBasic script is running successfully.

Updating Over-the-Air (OTA)


How can we help?