/*
 * Copyright (c) 2023 Nordic Semiconductor ASA
 *
 * SPDX-License-Identifier: Apache-2.0
 */

/dts-v1/;
#include <nordic/nrf9151ns_laca.dtsi>
#include "slm_nrf9151_common.dtsi"

/ {
	chosen {
		zephyr,flash = &flash0;
		zephyr,sram = &sram0_ns_app;
		zephyr,code-partition = &slot0_ns_partition;
		ncs,slm-uart = &uart2;
	};
};

/* Disable UART1, because it is used by default in TF-M */
&uart1 {
	status = "disabled";
};

&uart0 {
	status = "disabled";
};

&uart2 {
	compatible = "nordic,nrf-uarte";
	current-speed = <115200>;
	status = "okay";

	pinctrl-0 = <&uart2_default_alt>;
	pinctrl-1 = <&uart2_sleep_alt>;
	pinctrl-names = "default", "sleep";
};

&i2c2 {
	status = "disabled";
};

/* Disable SPI3 to prevent external flash issues */
&spi3 {
	status = "disabled";
};

&pinctrl {
	uart2_default_alt: uart2_default_alt {
		group1 {
			psels = <NRF_PSEL(UART_RX, 0, 5)>;
			bias-pull-up;
		};
		group2 {
			psels = <NRF_PSEL(UART_TX, 0, 4)>;
			
		};
	};

	uart2_sleep_alt: uart2_sleep_alt {
		group1 {
			psels = <NRF_PSEL(UART_TX, 0, 4)>,
				<NRF_PSEL(UART_RX, 0, 5)>;
			low-power-enable;
		};
	};
};
