UTIL Extension Vendor Specific API

UTIL Extension Commands

UTIL_NV_Read

Opcode

0xFE81

Command Description

Send this command to read an NV parameter.

Command Parameters

nvID
Size

1 byte(s)

Default

0

Range

Any 1-byte value

nvLen
Size

1 byte(s)

Default

0

Range

Any 1-byte value

Events Generated

When this command is received, the host will send the CommandStatus Event.

UTIL_NV_Write

Opcode

0xFE82

Command Description

Send this command to write an NV parameter.

Command Parameters

nvID
Size

1 byte(s)

Default

0

Range

Any 1-byte value

nvDataLen

Size of NV data

Size

1 byte(s)

Value

size(nvData)

nvData

NV Data Field. Structure can be different for each NV item

Size

input byte(s)

Default

“00”

Range

Any 1-byte value

Events Generated

When this command is received, the host will send the CommandStatus Event.

UTIL_ForceBoot

Opcode

0xFE83

Command Description

Force the boot loader to run.

Events Generated

When this command is received, the device resets if the boot loader is present. Otherwise, the host will send the CommandStatus Event.

UTIL_BuildRevision

Opcode

0xFE84

Command Description

This command is used to read the build revision information of the BLE stack software.

Events Generated

When this command is received, the host will send the CommandStatus Event.

Additional Command Status Return Parameters

dataLen
Size

1 byte(s)

Range

stk ver (mj/mn/ph)
Condition

( StatStatus==0x00)

Size

3 byte(s)

Range

bld ver
Condition

( StatStatus==0x00)

Size

2 byte(s)

Range

stk info
Condition

( StatStatus==0x00)

Size

1 byte(s)

Range

Value

Description

0x01

IARProject

0x02

CCSProject

0x10

IARLibrary

0x80

ROMBuild

ctrl info
Condition

( StatStatus==0x00)

Size

2 byte(s)

Range

Value

Description

0x01

ADV_NCONN

0x02

ADV_CONN

0x04

SCAN

0x08

INIT

0x10

PING

0x20

SLV_FEAT_EXCHG

0x40

CONN_PARAM_REQ

host info
Condition

( StatStatus==0x00)

Size

2 byte(s)

Range

Value

Description

0x01

BROADCASTER

0x02

OBSERVER

0x04

PERIPHERAL

0x08

CENTRAL

UTIL_GetMemStats

Opcode

0xFE87

Command Description

Get memory statistics

Command Parameters

command ID
Size

1 byte(s)

Default

2

Range

Value

Description

0x01

Light Heap Statistic

0x02

Full Heap Statistic (requieres HEAPMGR_METRICS)

0x04

Thread usage Statistic (requieres HEAPMGR_METRICS)

Events Generated

When this command is received, the host will send the CommandStatus Event.

Additional Command Status Return Parameters

dataLen
Size

1 byte(s)

Range

:all cmdID receive :

Size

1 byte(s)

Range

Value

Description

0x01

Light Heap Statistic

0x02

Full Heap Statistic (requieres HEAPMGR_METRICS)

0x04

Thread usage Statistic (requieres HEAPMGR_METRICS)

cmdID
Condition

( (cmdID & 0x01) == 0x01)

Size

1 byte(s)

Range

Value

Description

0x01

Light Heap Statistic

0x02

Full Heap Statistic (requieres HEAPMGR_METRICS)

0x04

Thread usage Statistic (requieres HEAPMGR_METRICS)

Heap Size
Condition

( (cmdID & 0x01) == 0x01)

Size

4 byte(s)

Range

Heap Size Free
Condition

( (cmdID & 0x01) == 0x01)

Size

4 byte(s)

Range

Biggest free buffer Available
Condition

( (cmdID & 0x01) == 0x01)

Size

4 byte(s)

Range

cmdID
Condition

( (cmdID & 0x02) == 0x02)

Size

1 byte(s)

Range

Value

Description

0x01

Light Heap Statistic

0x02

Full Heap Statistic (requieres HEAPMGR_METRICS)

0x04

Thread usage Statistic (requieres HEAPMGR_METRICS)

Heap Fail number
Condition

( (cmdID & 0x02) == 0x02)

Size

2 byte(s)

Range

Heap Allocated
Condition

( (cmdID & 0x02) == 0x02)

Size

4 byte(s)

Range

Heap Max Allocated
Condition

( (cmdID & 0x02) == 0x02)

Size

4 byte(s)

Range

cmdID
Condition

( (cmdID & 0x04) ==0x04)

Size

1 byte(s)

Range

Value

Description

0x01

Light Heap Statistic

0x02

Full Heap Statistic (requieres HEAPMGR_METRICS)

0x04

Thread usage Statistic (requieres HEAPMGR_METRICS)

Number of Thread
Condition

( (cmdID & 0x04) ==0x04)

Size

1 byte(s)

Range

An array of size “Count” will be returned containing the parameters starting here:

Priority
Condition

( (cmdID & 0x04) ==0x04)

Size

1 byte(s)

Range

Handle
Condition

( (cmdID & 0x04) ==0x04)

Size

2 byte(s)

Range

max Stack used
Condition

( (cmdID & 0x04) ==0x04)

Size

2 byte(s)

Range

stack size
Condition

( (cmdID & 0x04) ==0x04)

Size

2 byte(s)

Range

The array of parameters ends here.

UTIL Extension Events

UTIL_GetMemStats

Opcode

0x0681

Event Description

This event displays memory statistics for debugging.

Event Parameters

Status
Size

1 byte(s)

Range

See Status Table

Module
Size

1 byte(s)

Range

Value

Description

0x00

HCI TL

0x01

Host TL

cmdID
Size

1 byte(s)

Range

Value

Description

0x01

Light Heap Statistic

0x02

Full Heap Statistic (requieres HEAPMGR_METRICS)

0x04

Thread usage Statistic (requieres HEAPMGR_METRICS)

cmdID
Condition

( (cmdID & 0x01) == 0x01)

Size

1 byte(s)

Range

Value

Description

0x01

Light Heap Statistic

0x02

Full Heap Statistic (requieres HEAPMGR_METRICS)

0x04

Thread usage Statistic (requieres HEAPMGR_METRICS)

Heap Size
Condition

( (cmdID & 0x01) == 0x01)

Size

4 byte(s)

Range

Heap Size Free
Condition

( (cmdID & 0x01) == 0x01)

Size

4 byte(s)

Range

Biggest free buffer Available
Condition

( (cmdID & 0x01) == 0x01)

Size

4 byte(s)

Range

cmdID
Condition

( (cmdID & 0x02) == 0x02)

Size

1 byte(s)

Range

Value

Description

0x01

Light Heap Statistic

0x02

Full Heap Statistic (requieres HEAPMGR_METRICS)

0x04

Thread usage Statistic (requieres HEAPMGR_METRICS)

Heap Fail number
Condition

( (cmdID & 0x02) == 0x02)

Size

2 byte(s)

Range

Heap Allocated
Condition

( (cmdID & 0x02) == 0x02)

Size

4 byte(s)

Range

Heap Max Allocated
Condition

( (cmdID & 0x02) == 0x02)

Size

4 byte(s)

Range

cmdID
Condition

( (cmdID & 0x04) ==0x04)

Size

1 byte(s)

Range

Value

Description

0x01

Light Heap Statistic

0x02

Full Heap Statistic (requieres HEAPMGR_METRICS)

0x04

Thread usage Statistic (requieres HEAPMGR_METRICS)

Number of Thread
Condition

( (cmdID & 0x04) ==0x04)

Size

1 byte(s)

Range

An array of size “Count” will be returned containing the parameters starting here:

Priority
Condition

( (cmdID & 0x04) ==0x04)

Size

1 byte(s)

Range

Handle
Condition

( (cmdID & 0x04) ==0x04)

Size

2 byte(s)

Range

max Stack used
Condition

( (cmdID & 0x04) ==0x04)

Size

2 byte(s)

Range

stack size
Condition

( (cmdID & 0x04) ==0x04)

Size

2 byte(s)

Range

The array of parameters ends here.