Initial import
This commit is contained in:
6
boards/heltec/heltec_meshpocket/Kconfig.defconfig
Normal file
6
boards/heltec/heltec_meshpocket/Kconfig.defconfig
Normal file
@@ -0,0 +1,6 @@
|
||||
if BOARD_HELTEC_MESHPOCKET
|
||||
|
||||
config BOARD
|
||||
default "heltec_meshpocket"
|
||||
|
||||
endif # BOARD_HELTEC_MESHPOCKET
|
||||
@@ -0,0 +1,2 @@
|
||||
config BOARD_HELTEC_MESHPOCKET
|
||||
select SOC_NRF52840_QIAA
|
||||
2
boards/heltec/heltec_meshpocket/board.cmake
Normal file
2
boards/heltec/heltec_meshpocket/board.cmake
Normal file
@@ -0,0 +1,2 @@
|
||||
# Heltec MeshPocket — board.cmake
|
||||
include(${ZEPHYR_BASE}/boards/nordic/common/board.cmake)
|
||||
7
boards/heltec/heltec_meshpocket/board.yml
Normal file
7
boards/heltec/heltec_meshpocket/board.yml
Normal file
@@ -0,0 +1,7 @@
|
||||
board:
|
||||
name: heltec_meshpocket
|
||||
full_name: "Heltec MeshPocket"
|
||||
vendor: heltec
|
||||
url: https://heltec.org/project/mesh-pocket/
|
||||
socs:
|
||||
- name: nrf52840
|
||||
@@ -0,0 +1,47 @@
|
||||
/*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*
|
||||
* Heltec MeshPocket — pin control definitions
|
||||
* SoC: nRF52840-QIAA
|
||||
*/
|
||||
|
||||
#include <nordic/nrf52840.dtsi>
|
||||
#include <dt-bindings/pinctrl/nrf-pinctrl.h>
|
||||
|
||||
&pinctrl {
|
||||
uart0_default: uart0_default {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(UART_TX, 0, 6)>;
|
||||
};
|
||||
group2 {
|
||||
psels = <NRF_PSEL(UART_RX, 0, 8)>;
|
||||
bias-pull-up;
|
||||
};
|
||||
};
|
||||
|
||||
uart0_sleep: uart0_sleep {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(UART_TX, 0, 6)>,
|
||||
<NRF_PSEL(UART_RX, 0, 8)>;
|
||||
low-power-enable;
|
||||
};
|
||||
};
|
||||
|
||||
/* SPI1 for SX1262 */
|
||||
spi1_default: spi1_default {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(SPIM_SCK, 0, 26)>,
|
||||
<NRF_PSEL(SPIM_MOSI, 0, 27)>,
|
||||
<NRF_PSEL(SPIM_MISO, 0, 28)>;
|
||||
};
|
||||
};
|
||||
|
||||
spi1_sleep: spi1_sleep {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(SPIM_SCK, 0, 26)>,
|
||||
<NRF_PSEL(SPIM_MOSI, 0, 27)>,
|
||||
<NRF_PSEL(SPIM_MISO, 0, 28)>;
|
||||
low-power-enable;
|
||||
};
|
||||
};
|
||||
};
|
||||
96
boards/heltec/heltec_meshpocket/heltec_meshpocket.dts
Normal file
96
boards/heltec/heltec_meshpocket/heltec_meshpocket.dts
Normal file
@@ -0,0 +1,96 @@
|
||||
/*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*
|
||||
* Heltec MeshPocket — Device Tree Source
|
||||
* SoC: nRF52840-QIAA
|
||||
* Radio: SX1262 (crystal oscillator, no TCXO)
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
#include <nordic/nrf52840_qiaa.dtsi>
|
||||
#include "heltec_meshpocket-pinctrl.dtsi"
|
||||
|
||||
/ {
|
||||
model = "Heltec MeshPocket";
|
||||
compatible = "heltec,meshpocket";
|
||||
|
||||
chosen {
|
||||
zephyr,sram = &sram0;
|
||||
zephyr,flash = &flash0;
|
||||
zephyr,console = &uart0;
|
||||
zephyr,shell-uart = &uart0;
|
||||
zephyr,code-partition = &slot0_partition;
|
||||
};
|
||||
|
||||
aliases {
|
||||
lora0 = &lora;
|
||||
};
|
||||
};
|
||||
|
||||
&uicr {
|
||||
gpio-as-nreset;
|
||||
};
|
||||
|
||||
&gpiote {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&gpio0 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&gpio1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&uart0 {
|
||||
compatible = "nordic,nrf-uarte";
|
||||
status = "okay";
|
||||
current-speed = <115200>;
|
||||
pinctrl-0 = <&uart0_default>;
|
||||
pinctrl-1 = <&uart0_sleep>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
};
|
||||
|
||||
&spi1 {
|
||||
compatible = "nordic,nrf-spim";
|
||||
status = "okay";
|
||||
pinctrl-0 = <&spi1_default>;
|
||||
pinctrl-names = "default";
|
||||
cs-gpios = <&gpio0 24 GPIO_ACTIVE_LOW>;
|
||||
|
||||
lora: lora@0 {
|
||||
compatible = "semtech,sx1262";
|
||||
reg = <0>;
|
||||
spi-max-frequency = <1000000>;
|
||||
reset-gpios = <&gpio0 21 GPIO_ACTIVE_LOW>;
|
||||
busy-gpios = <&gpio1 3 GPIO_ACTIVE_HIGH>;
|
||||
dio1-gpios = <&gpio1 4 GPIO_ACTIVE_HIGH>;
|
||||
dio2-tx-enable;
|
||||
};
|
||||
};
|
||||
|
||||
&flash0 {
|
||||
partitions {
|
||||
compatible = "fixed-partitions";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
|
||||
boot_partition: partition@0 {
|
||||
label = "mcuboot";
|
||||
reg = <0x00000000 0x0000C000>;
|
||||
};
|
||||
slot0_partition: partition@c000 {
|
||||
label = "image-0";
|
||||
reg = <0x0000C000 0x00067000>;
|
||||
};
|
||||
slot1_partition: partition@73000 {
|
||||
label = "image-1";
|
||||
reg = <0x00073000 0x00067000>;
|
||||
};
|
||||
storage_partition: partition@da000 {
|
||||
label = "storage";
|
||||
reg = <0x000da000 0x00006000>;
|
||||
};
|
||||
};
|
||||
};
|
||||
@@ -0,0 +1,7 @@
|
||||
CONFIG_SOC_SERIES_NRF52X=y
|
||||
CONFIG_BOARD_HELTEC_MESHPOCKET=y
|
||||
CONFIG_FLASH=y
|
||||
CONFIG_FLASH_MAP=y
|
||||
CONFIG_UART_CONSOLE=y
|
||||
CONFIG_SPI=y
|
||||
CONFIG_GPIO=y
|
||||
Reference in New Issue
Block a user