doc: Update documentation for EM Starter Kit

* Change emsk to EM Starter Kit
* Fix some typos
* Add more statement for steps of using EM Starter Kit

Signed-off-by: Huaqi Fang <huaqi.fang@synopsys.com>
This commit is contained in:
Huaqi Fang 2017-05-18 02:48:54 -04:00 committed by ruuddw
parent 2bcd17e1af
commit 70a7c89021

View file

@ -30,9 +30,10 @@ The lastest version of EM Starter Kit is 2.3, developer can upgrade from
The default configuration for EM Starter Kit boards can be found in
:file:`boards/arc/em_starterkit/em_starterkit_defconfig`.
The default SOC for this board is the EM9D. This configuration is a Harvard
Architecture, with a separate instruction bus and data bus. Instruction memory
is called ICCM and data memory is called DCCM. The configuration file for EM9D
The default SoC for this board supported in Zephyr is the EM9D.
This configuration is a Harvard Architecture, with a separate
instruction bus and data bus. Instruction memory is called ICCM
and data memory is called DCCM. The configuration file for EM9D
is found in :file:`arch/arc/soc/em9d/Kconfig.defconfig`.
If you have a larger program, you can select the EM7D or EM11D, which gives
@ -42,7 +43,8 @@ is found in :file:`arch/arc/soc/em7d/Kconfig.defconfig` and EM11D is found in
.. note::
EM7D has secureshield feature, which is not supported in Zephyr currently.
EM7D of EM Starter Kit 2.3 has secureshield feature,
which is not supported in Zephyr currently.
Hardware
@ -56,8 +58,8 @@ to support attachment of GPIO, I2C, UART or SPI devices.
The board also has a 16MB SPI-FLASH and an SDCard for storage. There are 9 LEDs,
3 buttons, and 4 dip switches that can be used with GPIO.
The Xilinx Spartan(R)-6 LX150 FPGA can auto-load one of 3 FPGA SOC bit files
which have the EM7D, EM9D, or EM11D SOC.
The Xilinx Spartan(R)-6 LX150 FPGA can auto-load one of 3 FPGA SoC bit files
which have the EM7D, EM9D, or EM11D SoC.
Documentation and general information for the board can be found at the
`embARC-website`_, which also includes some free sample software.
@ -73,8 +75,8 @@ use of a large variety of pluggable modules for storage, communications,
sensors, displays, etc. With the Pmod interface, you can prototype your
applications using the Zephyr RTOS.
The table below shows which drivers are supported and which functionality can be
found on which architectures:
The table below shows which drivers are supported and which functionality can
be found on which architectures:
+-----------+------------+-----+-------+-----------------------+
| Interface | Controller |EM9D | EM11D | Driver/Component |
@ -102,7 +104,7 @@ The SPI-Flash also holds 3 (or 4) separate FPGA CPU bit files, selectable via
dip switch.
The SPI-Flash is also programmed with a bootloader. The booloader can copy a
program image from SPI-Flash into executable memory. Zephyr initialization will
program image from SPI-Flash into executable memory. Zephyr initialization will
copy the initialized data section to the data memory if CONFIG_XIP is used.
@ -130,6 +132,26 @@ pieces of hardware are required.
See http://store.digilentinc.com/pmod-modules or develop your
custom interfaces to attach to the Pmod connector.
Set up the ARC EM Starter Kit
=============================
To run Zephyr application on correct arc core of EM Starter Kit, you need to
setup the board correctly.
* Connect the digilent usb cable from your host to the board.
* Connect the 5V DC power supply to your board.
* Select the core configuration of the board by choosing correct dip switch
SW1 settings, then press then FPGA configure button located above the letter
'C' of the ARC logo on the board.
* Then the board will be reconfigured with selected core configuration, you
can download and debug Zephyr application now.
* If you want to know more about how to use this board, you can take a look
at the **ARC EM Starter Kit User Guide**.
Building Sample Applications
==============================
@ -162,8 +184,8 @@ To build the application, execute make:
Connecting Serial Output
=========================
In the default configuration, Zephyr's EM Starter Kit images support serial output
via the UART1 on the board. To enable serial output:
In the default configuration, Zephyr's EM Starter Kit images support
serial output via the UART1 on the board. To enable serial output:
On your development environment, you will need to:
@ -181,15 +203,12 @@ Parity: None
Stopbits: 1
========= =====
Using the latest version of Zephyr SDK(>=0.9), you can debug and flash
EM Starterkit directly.
Boot up the SOC by pressing the "C" button. Be sure the digilent cable
is attached from your host to the EM Starter Kit board.
Debugging
==========
Using the latest version of Zephyr SDK(>=0.9), you can debug and flash
EM Starterkit directly.
Build and debug the application with the following commands:
.. code-block:: console
@ -200,18 +219,19 @@ Build and debug the application with the following commands:
At this point you can do your normal debug session. Set breakpoints and then
'c' to continue into the program.
Launch the debug server on the emsk:
Launch the debug server on the EM Starter Kit:
.. code-block:: console
$ make BOARD=em_starterkit debugserver
Connect to the debug server at the emsk from a second console:
Connect to the debug server at the EM Starter Kit from a second console:
.. code-block:: console
$ cd <my app>
$ $ZEPHYR_SDK_INSTALL_DIR/sysroots/x86_64-pokysdk-linux/usr/bin/arc-zephyr-elf/arc-zephyr-elf-gdb outdir/em_starterkit/zephyr.elf
$ $ZEPHYR_SDK_INSTALL_DIR/sysroots/x86_64-pokysdk-linux/usr/bin/arc-zephyr-elf/arc-zephyr-elf-gdb \
outdir/em_starterkit/zephyr.elf
(gdb) target remote localhost:3333
(gdb) load
(gdb) b main
@ -220,16 +240,16 @@ Connect to the debug server at the emsk from a second console:
Flashing
========
If you just want to download the application to the emsk's CCM or DDR and run,
you can also use this command to achieve this.
If you just want to download the application to the EM Starter Kit's CCM
or DDR and run, you can also use this command to achieve this.
.. code-block:: console
$ make BOARD=em_starterkit flash
This command still use openocd and gdb to load application elf file to emsk,
but it will load application and then run immediately. If power is lost,
the application will also lost due to power loss.
This command still uses openocd and gdb to load application elf file
to EM Starter Kit, but it will load application and then run immediately.
If power is lost, the application will also lost due to power loss.
Most of the time you will not be flashing your program but will instead
debug it using openocd and gdb. The program can be download via the USB