2018-10-17 14:58:14 +08:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2018 Christian Taedcke, Diego Sueiro
|
|
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
|
|
*/
|
|
|
|
|
|
|
|
/** @file
|
|
|
|
* @brief Silabs EFR32MG MCU pin definitions.
|
|
|
|
*
|
|
|
|
* This file contains pin configuration data required by different MCU
|
|
|
|
* modules to correctly configure GPIO controller.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef _SOC_PINMAP_H_
|
|
|
|
#define _SOC_PINMAP_H_
|
|
|
|
|
|
|
|
#include <em_gpio.h>
|
|
|
|
|
2018-12-27 15:12:05 +08:00
|
|
|
#ifdef CONFIG_GPIO_GECKO
|
|
|
|
/* Serial Wire Output (SWO) */
|
|
|
|
#if (DT_GPIO_GECKO_SWO_LOCATION == 0)
|
|
|
|
#define PIN_SWO {gpioPortF, 2, gpioModePushPull, 1}
|
|
|
|
#elif (DT_GPIO_GECKO_SWO_LOCATION == 1)
|
|
|
|
#define PIN_SWO {gpioPortB, 13, gpioModePushPull, 1}
|
|
|
|
#elif (DT_GPIO_GECKO_SWO_LOCATION == 2)
|
|
|
|
#define PIN_SWO {gpioPortD, 15, gpioModePushPull, 1}
|
|
|
|
#elif (DT_GPIO_GECKO_SWO_LOCATION == 3)
|
|
|
|
#define PIN_SWO {gpioPortC, 11, gpioModePushPull, 1}
|
|
|
|
#elif (DT_GPIO_GECKO_SWO_LOCATION >= 4)
|
|
|
|
#error ("Invalid SWO pin location")
|
|
|
|
#endif
|
|
|
|
#endif /* CONFIG_GPIO_GECKO */
|
|
|
|
|
2018-10-17 14:58:14 +08:00
|
|
|
#endif /* _SOC_PINMAP_H_ */
|