X-Git-Url: https://review.openocd.org/gitweb?a=blobdiff_plain;f=doc%2Fopenocd.texi;h=455e6fbe84b1ebdd6eaa9adf78ad29fe592fa1f7;hb=3c954fbd8933f0f8e6e988b28e65881a3401cb2b;hp=f614c62949add89d247eb440858b36cb0d6add33;hpb=47d4224d48199e700f7f685c7965a9864dde5f20;p=openocd.git diff --git a/doc/openocd.texi b/doc/openocd.texi index f614c62949..455e6fbe84 100644 --- a/doc/openocd.texi +++ b/doc/openocd.texi @@ -156,9 +156,9 @@ USB-based, parallel port-based, and other standalone boxes that run OpenOCD internally. @xref{Debug Adapter Hardware}. @b{GDB Debug:} It allows ARM7 (ARM7TDMI and ARM720t), ARM9 (ARM920T, -ARM922T, ARM926EJ--S, ARM966E--S), XScale (PXA25x, IXP42x) and -Cortex-M3 (Stellaris LM3, ST STM32 and Energy Micro EFM32) based cores to be -debugged via the GDB protocol. +ARM922T, ARM926EJ--S, ARM966E--S), XScale (PXA25x, IXP42x), Cortex-M3 +(Stellaris LM3, ST STM32 and Energy Micro EFM32) and Intel Quark (x10xx) +based cores to be debugged via the GDB protocol. @b{Flash Programming:} Flash writing is supported for external CFI-compatible NOR flashes (Intel and AMD/Spansion command set) and several @@ -666,7 +666,9 @@ to benefit from new features and bugfixes in Jim-Tcl. Properly installing OpenOCD sets up your operating system to grant it access to the debug adapters. On Linux, this usually involves installing a file -in @file{/etc/udev/rules.d,} so OpenOCD has permissions. MS-Windows needs +in @file{/etc/udev/rules.d,} so OpenOCD has permissions. An example rules file +that works for many common adapters is shipped with OpenOCD in the +@file{contrib} directory. MS-Windows needs complex and confusing driver configuration for every peripheral. Such issues are unique to each operating system, and are not detailed in this User's Guide. @@ -5687,6 +5689,23 @@ unlock str9 device. @end deffn +@deffn {Flash Driver} nrf51 +All members of the nRF51 microcontroller families from Nordic Semiconductor +include internal flash and use ARM Cortex-M0 core. + +@example +flash bank $_FLASHNAME nrf51 0 0x00000000 0 0 $_TARGETNAME +@end example + +Some nrf51-specific commands are defined: + +@deffn Command {nrf51 mass_erase} +Erases the contents of the code memory and user information +configuration registers as well. It must be noted that this command +works only for chips that do not have factory pre-programmed region 0 +code. +@end deffn +@end deffn @section mFlash @@ -7542,6 +7561,47 @@ the peripherals. @xref{targetevents,,Target Events}. @end deffn +@section Intel Architecture + +Intel Quark X10xx is the first product in the Quark family of SoCs. It is an IA-32 +(Pentium x86 ISA) compatible SoC. The core CPU in the X10xx is codenamed Lakemont. +Lakemont version 1 (LMT1) is used in X10xx. The CPU TAP (Lakemont TAP) is used for +software debug and the CLTAP is used for SoC level operations. +Useful docs are here: https://communities.intel.com/community/makers/documentation +@itemize +@item Intel Quark SoC X1000 OpenOCD/GDB/Eclipse App Note (web search for doc num 330015) +@item Intel Quark SoC X1000 Debug Operations User Guide (web search for doc num 329866) +@item Intel Quark SoC X1000 Datasheet (web search for doc num 329676) +@end itemize + +@subsection x86 32-bit specific commands +The three main address spaces for x86 are memory, I/O and configuration space. +These commands allow a user to read and write to the 64Kbyte I/O address space. + +@deffn Command {x86_32 idw} address +Display the contents of a 32-bit I/O port from address range 0x0000 - 0xffff. +@end deffn + +@deffn Command {x86_32 idh} address +Display the contents of a 16-bit I/O port from address range 0x0000 - 0xffff. +@end deffn + +@deffn Command {x86_32 idb} address +Display the contents of a 8-bit I/O port from address range 0x0000 - 0xffff. +@end deffn + +@deffn Command {x86_32 iww} address +Write the contents of a 32-bit I/O port to address range 0x0000 - 0xffff. +@end deffn + +@deffn Command {x86_32 iwh} address +Write the contents of a 16-bit I/O port to address range 0x0000 - 0xffff. +@end deffn + +@deffn Command {x86_32 iwb} address +Write the contents of a 8-bit I/O port to address range 0x0000 - 0xffff. +@end deffn + @section OpenRISC Architecture The OpenRISC CPU is a soft core. It is used in a programmable SoC which can be @@ -8369,7 +8429,7 @@ should be passed in to the proc in question. By "low-level," we mean commands that a human would typically not invoke directly. -Low-level commands are (should be) prefixed with "ocd_"; e.g. +Some low-level commands need to be prefixed with "ocd_"; e.g. @command{ocd_flash_banks} is the low-level API upon which @command{flash banks} is implemented. @@ -8383,6 +8443,16 @@ Convert a Tcl array to memory locations and write the values @item @b{ocd_flash_banks} <@var{driver}> <@var{base}> <@var{size}> <@var{chip_width}> <@var{bus_width}> <@var{target}> [@option{driver options} ...] Return information about the flash banks + +@item @b{capture} <@var{command}> + +Run <@var{command}> and return full log output that was produced during +its execution. Example: + +@example +> capture "reset init" +@end example + @end itemize OpenOCD commands can consist of two words, e.g. "flash banks". The @@ -8417,6 +8487,24 @@ We should add support for a variable like Tcl variable is jim, not real tcl). @end quotation +@section Tcl RPC server +@cindex RPC + +OpenOCD provides a simple RPC server that allows to run arbitrary Tcl +commands and receive the results. + +To access it, your application needs to connect to a configured TCP port +(see @command{tcl_port}). Then it can pass any string to the +interpreter terminating it with @code{0x1a} and wait for the return +value (it will be terminated with @code{0x1a} as well). This can be +repeated as many times as desired without reopening the connection. + +Remember that most of the OpenOCD commands need to be prefixed with +@code{ocd_} to get the results back. Sometimes you might also need the +@command{capture} command. + +See @file{contrib/rpc_examples/} for specific client implementations. + @node FAQ @chapter FAQ @cindex faq