1/* 2 * Copyright (c) 2022 Benjamin Björnsson <benjamin.bjornsson@gmail.com>. 3 * 4 * SPDX-License-Identifier: Apache-2.0 5 */ 6 7/dts-v1/; 8#include <nordic/nrf52832_qfaa.dtsi> 9#include "arduino_nicla_sense_me-pinctrl.dtsi" 10#include <zephyr/dt-bindings/input/input-event-codes.h> 11#include <zephyr/dt-bindings/led/led.h> 12 13/ { 14 model = "Arduino Nicla Sense ME"; 15 compatible = "arduino,arduino_nicla_sense_me"; 16 17 gpio_keys { 18 compatible = "gpio-keys"; 19 user_button: button { 20 label = "user button"; 21 gpios = <&gpio0 21 GPIO_ACTIVE_LOW>; 22 status = "okay"; 23 zephyr,code = <INPUT_KEY_0>; 24 }; 25 }; 26 27 chosen { 28 zephyr,console = &uart0; 29 zephyr,shell-uart = &uart0; 30 zephyr,uart-mcumgr = &uart0; 31 zephyr,bt-mon-uart = &uart0; 32 zephyr,bt-c2h-uart = &uart0; 33 zephyr,sram = &sram0; 34 zephyr,flash = &flash0; 35 zephyr,code-partition = &slot0_partition; 36 }; 37 38 aliases { 39 sw0 = &user_button; 40 watchdog0 = &wdt0; 41 }; 42}; 43 44&adc { 45 status = "okay"; 46}; 47 48&uicr { 49 gpio-as-nreset; 50}; 51 52&gpiote { 53 status = "okay"; 54}; 55 56&gpio0 { 57 status = "okay"; 58}; 59 60&uart0 { 61 compatible = "nordic,nrf-uarte"; 62 status = "okay"; 63 current-speed = <115200>; 64 pinctrl-0 = <&uart0_default>; 65 pinctrl-1 = <&uart0_sleep>; 66 pinctrl-names = "default", "sleep"; 67}; 68 69/* I2C0 in datasheet */ 70&i2c0 { 71 compatible = "nordic,nrf-twim"; 72 status = "okay"; 73 pinctrl-0 = <&i2c0_default>; 74 pinctrl-1 = <&i2c0_sleep>; 75 pinctrl-names = "default", "sleep"; 76 77 is31fl3194@53 { 78 compatible = "issi,is31fl3194"; 79 reg = <0x53>; 80 led_rgb { 81 label = "RGB LED"; 82 color-mapping = <LED_COLOR_ID_BLUE>, 83 <LED_COLOR_ID_GREEN>, 84 <LED_COLOR_ID_RED>; 85 current-limit = <10>; 86 }; 87 }; 88}; 89 90/* I2C1 in datasheet */ 91&i2c1 { 92 compatible = "nordic,nrf-twim"; 93 /* Cannot be used together with spi1. */ 94 status = "okay"; 95 pinctrl-0 = <&i2c1_default>; 96 pinctrl-1 = <&i2c1_sleep>; 97 pinctrl-names = "default", "sleep"; 98}; 99 100/* SPI1 in datasheet */ 101&spi1 { 102 compatible = "nordic,nrf-spim"; 103 /* Cannot be used together with i2c1. */ 104 /* status = "okay"; */ 105 pinctrl-0 = <&spi1_default>; 106 pinctrl-1 = <&spi1_sleep>; 107 pinctrl-names = "default", "sleep"; 108}; 109 110/* SPI0 in datasheet */ 111&spi2 { 112 compatible = "nordic,nrf-spi"; 113 status = "okay"; 114 pinctrl-0 = <&spi2_default>; 115 pinctrl-1 = <&spi2_sleep>; 116 pinctrl-names = "default", "sleep"; 117 cs-gpios = <&gpio0 26 GPIO_ACTIVE_LOW>; 118 119 mx25r1635f: mx25r1635f@0 { 120 compatible = "jedec,spi-nor"; 121 reg = <0>; 122 spi-max-frequency = <80000000>; 123 jedec-id = [c2 28 15]; 124 size = <DT_SIZE_M(16)>; 125 has-dpd; 126 t-enter-dpd = <10000>; 127 t-exit-dpd = <35000>; 128 129 partitions { 130 compatible = "fixed-partitions"; 131 #address-cells = <1>; 132 #size-cells = <1>; 133 134 logging_partition: partition@0 { 135 label = "logging"; 136 reg = <0x00000000 DT_SIZE_M(16)>; 137 }; 138 }; 139 }; 140}; 141 142&flash0 { 143 partitions { 144 compatible = "fixed-partitions"; 145 #address-cells = <1>; 146 #size-cells = <1>; 147 148 boot_partition: partition@0 { 149 label = "sam-ba"; 150 reg = <0x00000000 0x00010000>; 151 read-only; 152 }; 153 slot0_partition: partition@10000 { 154 label = "image-0"; 155 reg = <0x00010000 0x30000>; 156 }; 157 slot1_partition: partition@40000 { 158 label = "image-1"; 159 reg = <0x00040000 0x30000>; 160 }; 161 scratch_partition: partition@70000 { 162 label = "image-scratch"; 163 reg = <0x00070000 0xa000>; 164 }; 165 storage_partition: partition@7a000 { 166 label = "storage"; 167 reg = <0x0007a000 0x00006000>; 168 }; 169 }; 170}; 171