User Guide - nxpdebugmbox

This user’s guide describes how to use nxpdebugmbox application.

Command line interface

nxpdebugmbox

Tool for working with Debug Mailbox.

nxpdebugmbox [OPTIONS] COMMAND [ARGS]...

Options

-i, --interface <interface>

Probe interface selection,if not specified, all available debug probe interfaces are used.

Options

pyocd | jlink | pemicro

-s, --serial-no <serial_no>

Debug probe hardware ID/serial number to select the probe in system.

-p, --protocol <VERSION>

Set the protocol version. Default is 1.0 (RSA). Available options are: 1.0, 1.1, 2.0, 2.1, 2.2

Options

1.0 | 1.1 | 2.0 | 2.1 | 2.2

-t, --timing <timing>

Time of extra delay after reset sequence, defaults to 1.0 second

-n, --no-reset

Omit reset of debug mailbox during initialization, default behavior is reset debug mailbox during initialization.

-o, --debug-probe-option <debug_probe_option>

This option could be used multiply to setup non-standard option for debug probe. The example of use: -o KEY=VALUE

--operation-timeout <operation_timeout>

Special option to change the standard operation timeout used for communication with debug mailbox. Default value is 4000ms.

-v, --verbose

Print more detailed information

-vv, --debug

Display more debugging information.

--version

Show the version and exit.

--help

Show this message and exit.

auth

Perform the Debug Authentication.

nxpdebugmbox auth [OPTIONS]

Options

-b, --beacon <beacon>

Authentication beacon

-c, --certificate <certificate>

Path to Debug Credentials.

-k, --key <key>

Path to DCK private key.

-n, --no-exit

When used, exit debug mailbox command is not executed after debug authentication.

blankauth

Debug Authentication for Blank Device.

nxpdebugmbox blankauth [OPTIONS]

Options

-f, --file <file>

Required Path to token file (string hex format).

-n, --no-exit

When used, exit debug mailbox command is not executed after debug authentication.

erase

Erase Flash.

nxpdebugmbox erase [OPTIONS]

exit

Exit DebugMailBox.

nxpdebugmbox exit [OPTIONS]

famode

Set Fault Analysis Mode.

nxpdebugmbox famode [OPTIONS]

gendc

Generate debug certificate (DC).

PATH - path to dc file
nxpdebugmbox gendc [OPTIONS] PATH

Options

-p, --protocol <VERSION>
Set the protocol version. Default is 1.0 (RSA).
NXP Protocol Version Encryption Type
1.0 RSA 2048
1.1 RSA 4096
2.0 NIST P-256 SECP256R1
2.1 NIST P-384 SECP384R1
2.2 NIST P-521 SECP521R1
-c, --config <config>

Required Specify YAML credential config file.

-e, --elf2sb-config <elf2sb_config>

Specify Root Of Trust from configuration file used by elf2sb tool

--force

Force overwriting of an existing file. Create destination folder, if doesn’t exist already.

--plugin <plugin>

External python file containing a custom SignatureProvider implementation.

Arguments

PATH

Required argument

get-cfg-template

Generate the template of Debug Credentials YML configuration file.

PATH - file name path to write template config file
nxpdebugmbox get-cfg-template [OPTIONS] PATH

Options

-f, --force

Force overwriting of an existing file. Create destination folder, if doesn’t exist already.

Arguments

PATH

Required argument

get-crp

Get CRP level.

Note: This command should be called after ‘start’ command and with no-reset ‘-n’ option.

nxpdebugmbox get-crp [OPTIONS]

ispmode

Enter ISP Mode.

nxpdebugmbox ispmode [OPTIONS]

Options

-m, --mode <mode>

Required

read-memory

Reads the memory and writes it to the file or stdout.

Returns the contents of memory at the given <ADDRESS>, for a specified <BYTE_COUNT>. Data are read by 4 bytes at once and are store in little endian format! | ADDRESS - starting address | BYTE_COUNT - number of bytes to read | FILE - store result into this file, if not specified use stdout

nxpdebugmbox read-memory [OPTIONS] ADDRESS BYTE_COUNT FILE

Options

-h, --use-hexdump

Use hexdump format

Arguments

ADDRESS

Required argument

BYTE_COUNT

Required argument

FILE

Optional argument

start

Start DebugMailBox.

nxpdebugmbox start [OPTIONS]

start-debug-session

Start debug session.

nxpdebugmbox start-debug-session [OPTIONS]

test-connection

Method just try if the device debug port is opened or not.

nxpdebugmbox test-connection [OPTIONS]

write-memory

Writes memory from a file or a hex-data.

Writes memory at <ADDRESS> from <FILE> or <HEX-DATA> Writes a provided buffer to a specified <BYTE_COUNT> in memory.

ADDRESS - starting address
FILE - write the content of this file
BYTE_COUNT - if specified, load only first BYTE_COUNT number of bytes from file
HEX-DATA - string of hex values: {{112233}}, {{11 22 33}}
nxpdebugmbox write-memory [OPTIONS] ADDRESS FILE[,BYTE_COUNT] | {{HEX-DATA}}

Arguments

ADDRESS

Required argument

FILE[,BYTE_COUNT] | {{HEX-DATA}}

Required argument