Skip to content

Commit 32e39c1

Browse files
vulpes2kartben
authored andcommitted
boards: silabs: add EK2703A support
Based on board files for DK2601B. The EFR32xG24 Explorer Kit (xG24-EK2703A) is similar to the DK2601B but does not have any sensors onboard. Signed-off-by: Daniel Fuchs <[email protected]>
1 parent f0fee21 commit 32e39c1

14 files changed

+546
-0
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Copyright (c) 2024 Norik Systems
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
zephyr_library()
5+
zephyr_library_sources(board.c)
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# EFR32XG24 EK2703A board
2+
3+
# Copyright (c) 2022, Silicon Labs
4+
# SPDX-License-Identifier: Apache-2.0
5+
6+
if BOARD_XG24_EK2703A
7+
8+
config BOARD_XG24_EK2703A
9+
select GPIO
10+
select BOARD_LATE_INIT_HOOK
11+
12+
module = BOARD_EFR32MG24
13+
module-str = Board Control
14+
source "subsys/logging/Kconfig.template.log_config"
15+
16+
endif # BOARD_XG24_EK2703A
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# Copyright (c) 2021, Sateesh Kotapati
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
if BOARD_XG24_EK2703A
5+
6+
config CMU_HFXO_FREQ
7+
default 39000000
8+
9+
config CMU_LFXO_FREQ
10+
default 32768
11+
12+
if SOC_GECKO_USE_RAIL
13+
14+
config FPU
15+
default y
16+
17+
endif # SOC_GECKO_USE_RAIL
18+
19+
if BT
20+
21+
config COMMON_LIBC_MALLOC_ARENA_SIZE
22+
default 8192
23+
24+
endif # BT
25+
26+
endif # BOARD_XG24_EK2703A
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Copyright (c) 2021, Sateesh Kotapati
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
config BOARD_XG24_EK2703A
5+
select SOC_PART_NUMBER_EFR32MG24B210F1536IM48
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
/*
2+
* Copyright (c) 2021 Sateesh Kotapati
3+
*
4+
* SPDX-License-Identifier: Apache-2.0
5+
*/
6+
7+
#include <zephyr/init.h>
8+
#include <zephyr/drivers/gpio.h>
9+
#include <zephyr/sys/printk.h>
10+
#include <zephyr/logging/log.h>
11+
12+
LOG_MODULE_REGISTER(efr32xg24_ek2703a, CONFIG_BOARD_EFR32MG24_LOG_LEVEL);
13+
14+
void board_late_init_hook(void)
15+
{
16+
int ret;
17+
18+
static struct gpio_dt_spec wake_up_gpio_dev =
19+
GPIO_DT_SPEC_GET(DT_NODELABEL(wake_up_trigger), gpios);
20+
21+
if (!gpio_is_ready_dt(&wake_up_gpio_dev)) {
22+
LOG_ERR("Wake-up GPIO device was not found!\n");
23+
}
24+
ret = gpio_pin_configure_dt(&wake_up_gpio_dev, GPIO_OUTPUT_ACTIVE);
25+
if (ret < 0) {
26+
LOG_ERR("Failed to configure wake-up GPIO!\n");
27+
}
28+
}
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Copyright (c) 2021, Sateesh Kotapati
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
board_runner_args(jlink "--device=EFR32MG24BxxxF1536" "--reset-after-load")
5+
include(${ZEPHYR_BASE}/boards/common/jlink.board.cmake)
6+
7+
board_runner_args(silabs_commander "--device=EFR32MG24B210F1536IM48")
8+
include(${ZEPHYR_BASE}/boards/common/silabs_commander.board.cmake)
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
board:
2+
name: xg24_ek2703a
3+
full_name: EFR32xG24 Explorer Kit (xG24-EK2703A)
4+
vendor: silabs
5+
socs:
6+
- name: efr32mg24b210f1536im48
Lines changed: 163 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,163 @@
1+
.. zephyr:board:: xg24_ek2703a
2+
3+
Overview
4+
********
5+
6+
The EFR32xG24 Explorer Kit (xG24-EK2703A) contains
7+
a Wireless System-On-Chip from the EFR32MG24 family built on an
8+
ARM Cortex®-M33 processor with excellent low power capabilities.
9+
10+
Hardware
11+
********
12+
13+
- EFR32MG24B210F1536IM48-B Mighty Gecko SoC
14+
- CPU core: ARM Cortex®-M33 with FPU
15+
- Flash memory: 1536 kB
16+
- RAM: 256 kB
17+
- Transmit power: up to +10 dBm
18+
- Operation frequency: 2.4 GHz
19+
- Crystals for LFXO (32.768 kHz) and HFXO (39 MHz).
20+
21+
For more information about the EFR32MG24 SoC and BRD2703A board, refer to these
22+
documents:
23+
24+
- `EFR32MG24 Website`_
25+
- `EFR32MG24 Datasheet`_
26+
- `EFR32xG24 Reference Manual`_
27+
- `BRD2703A User Guide`_
28+
29+
Supported Features
30+
==================
31+
32+
The ``xg24_ek2703a`` board supports the following hardware features:
33+
34+
+-----------+------------+-------------------------------------+
35+
| Interface | Controller | Driver/Component |
36+
+===========+============+=====================================+
37+
| MPU | on-chip | memory protection unit |
38+
+-----------+------------+-------------------------------------+
39+
| NVIC | on-chip | nested vector interrupt controller |
40+
+-----------+------------+-------------------------------------+
41+
| SYSTICK | on-chip | systick |
42+
+-----------+------------+-------------------------------------+
43+
| COUNTER | on-chip | stimer |
44+
+-----------+------------+-------------------------------------+
45+
| FLASH | on-chip | flash memory |
46+
+-----------+------------+-------------------------------------+
47+
| GPIO | on-chip | gpio |
48+
+-----------+------------+-------------------------------------+
49+
| UART | on-chip | serial |
50+
+-----------+------------+-------------------------------------+
51+
| TRNG | on-chip | semailbox |
52+
+-----------+------------+-------------------------------------+
53+
| WATCHDOG | on-chip | watchdog |
54+
+-----------+------------+-------------------------------------+
55+
| I2C(M/S) | on-chip | i2c |
56+
+-----------+------------+-------------------------------------+
57+
| RADIO | on-chip | bluetooth |
58+
+-----------+------------+-------------------------------------+
59+
60+
Other hardware features are currently not supported by the port.
61+
62+
Connections and IOs
63+
===================
64+
65+
In the following table, the column **Name** contains Pin names. For example, PA2
66+
means Pin number 2 on PORTA, as used in the board's datasheets and manuals.
67+
68+
+-------+-------------+-------------------------------------+
69+
| Name | Function | Usage |
70+
+=======+=============+=====================================+
71+
| PA4 | GPIO | LED0 |
72+
+-------+-------------+-------------------------------------+
73+
| PA7 | GPIO | LED1 |
74+
+-------+-------------+-------------------------------------+
75+
| PB2 | GPIO | Push Button 0 |
76+
+-------+-------------+-------------------------------------+
77+
| PB3 | GPIO | Push Button 1 |
78+
+-------+-------------+-------------------------------------+
79+
| PA5 | USART0_TX | UART Console VCOM_TX US0_TX |
80+
+-------+-------------+-------------------------------------+
81+
| PA6 | USART0_RX | UART Console VCOM_RX US0_RX |
82+
+-------+-------------+-------------------------------------+
83+
84+
The default configuration can be found in
85+
:zephyr_file:`boards/silabs/dev_kits/xg24_ek2703a/xg24_ek2703a_defconfig`
86+
87+
System Clock
88+
============
89+
90+
The EFR32MG24 SoC is configured to use the 39 MHz external oscillator on the
91+
board.
92+
93+
Serial Port
94+
===========
95+
96+
The EFR32MG24 SoC has one USART and two EUSARTs.
97+
USART0 is connected to the board controller and is used for the console.
98+
99+
Programming and Debugging
100+
*************************
101+
102+
.. note::
103+
Before using the kit the first time, you should update the J-Link firmware
104+
in Simplicity Studio.
105+
106+
Flashing
107+
========
108+
109+
The sample application :zephyr:code-sample:`hello_world` is used for this example.
110+
Build the Zephyr kernel and application:
111+
112+
.. zephyr-app-commands::
113+
:zephyr-app: samples/hello_world
114+
:board: xg24_ek2703a
115+
:goals: build
116+
117+
Connect the xg24_ek2703a to your host computer using the USB port and you
118+
should see a USB connection.
119+
120+
Open a serial terminal (minicom, putty, etc.) with the following settings:
121+
122+
- Speed: 115200
123+
- Data: 8 bits
124+
- Parity: None
125+
- Stop bits: 1
126+
127+
Reset the board and you'll see the following message on the corresponding serial port
128+
terminal session:
129+
130+
.. code-block:: console
131+
132+
Hello World! xg24_ek2703a
133+
134+
Bluetooth
135+
=========
136+
137+
To use the BLE function, run the command below to retrieve necessary binary
138+
blobs from the SiLabs HAL repository.
139+
140+
.. code-block:: console
141+
142+
west blobs fetch hal_silabs
143+
144+
Then build the Zephyr kernel and a Bluetooth sample with the following
145+
command. The :zephyr:code-sample:`bluetooth_observer` sample application is used in
146+
this example.
147+
148+
.. zephyr-app-commands::
149+
:zephyr-app: samples/bluetooth/observer
150+
:board: xg24_ek2703a
151+
:goals: build
152+
153+
.. _EFR32MG24 Website:
154+
https://www.silabs.com/wireless/zigbee/efr32mg24-series-2-socs#
155+
156+
.. _EFR32MG24 Datasheet:
157+
https://www.silabs.com/documents/public/data-sheets/efr32mg24-datasheet.pdf
158+
159+
.. _EFR32xG24 Reference Manual:
160+
https://www.silabs.com/documents/public/reference-manuals/efr32xg24-rm.pdf
161+
162+
.. _BRD2703A User Guide:
163+
https://www.silabs.com/documents/public/user-guides/ug533-xg24-ek2703a.pdf
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Copyright (c) 2022, Antmicro
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
description: GPIO Wake Up Trigger for EFR32MG24
5+
6+
compatible: "silabs,gecko-wake-up-trigger"
7+
8+
include: base.yaml
9+
10+
properties:
11+
gpios:
12+
type: phandle-array
13+
required: true
14+
description: |
15+
GPIO used as wake up trigger from EM4 sleep
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Copyright (c) 2021 Linaro Limited
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
# SPI is implemented via usart so node name isn't spi@...
5+
list(APPEND EXTRA_DTC_FLAGS "-Wno-spi_bus_bridge")

0 commit comments

Comments
 (0)