Escapement Project

The verge command

Every command, and the doc that explains it. verge help COMMAND, or --help after any command, lists its options.

Which probe a command acts on#

A command acts on one probe. --serial names it by its serial number, before or after the command. Without it, verge takes the only attached probe the command can act on. When several could be meant, it lists them and asks at a terminal; elsewhere it stops and asks for --serial.

A Pro command, such as energy, looks only at Pros running Verge, so a standalone MCU-Link beside a Pro needs no serial. list and release show only the probe --serial names.

Options every command takes#

optionwhat it does
--serial SERIALthe probe to act on, as above
-v, --verbosesay more about what is happening; twice for USB-level detail
--repo OWNER/NAMEthe GitHub repository Verge releases come from; VERGE_REPO too. The default is Escapement-Project/mculink-verge
--github-token TOKENa GitHub token, for a private repository; GITHUB_TOKEN too. Public releases need none, and a token GitHub refuses stops the lookup

Exit status#

statuswhat it means
0it worked
1it failed, or the answer to its question was no
2verge could not read the command line
3the probe came back in ISP mode after a flash or a reset, so it does not run an image yet; the message says what to do
130Ctrl-C stopped an update or a question

Ctrl-C is also how a recording, a watch or a batch ends. Ended that way, it exits with the status that run gives.

Commands#

commandwhat it doesmore
listlists every attached MCU-Link: its USB port and serial number, its firmware and board, and how it can update. The default when you give no commandSee what is attached
updateinstalls a firmware on a probe, the best way its state allowsUpdating and recovery
batchupdates probes one after another as you plug them inUpdating many probes
ispworks with a probe's ROM bootloader: enter, flash, reset and infoISP mode
releaseshows a Verge release, and how each attached probe compares to itbelow
inspectsays what an image file puts into flashbelow
readreads target memory over SWD, JTAG or cJTAGbelow
diodrives and reads the DIO pins of an MCU-Link or MCU-Link Pro running Verge; dio record records a standalone MCU-Link'sbelow, Probes and jumpers, The Pro
restartrestarts a probe running Verge, even one a debugger holds or whose CMSIS-DAP has stopped answeringbelow
powerreads or switches the target supply of an MCU-Link Pro running VergeThe Pro
energymeasures a target's voltage, current and energy through an MCU-Link Pro running VergeEnergy capture

restart#

verge restart

Restarts a probe running Verge, as unplugging it would, and waits for it to come back. The request goes to the probe's USB core rather than through CMSIS-DAP, so it works while a debugger holds the probe, and when a CMSIS-DAP command never finishes. Everything the probe holds is lost: the DIO pins go back to inputs, a Pro's target supply turns off and an energy capture ends.

dio record#

verge dio record --out FILE [--for DURATION] [--pins PINS]

Records a standalone MCU-Link's DIO pins to a tickwave recording, which tickwave opens. Name the file .tickwave; a .sr or .csv name is refused, since the file holds neither. Each pin --pins names is a digital channel, all four unless you name some. The probe stamps an edge as its interrupt takes it, a little after the edge itself, to 7 ns. There are no energy readings. A Pro without its energy measurement circuit records the same way. Any other Pro records its pins beside its energy capture, with verge energy record --dio (Energy capture).

The recording goes through Verge Aux, so a debugger can hold the probe meanwhile, and verge dio can drive the pins through CMSIS-DAP while it runs. It runs until --for is up, or until Ctrl-C. Where the probe lost edges, the recording marks the pins unknown. A crash loses about the last second. The probe reports its time while the pins are quiet, so the recording a crash leaves covers quiet stretches too, even before the first edge. Once recording ends, verge rewrites the file with full-size blocks.

release#

verge release [TAG]

Shows a Verge release, the latest unless you give a tag, and how each attached probe compares to it. A tag works with or without its v.

inspect#

verge inspect FILE

Reads an ELF or S-record file and says what it puts into flash, including the boards a Verge image declares. Touches no USB device. The board declaration.

read#

verge read --chip CHIP [--protocol swd|jtag|cjtag] [--speed KHZ]
           [--cjtag-format FORMAT] [--time] WIDTH ADDRESS WORDS

Reads target memory through a probe over SWD, JTAG or cJTAG, as probe-rs's read does. It prints probe-rs's hex table on stdout and nothing else: each line is an address and eight values, four for b64. It picks among every probe probe-rs can drive, not only MCU-Links. Like probe-rs's read, it resumes any halted core when it finishes.

argument or optionwhat it does
WIDTHthe width of each value: b8, b16, b32 or b64
ADDRESSthe first address: decimal, 0x hexadecimal, 0o octal or 0b binary
WORDShow many values to read
--chip CHIPthe target chip, as probe-rs names it
--protocolthe wire: swd, the default, jtag or cjtag. cJTAG works on a probe running Verge
--cjtag-format FORMATwith cjtag, the scan format to connect in: oscan1, the default, oscan2, oscan5 or oscan6. Ask only for a format the target has: nothing checks it, and a target without the format has not been tried. Wires and clocks says what each format gains
--speed KHZthe wire clock in kHz; the probe's default when left out
--timeprint the attach and read times on stderr
verge read --chip CC1312R --protocol cjtag b32 0 64

From verge, where changes to this page go.