Skip to content

Commit accca8a

Browse files
committed
boards: ambiq: Add support for the Ambiq Apollo2 EVB board
Adds support for the Ambiq Apollo2 EVB board (AMAPHEVB). Signed-off-by: Sri Surya <srisurya@linumiz.com>
1 parent b5869e5 commit accca8a

File tree

10 files changed

+194
-0
lines changed

10 files changed

+194
-0
lines changed
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# SPDX-License-Identifier: Apache-2.0
2+
#
3+
# Copyright (c) 2025 Linumiz GmbH
4+
# Author: Sri Surya <srisurya@linumiz.com>
5+
6+
config BOARD_APOLLO2_EVB
7+
select SOC_APOLLO2
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# SPDX-License-Identifier: Apache-2.0
2+
#
3+
# Copyright (c) 2025 Linumiz GmbH
4+
# Author: Sri Surya <srisurya@linumiz.com>
5+
6+
if BOARD_APOLLO2_EVB
7+
8+
config SYS_CLOCK_HW_CYCLES_PER_SEC
9+
default 32768
10+
11+
endif
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
/*
2+
* SPDX-License-Identifier: Apache-2.0
3+
*
4+
* Copyright (c) 2025 Linumiz GmbH
5+
* Author: Sri Surya <srisurya@linumiz.com>
6+
*/
7+
8+
#include <dt-bindings/pinctrl/ambiq-apollo2-pinctrl.h>
9+
10+
&pinctrl {
11+
uart0_default: uart0_default {
12+
group1 {
13+
pinmux = <UART0TX_P22>;
14+
};
15+
group2 {
16+
pinmux = <UART0RX_P23>;
17+
input-enable;
18+
};
19+
};
20+
};
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
/* SPDX-License-Identifier: Apache-2.0 */
2+
3+
/dts-v1/;
4+
#include <ambiq/ambiq_apollo2.dtsi>
5+
6+
#include "apollo2_evb-pinctrl.dtsi"
7+
8+
/ {
9+
model = "Ambiq Apollo2 evaluation board";
10+
compatible = "ambiq,apollo2_evb";
11+
12+
chosen {
13+
zephyr,sram = &sram0;
14+
zephyr,flash = &flash0;
15+
zephyr,console = &uart0;
16+
zephyr,shell-uart = &uart0;
17+
zephyr,uart-mcumgr = &uart0;
18+
zephyr,uart-pipe = &uart0;
19+
};
20+
};
21+
22+
&flash0 {
23+
erase-block-size = <8192>;
24+
write-block-size = <4>;
25+
26+
partitions {
27+
compatible = "fixed-partitions";
28+
#address-cells = <1>;
29+
#size-cells = <1>;
30+
31+
boot_partition: partition@c000 {
32+
label = "mcuboot";
33+
reg = <0x0000c000 0xc000>;
34+
};
35+
slot0_partition: partition@18000 {
36+
label = "image-0";
37+
reg = <0x00018000 0x72000>;
38+
};
39+
slot1_partition: partition@8a000 {
40+
label = "image-1";
41+
reg = <0x0008a000 0x72000>;
42+
};
43+
storage_partition: partition@fc000 {
44+
label = "storage";
45+
reg = <0x000fc000 0x4000>;
46+
};
47+
};
48+
};
49+
50+
&uart0 {
51+
current-speed = <115200>;
52+
pinctrl-0 = <&uart0_default>;
53+
pinctrl-names = "default";
54+
status = "okay";
55+
};
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
identifier: apollo2_evb
2+
name: Apollo2 EVB
3+
type: mcu
4+
arch: arm
5+
ram: 256
6+
flash: 1024
7+
toolchain:
8+
- zephyr
9+
- gnuarmemb
10+
supported:
11+
- uart
12+
testing:
13+
ignore_tags:
14+
- net
15+
vendor: ambiq
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# SPDX-License-Identifier: Apache-2.0
2+
#
3+
# Copyright (c) 2025 Linumiz GmbH
4+
# Author: Sri Surya <srisurya@linumiz.com>
5+
6+
CONFIG_CONSOLE=y
7+
CONFIG_UART_CONSOLE=y
8+
CONFIG_SERIAL=y
9+
CONFIG_UART_INTERRUPT_DRIVEN=y

boards/ambiq/apollo2_evb/board.cmake

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# SPDX-License-Identifier: Apache-2.0
2+
#
3+
# Copyright (c) 2025 Linumiz GmbH
4+
# Author: Sri Surya <srisurya@linumiz.com>
5+
6+
board_runner_args(jlink "--device=AMA2B1KK" "--iface=swd" "--speed=4000")
7+
8+
include(${ZEPHYR_BASE}/boards/common/jlink.board.cmake)

boards/ambiq/apollo2_evb/board.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
board:
2+
name: apollo2_evb
3+
full_name: Apollo2 EVB
4+
vendor: ambiq
5+
socs:
6+
- name: apollo2
Loading
Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
.. zephyr:board:: apollo2_evb
2+
3+
The Apollo2 EVB is a board by Ambiq featuring their ultra-low power Apollo2 SoC.
4+
5+
Hardware
6+
********
7+
8+
The Ambiq Apollo2 SoC provides the following hardware features:
9+
10+
- ARM® Cortex® M4F core with a Floating Point Unit
11+
- Up to 48 MHz operating frequency
12+
- 16 kB 2-way Associative Cache
13+
- Up to 1 MB of flash memory for code/data
14+
- Up to 256 KB of low leakage RAM for code/data
15+
16+
For more information about the Apollo2 SoC and a potential Apollo2 EVB board:
17+
18+
* `Apollo2 SoC Website <https://ambiq.com/apollo2/>`_
19+
* `Apollo2 SoC Datasheet <https://www.fujitsu.com/uk/imagesgig5/Apollo2_Blue_MCU_Data_Sheet_rev0p8.pdf>`_
20+
21+
Supported Features
22+
==================
23+
24+
.. zephyr:board-supported-hw::
25+
26+
Programming and Debugging
27+
=========================
28+
29+
Flashing an application
30+
-----------------------
31+
32+
Connect your device to your host computer using the JLINK USB port.
33+
The sample application :zephyr:code-sample:`hello_world` is used for this example.
34+
Build the Zephyr kernel and application, then flash it to the device:
35+
36+
.. zephyr-app-commands::
37+
:zephyr-app: samples/hello_world
38+
:board: apollo2_evb
39+
:goals: flash
40+
41+
.. note::
42+
``west flash`` requires `SEGGER J-Link software`_ and `pylink`_ Python module
43+
to be installed on you host computer.
44+
45+
Open a serial terminal (minicom, putty, etc.) with the following settings:
46+
47+
- Speed: 115200
48+
- Data: 8 bits
49+
- Parity: None
50+
- Stop bits: 1
51+
52+
Reset the board and you should be able to see on the corresponding Serial Port
53+
the following message:
54+
55+
.. code-block:: console
56+
57+
Hello World! apollo2_evb
58+
59+
.. _SEGGER J-Link software:
60+
https://www.segger.com/downloads/jlink
61+
62+
.. _pylink:
63+
https://github.com/Square/pylink

0 commit comments

Comments
 (0)