Command-Line Tool¶
PyLink ships with a command-line interface that provides common functionality. After you’ve installed the package, the command should be readily available for use.
Python interface for SEGGER J-Link.
usage: pylink [-h] [--version] [-v]
{erase,flash,unlock,license,info,emulator,firmware} ...
Named Arguments¶
- --version
show program’s version number and exit
- -v, --verbose
increase output verbosity
Sub-commands¶
erase¶
Erases the target device.
pylink erase [-h] -t {jtag,swd} -d DEVICE [-s SERIAL_NO | -i IP_ADDR]
Named Arguments¶
- -t, --tif
Possible choices: jtag, swd
target interface (JTAG | SWD)
- -d, --device
specify the target device name
- -s, --serial
specify the J-Link serial number
- -i, --ip_addr
J-Link IP address
flash¶
Flashes firmware from a file to a device connected to a J-Link.
pylink flash [-h] [-a ADDR] -t {jtag,swd} -d DEVICE
[-s SERIAL_NO | -i IP_ADDR]
file
Positional Arguments¶
- file
file to flash onto device
Named Arguments¶
- -a, --addr
start address to flash from
- -t, --tif
Possible choices: jtag, swd
target interface (JTAG | SWD)
- -d, --device
specify the target device name
- -s, --serial
specify the J-Link serial number
- -i, --ip_addr
J-Link IP address
unlock¶
Unlocks a device connected to a J-Link. Note that this will erase the device.
pylink unlock [-h] -t {jtag,swd} -d DEVICE [-s SERIAL_NO | -i IP_ADDR]
{kinetis}
Positional Arguments¶
- name
Possible choices: kinetis
name of MCU to unlock
Named Arguments¶
- -t, --tif
Possible choices: jtag, swd
target interface (JTAG | SWD)
- -d, --device
specify the target device name
- -s, --serial
specify the J-Link serial number
- -i, --ip_addr
J-Link IP address
license¶
Manage the licenses of the J-Link.
pylink license [-h] (-l | -a ADD | -e) [-s SERIAL_NO | -i IP_ADDR]
Named Arguments¶
- -l, --list
list the licenses of the J-Link
- -a, --add
add a custom license to the J-Link
- -e, --erase
erase the custom licenses on the J-Link
- -s, --serial
specify the J-Link serial number
- -i, --ip_addr
J-Link IP address
info¶
Get information about the J-Link.
pylink info [-h] [-p] [-j] [-s SERIAL_NO | -i IP_ADDR]
Named Arguments¶
- -p, --product
print the production information
- -j, --jtag
print the JTAG pin status
- -s, --serial
specify the J-Link serial number
- -i, --ip_addr
J-Link IP address
emulator¶
Query for information about emulators or support.
pylink emulator [-h] (-l [{usb,ip}] | -s SUPPORTED | -t)
Named Arguments¶
- -l, --list
Possible choices: usb, ip
list all the connected emulators
- -s, --supported
query whether a device is supported
- -t, --test
perform a self-test
firmware¶
Modify the J-Link firmware.
pylink firmware [-h] (-d | -u) [-s SERIAL_NO | -i IP_ADDR]
Named Arguments¶
- -d, --downgrade
downgrade the J-Link firmware
- -u, --upgrade
upgrade the J-Link firmware
- -s, --serial
specify the J-Link serial number
- -i, --ip_addr
J-Link IP address
Copyright 2017 Square, Inc.