boards/arm/mps2/doc/mps2_armv7m.rst
.. _mps2_armv7m_board:
ARM V2M MPS2 Armv7-m (AN385/AN386/AN500) ########################################
Overview
The mps2/an385, mps2/an386, and mps2/an500 board targets are three of
the mps2 Armv7-m based board targets supported in Zephyr. This document
provides details about the support provided for these three Armv7-m mps2 board targets
(AN385, AN386, AN500) and the following devices:
.. image:: img/mps2.jpg :align: center :alt: ARM V2M MPS2
In addition to enabling actual hardware usage, these board targets can
also use FVP_ to emulate the platforms running on the MPS2+.
More information about the board can be found at the V2M MPS2 Website_.
The application note for each of the board can be found as follows:
Application Note AN385_Application Note AN386_Application Note AN500_AN385 is also supported to run with QEMU, and is set to run with QEMU by default.
.. note:: These board targets makes no claims about its suitability for use with actual MPS2 hardware systems, or any other hardware system.
Hardware
ARM V2M MPS2 provides the following hardware components:
ARM Cortex-M Chip
ARM IoT Subsystem for Cortex-M
Form factor: 140x120cm
ZBTSRAM: 8MB single cycle SRAM, 16MB PSRAM
Video: QSVGA touch screen panel, 4bit RGB VGA connector
Audio: Audio Codec
Debug:
Expansion
.. note:: 4 MB of flash memory (in ZBTSRAM 1, starting at address 0x00400000) and 4 MB of RAM (in ZBTSRAM 2 & 3, starting at address 0x20000000) are available.
mps2 for details.MPS2 is a Cortex-M based SoC and has 15 fixed exceptions and 45 IRQs.
A Cortex-M3/4/7-based board uses vectored exceptions. This means each exception calls a handler directly from the vector table.
Handlers are provided for exceptions 1-6, 11-12, and 14-15. The table here identifies the handlers used for each exception.
+------+------------+----------------+--------------------------+ | Exc# | Name | Remarks | Used by Zephyr Kernel | +======+============+================+==========================+ | 1 | Reset | | system initialization | +------+------------+----------------+--------------------------+ | 2 | NMI | | system fatal error | +------+------------+----------------+--------------------------+ | 3 | Hard fault | | system fatal error | +------+------------+----------------+--------------------------+ | 4 | MemManage | MPU fault | system fatal error | +------+------------+----------------+--------------------------+ | 5 | Bus | | system fatal error | +------+------------+----------------+--------------------------+ | 6 | Usage | undefined | system fatal error | | | fault | instruction, | | | | | or switch | | | | | attempt to ARM | | | | | mode | | +------+------------+----------------+--------------------------+ | 11 | SVC | | system calls, kernel | | | | | run-time exceptions, | | | | | and IRQ offloading | +------+------------+----------------+--------------------------+ | 12 | Debug | | system fatal error | | | monitor | | | +------+------------+----------------+--------------------------+ | 14 | PendSV | | context switch | +------+------------+----------------+--------------------------+ | 15 | SYSTICK | | system clock | +------+------------+----------------+--------------------------+
The ARM V2M MPS2 Board has 4 GPIO controllers. These controllers are responsible for pin muxing, input/output, pull-up, etc.
All GPIO controller pins are exposed via the following sequence of pin numbers:
Mapping from the ARM MPS2 Board pins to GPIO controllers:
.. rst-class:: rst-columns
Peripheral Mapping:
.. rst-class:: rst-columns
For more details please refer to MPS2 Technical Reference Manual (TRM)_.
The V2M MPS2 main clock is 24 MHz.
The V2M MPS2 processor has five UARTs. Both the UARTs have only two wires for RX/TX and no flow control (CTS/RTS) or FIFO. The Zephyr console output, by default, is utilizing UART0.
Programming and Debugging
V2M MPS2 provides:
Here is an example for the :zephyr:code-sample:hello_world application with AN385.
.. zephyr-app-commands:: :zephyr-app: samples/hello_world :board: mps2/an385 :goals: build
Connect the V2M MPS2 to your host computer using the USB port and you should see a USB connection which exposes a Mass Storage and a USB Serial Port. Copy the generated zephyr.bin in the exposed drive. Reset the board and you should be able to see on the corresponding Serial Port the following message:
.. code-block:: console
Hello World! arm
Here is the same example for running with FVP.
Set the ARMFVP_BIN_PATH environment variable to the location of your FVP you have downloaded from here <FVP_>_
.. code-block:: console
export ARMFVP_BIN_PATH=/home/../FVP_MPS2/
Then build with the same command you would use normally, and run with west build -t run_armfvp.
.. _V2M MPS2 Website: https://developer.mbed.org/platforms/ARM-MPS2/
.. _MPS2 Technical Reference Manual (TRM): https://developer.arm.com/documentation/100112/0200/
.. _Application Note AN385: https://documentation-service.arm.com/static/5ed107a5ca06a95ce53f89e3
.. _Application Note AN386: https://documentation-service.arm.com/static/5ed1094dca06a95ce53f8a9f
.. _Application Note AN500: https://documentation-service.arm.com/static/5ed112fcca06a95ce53f8eb3