boards: arm: nrf52840_pca10056: add settings for WNC-M14A2A modem

These settings enable use of the WNC-M14A2A LTE-M modem as the default
network interface for the nRF52840-DK board (nrf52840_pca10056).

They include the following settings when MODEM_WNCM14A2A is selected:
- UARTE1 pin setup
- DTS / DTS fixup additions for WNC-M14A2A
- Kconfig settings for modem driver

Signed-off-by: Michael Scott <mike@foundries.io>
This commit is contained in:
Michael Scott 2018-08-01 12:06:00 -08:00 committed by Jukka Rissanen
commit 65af15bcc2
4 changed files with 55 additions and 0 deletions

View file

@ -57,4 +57,20 @@
#define CONFIG_WDT_NRF_IRQ NORDIC_NRF_WATCHDOG_40010000_IRQ_WDT
#define CONFIG_WDT_NRF_IRQ_PRI NORDIC_NRF_WATCHDOG_40010000_IRQ_WDT_PRIORITY
#define CONFIG_WNCM14A2A_UART_DRV_NAME NORDIC_NRF_UARTE_40028000_WNCM14A2A_BUS_NAME
#define CONFIG_WNCM14A2A_GPIO_MDM_BOOT_MODE_SEL_NAME NORDIC_NRF_UARTE_40028000_WNCM14A2A_MDM_BOOT_MODE_SEL_GPIOS_CONTROLLER
#define CONFIG_WNCM14A2A_GPIO_MDM_BOOT_MODE_SEL_PIN NORDIC_NRF_UARTE_40028000_WNCM14A2A_MDM_BOOT_MODE_SEL_GPIOS_PIN
#define CONFIG_WNCM14A2A_GPIO_MDM_POWER_NAME NORDIC_NRF_UARTE_40028000_WNCM14A2A_MDM_POWER_GPIOS_CONTROLLER
#define CONFIG_WNCM14A2A_GPIO_MDM_POWER_PIN NORDIC_NRF_UARTE_40028000_WNCM14A2A_MDM_POWER_GPIOS_PIN
#define CONFIG_WNCM14A2A_GPIO_MDM_KEEP_AWAKE_NAME NORDIC_NRF_UARTE_40028000_WNCM14A2A_MDM_KEEP_AWAKE_GPIOS_CONTROLLER
#define CONFIG_WNCM14A2A_GPIO_MDM_KEEP_AWAKE_PIN NORDIC_NRF_UARTE_40028000_WNCM14A2A_MDM_KEEP_AWAKE_GPIOS_PIN
#define CONFIG_WNCM14A2A_GPIO_MDM_RESET_NAME NORDIC_NRF_UARTE_40028000_WNCM14A2A_MDM_RESET_GPIOS_CONTROLLER
#define CONFIG_WNCM14A2A_GPIO_MDM_RESET_PIN NORDIC_NRF_UARTE_40028000_WNCM14A2A_MDM_RESET_GPIOS_PIN
#define CONFIG_WNCM14A2A_GPIO_MDM_SHLD_TRANS_ENA_NAME NORDIC_NRF_UARTE_40028000_WNCM14A2A_MDM_SHLD_TRANS_ENA_GPIOS_CONTROLLER
#define CONFIG_WNCM14A2A_GPIO_MDM_SHLD_TRANS_ENA_PIN NORDIC_NRF_UARTE_40028000_WNCM14A2A_MDM_SHLD_TRANS_ENA_GPIOS_PIN
#ifdef NORDIC_NRF_UARTE_40028000_WNCM14A2A_MDM_SEND_OK_GPIOS_PIN
#define CONFIG_WNCM14A2A_GPIO_MDM_SEND_OK_NAME NORDIC_NRF_UARTE_40028000_WNCM14A2A_MDM_SEND_OK_GPIOS_CONTROLLER
#define CONFIG_WNCM14A2A_GPIO_MDM_SEND_OK_PIN NORDIC_NRF_UARTE_40028000_WNCM14A2A_MDM_SEND_OK_GPIOS_PIN
#endif
/* End of SoC Level DTS fixup file */

View file

@ -30,6 +30,22 @@ config UART_0_NRF_RTS_PIN
config UART_0_NRF_CTS_PIN
default 7
if MODEM_WNCM14A2A
config UART_1_NRF_TX_PIN
default 46
config UART_1_NRF_RX_PIN
default 45
config UART_1_NRF_RTS_PIN
default 44
config UART_1_NRF_CTS_PIN
default 47
endif # MODEM_WCN14A2A
endif # UART_NRFX
if USB

View file

@ -40,6 +40,26 @@
status = "ok";
};
#ifdef CONFIG_UART_1_NRF_UARTE
&uart1 {
current-speed = <115200>;
status = "ok";
#ifdef CONFIG_MODEM_WNCM14A2A
wncm14a2a {
compatible = "wnc,m14a2a";
label = "wncm14a2a";
mdm-boot-mode-sel-gpios = <&gpio1 2 0>;
mdm-power-gpios = <&gpio1 3 0>;
mdm-keep-awake-gpios = <&gpio1 7 0>;
mdm-reset-gpios = <&gpio1 10 0>;
mdm-shld-trans-ena-gpios = <&gpio1 11 0>;
status = "ok";
};
#endif
};
#endif
&i2c0 {
status = "ok";
sda-pin = <26>;

View file

@ -45,6 +45,9 @@ config MODEM_WNCM14A2A
select MODEM_RECEIVER
select NET_OFFLOAD
select UART_MCUX_2 if BOARD_FRDM_K64F
select GPIO_NRF5_P1 if SOC_NRF52840
select UART_1_NRF_UARTE if SOC_NRF52840
select UART_1_NRF_FLOW_CONTROL if SOC_NRF52840
help
Choose this setting to enable Wistron WNC-M14A2A LTE-M modem driver.
NOTE: Currently the pin settings only work with FRDM K64F shield.