BLEConsole

Bluetooth Low Energy device console app


Project maintained by sensboston Hosted on GitHub Pages — Theme by mattgraham

BLEConsole

Windows command-line tool for interacting with Bluetooth LE devices

image

Version 2.1 - Enhanced Pairing and Usability

New in v2.1:

Previous in v2.0:

Requirements

Windows 10, BT 4.0 adapter

Console Commands

General Commands

Data Format Commands

GATT Operations

Descriptor Commands

Device Information

Pairing Commands

Scripting Commands

* You can use standard C escape characters like \t, \n etc.

** <name> can be “service/characteristic”, characteristic name, or # index

Examples

Connect with PIN pairing

BLE: open ESP32_Device 123456
Connecting to ESP32_Device. It is not paired.
Attempting to pair with PIN...
Pairing successful.
Found 3 services:
#00: GenericAccess
#01: GenericAttribute
#02: Custom Service

Interactive PIN pairing (device displays PIN)

BLE: open MyDevice
Connecting to MyDevice. It is not paired.
Attempting to pair...
Device is displaying a PIN. Enter the PIN shown on the device:
PIN: 847293
Pairing successful.

Subscribe and unsubscribe

BLE: set #2
Selected service Custom Service.
#00: NotifyChar   N
#01: WriteChar    W

BLE: subs #0
Subscribed to characteristic NotifyChar (notify)

BLE: unsubs #0
Unsubscribed from NotifyChar.

BLE: unsubs
Unsubscribed from 0 characteristic(s).

Change byte order for numeric data

BLE: endian big
Byte order set to Big Endian.

BLE: format hex
Current send data format: Hex
Current received data format: Hex

BLE: read #0
hex:    00 01 02 03

Batch script example

// Loop through all devices
foreach

    // Connect and if successful
    if open $

        // Read device name
        read #0/#0

        // Close connection
        close
    endif

endfor

Notes