1/* 2 * Copyright (c) 2020 InnBlue 3 * 4 * SPDX-License-Identifier: Apache-2.0 5 */ 6#include "innblue22_common-pinctrl.dtsi" 7#include <zephyr/dt-bindings/input/input-event-codes.h> 8 9/ { 10 model = "innblue v22 Dev Kit"; 11 compatible = "innblue,innblue22"; 12 13 chosen { 14 zephyr,console = &uart0; 15 zephyr,shell-uart = &uart0; 16 zephyr,uart-mcumgr = &uart0; 17 }; 18 19 leds { 20 compatible = "gpio-leds"; 21 red_led: led_1 { 22 gpios = <&gpio0 7 GPIO_ACTIVE_LOW>; 23 label = "RGB red channel"; 24 }; 25 green_led: led_2 { 26 gpios = <&gpio0 6 GPIO_ACTIVE_LOW>; 27 label = "RGB green channel"; 28 }; 29 blue_led: led_3 { 30 gpios = <&gpio0 5 GPIO_ACTIVE_LOW>; 31 label = "RGB blue channel"; 32 }; 33 34 mode_led: led_4 { 35 gpios = <&gpio0 4 GPIO_ACTIVE_LOW>; 36 label = "mode red channel"; 37 }; 38 }; 39 40 buttons { 41 compatible = "gpio-keys"; 42 43 button0: button_0 { 44 gpios = <&gpio0 31 (GPIO_PULL_UP | GPIO_ACTIVE_LOW)>; 45 label = "Button 0"; 46 zephyr,code = <INPUT_KEY_0>; 47 }; 48 }; 49 50 en_5v0_boost: enable-5v0-boost { 51 compatible = "regulator-fixed"; 52 regulator-name = "en_5v0_boost"; 53 enable-gpios = <&gpio0 21 GPIO_ACTIVE_HIGH>; 54 startup-delay-us = <10000>; 55 regulator-boot-on; 56 }; 57 58 /* These aliases are provided for compatibility with samples */ 59 aliases { 60 led0 = &red_led; 61 led1 = &green_led; 62 led2 = &blue_led; 63 led3 = &mode_led; 64 sw0 = &button0; 65 rgb-pwm = &pwm0; 66 mode-pwm = &pwm1; 67 watchdog0 = &wdt0; 68 accel0 = &lis2dh12_accel; 69 }; 70}; 71 72&gpiote { 73 status = "okay"; 74}; 75 76&gpio0 { 77 status = "okay"; 78}; 79 80&uart0 { 81 status = "okay"; 82 current-speed = <115200>; 83 84 pinctrl-0 = <&uart0_default>; 85 pinctrl-1 = <&uart0_sleep>; 86 pinctrl-names = "default", "sleep"; 87}; 88 89&uart1 { 90 status = "okay"; 91 current-speed = <115200>; 92 pinctrl-0 = <&uart1_default>; 93 pinctrl-1 = <&uart1_sleep>; 94 pinctrl-names = "default", "sleep"; 95}; 96 97&uart2 { 98 current-speed = <115200>; 99 pinctrl-0 = <&uart2_default>; 100 pinctrl-1 = <&uart2_sleep>; 101 pinctrl-names = "default", "sleep"; 102}; 103 104 105&i2c2 { 106 compatible = "nordic,nrf-twim"; 107 status = "okay"; 108 109 clock-frequency = <I2C_BITRATE_FAST>; 110 111 pinctrl-0 = <&i2c2_default>; 112 pinctrl-1 = <&i2c2_sleep>; 113 pinctrl-names = "default", "sleep"; 114 bq27421@55 { 115 compatible = "ti,bq274xx"; 116 reg = <0x55>; 117 design-voltage = <3700>; 118 design-capacity = <1800>; 119 taper-current = <45>; 120 terminate-voltage = <3000>; 121 }; 122 123 lis2dh12_accel: lis2dh12-accel@19 { 124 compatible = "st,lis2dh"; 125 reg = <0x19>; 126 irq-gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>, <&gpio0 1 GPIO_ACTIVE_HIGH>; 127 }; 128 129 hts221@5f { 130 compatible = "st,hts221"; 131 reg = <0x5f>; 132 drdy-gpios = <&gpio0 3 GPIO_ACTIVE_HIGH>; 133 }; 134 135 lps22hb-press@5c { 136 compatible = "st,lps22hb-press"; 137 reg = <0x5c>; 138 }; 139 140 ccs811: ccs811@5a { 141 compatible = "ams,ccs811"; 142 reg = <0x5a>; 143 }; 144 145 bme680@76 { 146 compatible = "bosch,bme680"; 147 reg = <0x76>; 148 }; 149}; 150 151&pwm0 { 152 status = "okay"; 153 pinctrl-0 = <&pwm0_default>; 154 pinctrl-1 = <&pwm0_sleep>; 155 pinctrl-names = "default", "sleep"; 156}; 157 158&pwm1 { 159 status = "okay"; 160 pinctrl-0 = <&pwm1_default>; 161 pinctrl-1 = <&pwm1_sleep>; 162 pinctrl-names = "default", "sleep"; 163}; 164 165&flash0 { 166 167 partitions { 168 compatible = "fixed-partitions"; 169 #address-cells = <1>; 170 #size-cells = <1>; 171 172 boot_partition: partition@0 { 173 label = "mcuboot"; 174 reg = <0x00000000 0x10000>; 175 }; 176 slot0_partition: partition@10000 { 177 label = "image-0"; 178 }; 179 slot0_ns_partition: partition@50000 { 180 label = "image-0-nonsecure"; 181 }; 182 slot1_partition: partition@80000 { 183 label = "image-1"; 184 }; 185 slot1_ns_partition: partition@c0000 { 186 label = "image-1-nonsecure"; 187 }; 188 /* 0xf0000 to 0xf7fff reserved for TF-M partitions */ 189 storage_partition: partition@f8000 { 190 label = "storage"; 191 reg = <0x000f8000 0x00008000>; 192 }; 193 }; 194}; 195 196/ { 197 /* SRAM allocated and used by the BSD library */ 198 sram0_bsd: memory@20010000 { 199 compatible = "mmio-sram"; 200 }; 201 202 /* SRAM allocated to the Non-Secure image */ 203 sram0_ns: memory@20020000 { 204 compatible = "mmio-sram"; 205 }; 206}; 207 208/* Include partition configuration file */ 209#include "innblue22_partition_conf.dtsi" 210