BGX13 Variable Reference

This page provides a list of Bluetooth Xpress (BGX) BLE variables with a full description of the function of each variable together with example usage.

Variables are cached in volatile RAM and must be saved to non-volatile flash memory to persist between reboots. To save variables to flash, use the save command.

NOTE! Don't forget to check out command navigation tips to make it easier to find and type specific variable names.

Documentation Format

Many of the Bluetooth Xpress responses shown in the examples on this page were captured with the highest system print level ( sy p ) = 4, and system command header enabled ( sy c h ) = 1. These settings are provided to make it easy for a host microcontroller to parse responses by examining response headers.

Version Availability

Variables that were not available in the original product release but that have been added since are indicated with Version Notes . If the variable has no version notes, it means it was available since the original release.

List of Variables


Variable Description

All

al

All (variables)

Description

Returns a list of all variables. This includes the list of GPIO settings returned by gp u .

Attribute Description
access get

Get example

> get al
bl a     : D0CF5E828DC6
bl c c   : 0
bl c i   : 12
bl c t   : 400
bl d a   : 512
bl e b   : 1
bl e k   : none
bl e p   : any
bl p m   : 0
bl p p   : 1m
bl t c   : 8
bl v h d : 30
bl v h i : 32
bl v l d : 0
bl v l i : 874
bl v m   : low
bl v p   : high
bl v x d : 30
bl v x i : 32
bu i     : command
bu s c   : level
bu s s   : 242424
ce c c   : 0
ce s h d : 30
ce s h i : 96
ce s l d : 300
ce s l i : 2048
ce s m   : off
ce w m   : ack
gp u     :
!  # Description
#  0 none
#  1 none
#  2 none
#  3 none
#  4 none
#  5 none
#  6 none
#  7 none
i2 b s   : 92
sy c e   : 0
sy c h   : 0
sy c p   : 1
sy d n   : BGX-8DC6
sy i m   : Silicon Labs
sy i p   : Bluetooth Xpress
sy i s   : 04047F000404
sy o e   : 1
sy o p   : none
sy p     : 4
sy r e   : 1
sy r p   : none
sy s m   : deep
sy u     : 4C892A6AB30335045E0374CAD0CF5EFFFE828DC6
sy v     : BGX13P.1.2.2045.0-1524-2045
sy w c   : 1
tm n p   : 0
ua b     : 115200
ua f     : 0
uf l p   : 20
uf u     :
!  # Description
#  0 none ()
#  1 none ()
#  2 none ()
#  3 none ()
#  4 none ()
#  5 none ()
#  6 none ()
#  7 none ()

BLE Peripheral

bl a

BLE Address

Description

Returns the BLE device address.

Attribute Description
format 6-byte hex string, big-endian
default unique per device
access get
save n/a

Get example

> get bl a
D0CF5E35E0D8

bl c c

BLE Connection Count

Description

Returns the number of centrals that are connected when acting as a peripheral. Will return 0 or 1.

Attribute Description
format integer
units count
min 0
max 1
default 0
access get
save n/a

Get example

> get bl c c
0

bl c i

BLE Connection Interval

Description

BLE connection interval. See Bluetooth specification : Important Connection Parameters : Connection Interval, Supervision Timeout

Notes:

Attribute Description
format integer
units 1.25 ms
min 6 (7.5 ms)
max 3200 (4000 ms)
default 12 (15 ms)
access get/set
save yes

Get example

> get bl c i
12

Set example

> set bl c i 10
Success

bl c t

BLE Connection Timeout

Description

BLE connection supervision timeout. See Bluetooth specification : Important Connection Parameters : Connection Interval, Supervision Timeout .

Attribute Description
format integer
units 10 ms
min 10 (100 ms)
max 3200 (32000 ms)
default 400 (4000 ms)
access get/set
save yes

Get example

> get bl c t
400

Set example

> set bl c t 500
Success

bl d a

BLE Device Appearance

Description

BLE device appearance is a 16 bit integer that describes how the device appears to other devices. It is part of the GAP database. The default value of 512 corresponds to Generic tag, Generic category.

For other appearance values, see Bluetooth GAP Appearance .

Attribute Description
format integer
units n/a
min 0
max 65535
default 512
access get/set
save yes

Get example

get bl d a
512

Set example

set bl d a 512
Success

bl e b

BLE Encryption Bondable (mode)

Description

Enables or disable bonding. Encryption is always enabled for the Bluetooth Xpress module.

Note: The Bluetooth Xpress device can remember up to 14 devices in its internal bonding table. As new devices are added (beyond 14), older less used devices are forgotten.

Attribute Description
format integer
units 1=true/enabled, 0=false/disabled
min 0
max 1
default 1
access get/set
save yes

Get example

> get bl e b
1

Set example

> set bl e b 1
Success

bl e k

BLE Encryption Key

Description

The BLE encryption key can be set to none or to a 6 digit pin. Entering more or less than 6 digits, or entering a pin with non-numeric characters other than 'none' will cause the command to fail. Encryption is always enabled on the Bluetooth Xpress module.

The key type determines the pairing procedure and security mode and level. See Security .

Note : if the key is set to none , and an Android phone requests a pin, use 000000 .

Attribute Description
format 6-digit integer or 'none'
units n/a
min 000000
max 999999
default 'none'
access get/set
save yes

Get example

> get bl e k
none

Set example

> set bl e k 123456
Success

bl e p

BLE Encryption Pairing (mode)

Version Notes

Starting at 1.1.1229.0 added new option "off" and changed the default from "secure" to "any".

Description

Determines the policy for new pairing requests. When set to off , all new pairing requests are rejected. Selecting secure enables pairing with LE Secure Connections (BLE 4.2 or newer) only, while any enables pairing with either secure or legacy methods. When any is selected LE Secure Connections will be used by default if supported by the connecting device. Encryption is always enabled on Bluetooth Xpress modules.

Note : This setting only applies to new pairing requests and does not affect devices that were previously bonded.

Attribute Description
format string enumeration
units 'secure'=secure only
'any'=secure or legacy
'off'=disabled
default any
access get/set
save yes

Get example

> get bl e p
secure

Set example

> set bl e p off
Success

bl p m

BLE PHY Multiplex

Version Notes

Added in 1.1.1229.0

Description

Selects whether the peripheral advertises on one or multiple PHY's. When enabled the peripheral will advertise on both the LE 1M and LE Coded PHY's. When disabled the peripheral will advertise on one PHY determined by PHY preference setting bl p p .

Note : The BGX only supports one connection at a time. Once a connection is established on any PHY, advertising is automatically disabled on all enabled PHY's.

Attribute Description
format integer
units 1=true/enabled, 0=false/disabled
min 0
max 1
default 0
access get/set
save yes

Get example

> get bl p m
0

Set example

> set bl p m 1
Success

bl p p

BLE PHY Preference

Version Notes

Beginning with version 1.1.1229.0 , added new options 125k and 500k . Also changed the preferred PHY requester from the BGX peripheral to the central device (phone or BGX).

Description

Specifies the PHY preference for BLE GAP procedures. When either 1m or 2m is selected the device will advertise, scan and initiate connections using the BLE 1M PHY. If the central device (phone or BGX) has been configured to prefer the BLE 2M PHY, it will start a procedure to switch PHY's once a connection is established.

When either 125k or 500k is selected the device will advertise, scan and initiate connections using the BLE Coded PHY (S=8). For both central and peripheral devices, selecting 500k only affects the transmit direction. After a connection is established using the BLE Coded PHY (S=8), the transmit PHY will switch to the BLE Coded PHY (S=2).

It is possible to advertise on both the 1M and Coded PHY's at the same time. Use bl p m to enable this feature.

Notes:

Attribute Description
format string enumeration
units '1m'=1M PHY
'2m'=2M PHY
'125k'=Coded PHY(S=8)
'500k'=Coded PHY(S=2)
default 1m
access get/set
save yes

Get example

> get bl p p
1m

Set example

> set bl p p 2m
Success

bl t c

BLE Transmit Connected (power)

Description

Configures the RF transmit power when connected.

Attribute Description
format integer
units dBm
min -25
max 8
default 8
access get/set
save yes

Note: The BGX uses its low power amplifier when the transmit power setting is below 0 dBm. The low power amplifier only supports several discrete power settings below 0 dBm. For this reason, negative output power values will result in an actual output power that does not exactly match the value specified.

Get example

> get bl t c
8

Set example

> set bl t c 4
Success

bl v h d

BLE adVertising High Duration

Description

Configures high mode advertising duration. This is the duration in seconds for which advertising continues after issuing the adv high command. See BLE Advertising .

Attribute Description
format integer
units seconds
min 0 (advertise forever)
max 1000
default 30
access get/set
save yes

Get example

> get bl v h d
30

Set example

> set bl v h d 40
Success

bl v h i

BLE adVertising High Interval

Description

Configures high mode advertising interval, used for the adv command high option. The interval is measured in slots. For example, an interval of 32 means advertise in slot 0, then 32, then 64 and so on. Valid range: 32 - 16384 slots inclusive.

Attribute Description
format integer
units slots
min 32
max 16384
default 32
access get/set
save yes

Get example

> get bl v h i
32

Set example

> set bl v h i 50
Success

bl v l d

BLE adVertising Low Duration

Description

Configures low mode advertising duration. This is the duration in seconds for which advertising continues after issuing the adv low command. See BLE Advertising .

Attribute Description
format integer
units seconds
min 0 (advertise forever)
max 1000
default 0 (forever)
access get/set
save yes

Get example

> get bl v l d
0

Set example

> set bl v l d 350
Success

bl v l i

BLE adVertising Low Interval

Description

Configures low mode advertising interval, used for the adv command low option. The interval is measured in slots. For example, an interval of 32 means advertise in slot 0, then 32, then 64 and so on. Valid range: 32 - 16384 slots inclusive.

Attribute Description
format integer
units slots
min 32
max 16384
default 874
access get/set
save yes

Get example

> get bl v l i
874

Set example

> set bl v l i 64
Success

!-- structElement:varHeading -->

bl v x d

BLE adVertising Xpress Duration

Version Notes

Added in 1.2.2045.0

Description

Configures Xpress mode advertising duration. This is the duration in seconds for which advertising continues after issuing the adv xpr command. See BLE Advertising .

Attribute Description
format integer
units seconds
min 1
max 180
default 30
access get/set
save yes

Get example

> get bl v x d
30

Set example

> set bl v x d 40
Success

bl v x i

BLE adVertising Xpress Interval

Version Notes

Added in 1.2.2045.0

Description

Configures Xpress mode advertising interval, used for the adv command xpr option. The interval is measured in slots. For example, an interval of 32 means advertise in slot 0, then 32, then 64 and so on. Valid range: 32 - 16384 slots inclusive.

Attribute Description
format integer
units slots
min 32
max 16384
default 32
access get/set
save yes

Get example

> get bl v x i
32

Set example

> set bl v x i 64
Success

bl v m

BLE adVertising Mode

Version Notes

xpr value added in 1.2.2045.0 .

Description

Get peripheral advertising mode, as set by the adv command.

Attribute Description
format string enumeration
units 'high'=adv high mode
'low'=adv low mode
'xpr'=adv xpress mode
'off'=no advertising
default 'high'
access get
save n/a

Get example

> get bl v m
high

bl v p

BLE adVertising Preference

Version Notes

Added in 1.1.1229.0

xpr argument added in 1.2.2045.0 .

Description

Selects which advertising mode is entered whenever exiting a non-advertising mode (sleep, connection, scan, etc.).

Attribute Description
format string enumeration
units 'high'=adv high mode
'low'=adv low mode
'xpr'=adv xpress mode
'off'=no advertising
default 'high'
access get/set
save yes

Get example

> get bl v p
low

Set example

> set bl v p off
Success

Bus

bu i

Bus Initialization (mode)

Description

Serial bus initialization mode for str_select . If GPIO option str_select is used, and it is configured for edge mode (see bu s c ), then this option determines the initial mode of the serial bus (COMMAND or STREAM).

Notes :

Attribute Description
format string enumeration
units 'stream'=stream mode
'command'=command mode (remote command mode locked out)
default 'command'
access get/set
save yes

Get example

> get bu i
command

Set example

> set bu i stream
Success
> save
Success

bu s c

Bus Serial Control

Description

Serial bus switch control mode for str_select . If GPIO option str_select is used, then this option is used to determine whether the pin switching is edge or level mode for selecting serial bus STREAM or COMMAND mode.

If bu s c is set to edge , a rising edge on the str_select pin toggles the mode. The initial bus mode after reset can be configured (see bu i ).

If bu s c is set to level , the serial bus mode is selected by driving a constant high or low logic level onto the str_select pin. In level mode a low level selects COMMAND mode and a high level selects STREAM mode.

Note: The str_select pin is configured with the GPIO function command.

Attribute Description
format string enumeration
units 'edge'=rising edge toggle on str_select
'level'=mode selected by logic level
default 'level'
access get/set
save yes

Get example

> get bu s c
level

Set example

> set bu s c edge
Success

bu s s

Bus Stream (breakout) Sequence

Description

Set a new bus stream breakout sequence. Sending the breakout sequence when in STREAM mode places the device in local COMMAND mode. To disable the breakout sequence, set to none . See Serial Bus Modes .

In order to be seen as a breakout condition, the breakout sequence must be preceded and followed by idle periods of at least 500 milliseconds on the BGX UART's Rx line. The amount of time between each character in the breakout sequence must be less than 255 bit times or 4 milliseconds, whichever is shorter.

Due to these timing constraints, it is generally not possible to send the breakout sequence by manually typing it into a terminal. Instead, a terminal program with the capability to send macros should be used.

Note : Setting to 00 sets the breakout sequence to the hexadecimal 0x00 , corresponding to the ASCII NULL character.

Note : The breakout sequence does not work reliably for serial data rates less than 5000 bits per second .

Attribute Description
format up to 4-byte hex string
default 242424 ('$$$')
access get/set
save yes

Get example

> get bu s s
242424

Set example

Set breakout sequence to ASCII characters "BRK"

> set bu s s 42524b
Success

Disable breakout sequence:

> set bu s s none

Central

ce c c

Central Connection Count

Description

Returns the number of peripherals connected when acting as a central. Will return 0 if not connected, and 1 if connected.

Attribute Description
format integer
units count
min 0
max 1
default 0
access get
save n/a

Get example

> get ce c c
0

ce s h d

Central Scan High Duration

Description

Configures central scan high mode duration. This is the duration in seconds for which scan continues after issuing the scan high command.

Attribute Description
format integer
units seconds
min 0 (scan forever)
max 1000
default 30
access get/set
save yes

Get example

> get ce s h d
30

Set example

> set ce s h d 40
Success

ce s h i

Central Scan High Interval

Version Notes

Starting with version 1.1.1229.0 , if scanning is configured to use the BLE Coded PHY, the configured scan interval values are automatically tripled.

Description

Configures central high mode scanning interval, used for the scan command high option.

Attribute Description
format integer
units slots
min 4
max 16384
default 96
access get/set
save yes

Get example

> get ce s h i
96

Set example

> set ce s h i 1000
Success

ce s l d

Central Scan Low Duration

Description

Configures central low mode scanning duration. This is the duration in seconds for which scanning continues after issuing the scan low command.

Attribute Description
format integer
units seconds
min 0 (scan forever)
max 1000
default 300
access get/set
save yes

Get example

> get ce s l d
300

Set example

> set ce s l d 350
Success

ce s l i

Central Scan Low Interval

Version Notes

Starting with version 1.1.1229.0 , if scanning is configured to use the BLE Coded PHY, the configured scan interval values are automatically tripled.

Description

Configures low mode scanning interval, used for the scan command low option.

Attribute Description
format integer
units slots
min 4
max 16384
default 2048
access get/set
save yes

Get example

> get ce s l i
2048

Set example

> set ce s l i 64
Success

ce s m

Central Scan Mode

Description

With this device acting as a Central, returns scan mode, as set by the scan command.

Attribute Description
format string enumeration
units 'high'=scan high mode
'low'=scan low mode
'off'=no scanning
default 'off'
access get
save n/a

Get example

> get ce s m
off

ce w m

Central Write Mode

Version Notes

Starting with version 1.2.2045.0 , the ack setting uses Fast-Ack Flow Control instead of Legacy Flow Control (see Xpress Streaming Service Flow Control ). The noack setting is not recommended, because the ack setting guarantees data integrity while still achieving high throughput rates. The noack setting is still available to maintain backwards-compatibility with existing BGX applications.

Description

This variable controls whether the connection requires acknowledgement on writes.

Attribute Description
format string enumeration
units 'ack'=use write acknowledgement
'noack'=do not use acknowledgment
default 'ack'
access get/set
save yes

Get example

> get ce w m
ack

Get example

> set ce w m noack
Success

GPIO

gp u

GPIO Usage

Description

Get GPIO usage. See the GPIO function command for a description of configurable and automatically assigned GPIO functions.

By default get gp u displays the function and the direction set by the gdi or gdis commands. For example:

> gfu 5 stdio
Success
> gdi 5 ipu
Success
> gfu 6 stdio
Success
> gdi 6 ohi
Success
> get gp u
!  # Description
...
#  5 stdio,ipu
#  6 stdio,ohi
...

To view the pin mode and extra options set by the gdi command set this variable to verbose . To change back to the shorter display, set this variable to default .

> set gp u verbose
Success
> get gp u
!  # Description
    ...
#  5 stdio,ipu (ioz)
#  6 stdio,ohi (ioz,pp,drvst)
    ...
Attribute Description
format table list
units 'default'=abbreviated display
'verbose'=detailed display
default 'default'
access get/set
save no

Get example

> get gp u
!  # Description
#  0 stdio
#  1 stdio
#  2 none
#  3 none
#  4 none
#  5 none
#  6 none
#  7 none

I2C

i2 b s

I2C Bus Speed

Version Notes

Added in 1.2.2045.0

Description

I2C Master bus speed in kHz. This is the bus speed that will be used for the i2crd and i2cwr commands.

Attribute Description
format integer
units kHz
min 10
max 1000
default 92 (BGX13), 100 (BGX220)
access get/set
save yes

Note: The ratio between the low period and high period of the clock pulses on i2cm_scl ( Tlow:Thigh ) varies at different I2C bus speed settings as shown in the table below:

i2 b s Tlow:Thigh
i2 b s <= 92 1 : 1
93 <= i2 b s <= 392 2 : 1
i2 b s >= 393 3.67 : 1

Note: : SCL and SDA pins should be defined using gfu command before setting I2C bus speed.

Get example

> get i2 b s
92

Set example

> set i2 b s 1000
Success

System

sy c e

System Command Echo

Description

Enable/disable character echo.

Note! If character echo is turned off, keystrokes that are subsequently typed are not echoed to the serial interface (or terminal). This mode is primarily intended for machine control.

Attribute Description
format integer
units 1=true/enabled, 0=false/disabled
min 0
max 1
default 1
access get/set
save yes

Get example

> get sy c e
1

Set example

> set sy c e 0
Success

sy c h

System Command Header

Description

Enable/disable a response header for commands. Only applies to command mode. Response headers make it easy to parse responses with a host MCU.

See Serial Interface, Response Format for the reponse header format.

Attribute Description
format integer
units 1=true/enabled, 0=false/disabled
min 0
max 1
default 0
access get/set
save yes

Get example

> get sy c h
0

Set example

> set sy c h 1
Success

sy c m

System Command Mode

Description

Puts the Bluetooth Xpress command interface into human or machine mode. See Serial Interface, Configuration . Note! This variable is NOT readable.

Attribute Description
format string enumeration
units 'machine'=machine mode
'human'=human mode
default 'human'
access set
save yes

Set example

> set sy c m machine
Success

sy c p

System Command Prompt

Description

Enable/disable terminal command prompt. Only applies to command mode. A prompt makes it easy for humans to interact with Bluetooth Xpress module.

Attribute Description
format integer
units 1=true/enabled, 0=false/disabled
min 0
max 1
default 1
access get/set
save yes

Get example

> get sy c p
1

Set example

> set sy c p 1
Success

sy d n

System Device Name

Description

Bluetooth device name, up to 16 characters in length. Up to all 12 digits of the Bluetooth address from BD_ADDR may be substituted by hash # wildcard characters. The wildcard characters must be contiguous and the BD address will be right-justified within the field. See the examples below.

Attribute Description
format string
min --
max 16 characters length
default 'BGX-####'
access get/set
save yes

Get example

> get bl a
4C55CCABCDEF
> get sy d n
BGX-CDEF

Set example

In the following examples the BD_ADDR address is 4C55CCABCDEF (see bl a )

> set sy d n ACK-##
Success
> get sy d n
ACK-EF
> set sy d n BGX###
Success
> get sy d n
BGXDEF
> set sy d n my######
Success
> get sy d n
myABCDEF
> set sy d n ###-DEV
Success
> get sy d n
DEF-DEV

sy i m

System Info Manufacturer

Description

Manufacturer string, up to 32 characters in length. Use double quotes to enter a name containing a space.

Attribute Description
format string
min --
max 32 characters length
default 'Silicon Labs'
access get/set
save yes

Get example

> get sy i m
Silicon Labs

Set example

> set sy i m "Placeholder Name"
Success
> get sy i m
Placeholder Name

sy i p

System Info Product

Version Notes

Prior to 1.1.1229.0 the default value was "Blue Gecko Xpress"

Description

Product information string, up to 32 characters in length. Use double quotes to enter a name containing a space.

Attribute Description
format string
min --
max 32 characters length
default 'Bluetooth Xpress'
access get/set
save yes

Get example

> get sy i p
Bluetooth Xpress

Set example

> set sy i p "Placeholder Product"
Success
> get sy i p
Placeholder Product

sy i s

System Indicator Status (setting)

Version Notes

Starting with version 1.2.2045.0 an additional blink pattern was added for attempting to connect/advertising.

Description

Set the blink pattern for the con_status_led pin function. The command takes 6 hexadecimal values AABBCCDDEEFF, where AA, BB, CC and DD are hex numbers in the range 00 to FF .

AABB sets the LED blink pattern when not connected. CCDD sets the LED blink pattern when connected. EEFF sets the blink pattern when attempting to connect (i.e. adv or con command is executing).

Note : For backwards compatibility, the EEFF portion of the variable can be omitted. When the variable is set using AABBCCDD, the connecting blink pattern will match the not connected blink pattern. For versions prior to 1.2.2045.0 the EEFF portion will not be accepted.

The low part of the blink pattern is set with AA when not connected (CC when connected, EE when attempting to connect).

The high period of the blink pattern is set with BB when not connected (DD when connected, FF when attempting to connect).

Each pattern tick equals 0.1 sec (100 msec).

Some examples:

Low = AA/CC/EE High = BB/DD/FF Period Duty Cycle Notes
04 04 0.80s 50% 1.25 Hz --- default blink pattern when not connected or attempting to connect
7f 00 --- 0% Always low --- default blink pattern when connected
01 01 0.20s 50% Fastest possible blink. Duty cycle = 50%
ff ff 51.0s 50% Slowest possible blink. Duty cycle = 50%
1c 04 3.20s 12.5% Period = (28 + 4) x 0.1s, Duty cycle = 4/(28 + 4) x 100%
Attribute Description
format 6-byte hex string (4 bytes for legacy behavior)
units 0.1 sec resolution per byte
min '00' per byte (inactive)
max 'FF' per byte
default '04047F000404' (1.25 Hz blink when not connected or attempting to connect, always low when connected)
access get/set
save yes

Get example

> get sy i s
04047F000404

Set example

Set to fastest blink when not connected, slower blink when connected.

> set sy i s 0101ffff0202
Success

sy o e

System OTA Enable

Description

Enable or disable OTA upgrades.

Attribute Description
format integer
units 1=true/enabled, 0=false/disabled
min 0
max 1
default 1
access get/set
save yes

Get example

> get sy o e
1

Set example

> set sy o e 1
Success

sy o p

System OTA Password

Version Notes

This variable was added in 1.2.2045.0 .

Description

Requires the remote device to provide a password to enable OTA firmware update.

If set to none , OTA is not protected by a password.

If set to a string, the remote device must provide a password when performing a firmware update.

Attribute Description
format Up to 16-character string
default none
access get/set
save yes

Get example

> get sy o p
none

Set example

> set sy o p 123456
Success

sy p

System Print (level)

Description

System print level.

Attribute Description
format integer
units 0 = no messages
1 = synchronous system messages
2 = synchronous logging messages
3 = asynchronous system messages
4 = all/asynchronous logging messages
min 0
max 4
default 4
access get/set
save yes

Get example

> get sy p
0

Set example

> set sy p 0
Success

sy r e

System Remote (commanding) Enabled

Version Notes

Restricted mode was added in version 1.2.2045.0 .

Description

Enables/disables/restricts access to the Bluetooth Xpress module command interface from a remote terminal via the BLE interface (remote COMMAND mode).

If sy r e is set to 0, access to the command interface is restricted to the UART interface (local COMMAND mode). See Serial Interface .

If sy r e is set to 1, access to the command interface is enabled for remote COMMAND mode.

If sy r e is set to 2, access to the command interface is restricted to the following set of commands.

Remote Commands Allowed in Restricted Mode

Command Usage
gdi set GPIO direction and pin mode (stdio)
gdis set direction for multiple GPIOs
gfu select GPIO function
gge get GPIO value (stdio)
gges get multiple GPIO values
gse set GPIO value (stdio)
gses set multiple GPIO values
i2crd I2C read
i2cwr I2C write
rssi display RSSI value for current connection
str switch to stream mode
ver show version
Attribute Description
format integer
units 0=disabled, 1=unrestricted, 2=restricted (GPIO and I2C only)
min 0
max 2
default 1
access get/set
save yes

Get example

> get sy r e
1

Set example

> set sy r e 1
Success

sy r p

System Remote (commanding) Password

Version Notes

This variable was added in 1.2.2045.0 .

Description

Requires that the remote device use a password to access the Bluetooth Xpress module's command interface from a remote terminal via the BLE interface (remote COMMAND mode).

If set to none , remote COMMAND mode is not protected by a password (although is can still be disabled or restricted via sy r e ).

If set to a string, specifies the password that the remote device must use when issuing the rbmode remote command to access the module's command interface remotely.

Attribute Description
format up to 16-character string
default none
access get/set
save yes

Get example

> get sy r p
none

Set example

> set sy r p 123456
Success

sy s m

System Sleep Mode

Description

Sets the sleep mode to be entered by the Bluetooth Xpress module. See Power Management for more information.

Attribute Description
format string enumeration
units 'deep' = stop all active advertising and scanning operations when entering sleep mode
'radio' = continue all active advertising and scanning operations when entering sleep mode
default 'deep'
access get/set
save yes

Get example

> get sy s m
deep

Set example

> set sy s m radio
Success

sy u

System UUID

Description

Returns the hardware UUID of the module.

Attribute Description
format 20-byte hex string
default unique per device
access get
save n/a

The first 8 digits of the UUID indicate the hardware revision, per the following table:

UUID first 8 digits Hardware version
4C892A6A BGX13P-V2
080447D0 BGX13S-V2
F65FD7F0 BGX13S-V3

Get example

> get sy u
4C892A6A68B925AC06E893B1D0CF5EFFFE828F33

Note: In the above example, the hardware field value is 4C892A6A which indicates this device is BGX13P-V2.

sy v

System (firmware) Version

Description

Returns the Bluetooth Xpress firmware version.

Attribute Description
format string
default varies
access get
save n/a

This is the variable equivalent of the ver command. Refer to the ver command for a description of the version fields.

Get example

> get sy v
BGX13.1.0.821.0-1229-821

sy w c

System Wake on CTS

Description

Enables/disables waking the device from sleep mode when a falling edge is detected on the UART CTS pin.

UART baud rate ( ua b ) must be greater than 9600 bps for the device to wake from sleep on a falling edge of CTS. If the baud rate is 9600 bps or less, the UART interface is operational in sleep mode, so CTS retains its normal function as a flow control signal and cannot be used as a wake pin. In this scenario, the user can issue the wake command ( wake ) to put the device into active mode.

See Power Management for more information on power modes.

Attribute Description
format integer
units 1=true/enabled, 0=false/disabled
min 0
max 1
default 1
access get/set
save yes

Get example

> get sy w c
1

Set example

> set sy w c 0
Success

Test Mode

tm n p

Test Mode Number of Packets

Description

This variable reports the number of packets that were transmitted or received between the dtm start and dtm stop commands. It is set to 0 when dtm start runs and records total packets when dtm stop runs.

See Direct Test Mode (dtm) for more details.

Attribute Description
format integer
units count
min 0
max 65535
default 0
access get
save n/a

Get example

> get tm n p
0

UART

ua b

UART Baud

Description

Sets the UART baud rate.

Note: The new data rate does not take effect until the user issues the uartu command.

Attribute Description
format integer
units bits per second
min 0
max 2000000
default 115200
access get/set
save yes

Get example

> get ua b
115200

Set example

> set ua b 115200
Success

ua f

UART Flow control

Description

Turn on/off UART hardware flow control.

Note: The new flow control setting does not take effect until the user issues the uartu command.

Attribute Description
format integer
units 1=true/enabled, 0=false/disabled
min 0
max 1
default 0
access get/set
save yes

Get example

> get ua f
1

Set example

> set ua f 0
Success

User Function

uf l p

User Function Long-Press Duration

Version Notes

Added in 1.2.2045.0

Description

Configures the minimum length of time a ufu_level pin configured to trigger a hi_long or lo_long user event (see uevt command) must remain high (for hi_long ) or low (for lo_long ) in order for the event to be seen as a long-press rather than a short-press.

Attribute Description
format integer
units 100 milliseconds
min 1 (100 milliseconds)
max 100 (10 seconds)
default 20 (2 seconds)
access get/set
save yes

Get example

> get uf l p
20

Set example

> set uf l p 30
Success

uf u

User Function Usage

Description

User functions and the events that trigger them are displayed using this read-only variable. This multi-line variable behaves similar to the gpio "gp u" variable.

Attribute Description
format table list
access get
save n/a

Get example

> get uf u
!  # Description
#  0 lo,3 (con D0CF5E35E0D8 10)
#  1 hi,3 (dct)
#  2 none ()
#  3 none ()