Embedded System Design 2 - Project
pin_mapping.h File Reference

The pin definitions for the regular and custom Happy Gecko board. More...

#include "em_device.h"
#include "em_gpio.h"

Go to the source code of this file.

Macros

#define CUSTOM_BOARD   1
 
#define ADXL_SPI   USART0
 
#define ADXL_SPI_LOC   0
 
#define ADXL_MOSI_PORT   gpioPortE
 
#define ADXL_MOSI_PIN   10
 
#define ADXL_MISO_PORT   gpioPortE
 
#define ADXL_MISO_PIN   11
 
#define ADXL_CLK_PORT   gpioPortE
 
#define ADXL_CLK_PIN   12
 
#define ADXL_NCS_PORT   gpioPortF /* Can't use the US0_CS port (PE13) to manually set/clear CS line */
 
#define ADXL_NCS_PIN   5
 
#define ADXL_INT1_PORT   gpioPortF
 
#define ADXL_INT1_PIN   3
 
#define ADXL_INT2_PORT   gpioPortF /* Unused */
 
#define ADXL_INT2_PIN   4 /* Unused */
 
#define ADXL_VDD_PORT   gpioPortA
 
#define ADXL_VDD_PIN   1
 
#define LED_PORT   gpioPortA
 
#define LED_PIN   2
 
#define PB0_PORT   gpioPortC
 
#define PB0_PIN   9
 
#define PB1_PORT   gpioPortC
 
#define PB1_PIN   10
 
#define DBG_UART   USART1
 
#define DBG_UART_LOC   4
 
#define DBG_TXD_PORT   gpioPortF
 
#define DBG_TXD_PIN   2
 
#define DBG_RXD_PORT   gpioPortA
 
#define DBG_RXD_PIN   0
 
#define TEMP_DATA_PORT   gpioPortC
 
#define TEMP_DATA_PIN   4
 
#define TEMP_VDD_PORT   gpioPortB
 
#define TEMP_VDD_PIN   11
 
#define BREAK1_PORT   gpioPortC
 
#define BREAK1_PIN   2
 
#define BREAK2_PORT   gpioPortC
 
#define BREAK2_PIN   3
 
#define RN2483_UART   LEUART0
 
#define RN2483_UART_LOC   0
 
#define RN2483_TX_PORT   gpioPortD
 
#define RN2483_TX_PIN   4
 
#define RN2483_RX_PORT   gpioPortD
 
#define RN2483_RX_PIN   5
 
#define RN2483_RESET_PORT   gpioPortA
 
#define RN2483_RESET_PIN   10
 
#define IIC_EXT   I2C0 /* Unused */
 
#define IIT_EXT_LOC   4 /* Unused */
 
#define IIC_SDA_PORT   gpioPortC /* Unused */
 
#define IIC_SDA_PIN   0 /* Unused */
 
#define IIC_SCL_PORT   gpioPortC /* Unused */
 
#define IIC_SCL_PIN   1 /* Unused */
 
#define PM_RN2483_PORT   gpioPortA
 
#define PM_RN2483_PIN   8
 
#define PM_SENS_EXT_PORT   gpioPortA
 
#define PM_SENS_EXT_PIN   9
 

Detailed Description

The pin definitions for the regular and custom Happy Gecko board.

Version
2.0
Author
Brecht Van Eeckhoudt

Versions

  • v1.0: Started with custom board pinout.
  • v1.1: Added regular board pinout, selectable with define statement.
  • v1.2: Added documentation.
  • v1.3: Updated code with new DEFINE checks.
  • v1.4: Added IIC definitions.
  • v2.0: Updated version number.

License

Copyright (C) 2019 - Brecht Van Eeckhoudt

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

A copy of the GNU General Public License can be found in the LICENSE file along with this source code.


Some methods use code obtained from examples from Silicon Labs' GitHub. These sections are licensed under the Silabs License Agreement. See the file "Silabs_License_Agreement.txt" for details. Before using this software for any purpose, you must agree to the terms of that agreement.

Definition in file pin_mapping.h.

Macro Definition Documentation

◆ ADXL_CLK_PIN

#define ADXL_CLK_PIN   12

Definition at line 73 of file pin_mapping.h.

◆ ADXL_CLK_PORT

#define ADXL_CLK_PORT   gpioPortE

Definition at line 72 of file pin_mapping.h.

◆ ADXL_INT1_PIN

#define ADXL_INT1_PIN   3

Definition at line 78 of file pin_mapping.h.

◆ ADXL_INT1_PORT

#define ADXL_INT1_PORT   gpioPortF

Definition at line 77 of file pin_mapping.h.

◆ ADXL_INT2_PIN

#define ADXL_INT2_PIN   4 /* Unused */

Definition at line 80 of file pin_mapping.h.

◆ ADXL_INT2_PORT

#define ADXL_INT2_PORT   gpioPortF /* Unused */

Definition at line 79 of file pin_mapping.h.

◆ ADXL_MISO_PIN

#define ADXL_MISO_PIN   11

Definition at line 71 of file pin_mapping.h.

◆ ADXL_MISO_PORT

#define ADXL_MISO_PORT   gpioPortE

Definition at line 70 of file pin_mapping.h.

◆ ADXL_MOSI_PIN

#define ADXL_MOSI_PIN   10

Definition at line 69 of file pin_mapping.h.

◆ ADXL_MOSI_PORT

#define ADXL_MOSI_PORT   gpioPortE

Definition at line 68 of file pin_mapping.h.

◆ ADXL_NCS_PIN

#define ADXL_NCS_PIN   5

Definition at line 75 of file pin_mapping.h.

◆ ADXL_NCS_PORT

#define ADXL_NCS_PORT   gpioPortF /* Can't use the US0_CS port (PE13) to manually set/clear CS line */

Definition at line 74 of file pin_mapping.h.

◆ ADXL_SPI

#define ADXL_SPI   USART0

Definition at line 66 of file pin_mapping.h.

◆ ADXL_SPI_LOC

#define ADXL_SPI_LOC   0

Definition at line 67 of file pin_mapping.h.

◆ ADXL_VDD_PIN

#define ADXL_VDD_PIN   1

Definition at line 82 of file pin_mapping.h.

◆ ADXL_VDD_PORT

#define ADXL_VDD_PORT   gpioPortA

Definition at line 81 of file pin_mapping.h.

◆ BREAK1_PIN

#define BREAK1_PIN   2

Definition at line 110 of file pin_mapping.h.

◆ BREAK1_PORT

#define BREAK1_PORT   gpioPortC

Definition at line 109 of file pin_mapping.h.

◆ BREAK2_PIN

#define BREAK2_PIN   3

Definition at line 112 of file pin_mapping.h.

◆ BREAK2_PORT

#define BREAK2_PORT   gpioPortC

Definition at line 111 of file pin_mapping.h.

◆ CUSTOM_BOARD

#define CUSTOM_BOARD   1

Public definition to select the Happy Gecko board version

  • 1 - Use the custom Happy Gecko board pinout.
  • 0 - Use the regular Happy Gecko board pinout.

Definition at line 60 of file pin_mapping.h.

◆ DBG_RXD_PIN

#define DBG_RXD_PIN   0

Definition at line 100 of file pin_mapping.h.

◆ DBG_RXD_PORT

#define DBG_RXD_PORT   gpioPortA

Definition at line 99 of file pin_mapping.h.

◆ DBG_TXD_PIN

#define DBG_TXD_PIN   2

Definition at line 98 of file pin_mapping.h.

◆ DBG_TXD_PORT

#define DBG_TXD_PORT   gpioPortF

Definition at line 97 of file pin_mapping.h.

◆ DBG_UART

#define DBG_UART   USART1

Definition at line 95 of file pin_mapping.h.

◆ DBG_UART_LOC

#define DBG_UART_LOC   4

Definition at line 96 of file pin_mapping.h.

◆ IIC_EXT

#define IIC_EXT   I2C0 /* Unused */

Definition at line 125 of file pin_mapping.h.

◆ IIC_SCL_PIN

#define IIC_SCL_PIN   1 /* Unused */

Definition at line 130 of file pin_mapping.h.

◆ IIC_SCL_PORT

#define IIC_SCL_PORT   gpioPortC /* Unused */

Definition at line 129 of file pin_mapping.h.

◆ IIC_SDA_PIN

#define IIC_SDA_PIN   0 /* Unused */

Definition at line 128 of file pin_mapping.h.

◆ IIC_SDA_PORT

#define IIC_SDA_PORT   gpioPortC /* Unused */

Definition at line 127 of file pin_mapping.h.

◆ IIT_EXT_LOC

#define IIT_EXT_LOC   4 /* Unused */

Definition at line 126 of file pin_mapping.h.

◆ LED_PIN

#define LED_PIN   2

Definition at line 86 of file pin_mapping.h.

◆ LED_PORT

#define LED_PORT   gpioPortA

Definition at line 85 of file pin_mapping.h.

◆ PB0_PIN

#define PB0_PIN   9

Definition at line 90 of file pin_mapping.h.

◆ PB0_PORT

#define PB0_PORT   gpioPortC

Definition at line 89 of file pin_mapping.h.

◆ PB1_PIN

#define PB1_PIN   10

Definition at line 92 of file pin_mapping.h.

◆ PB1_PORT

#define PB1_PORT   gpioPortC

Definition at line 91 of file pin_mapping.h.

◆ PM_RN2483_PIN

#define PM_RN2483_PIN   8

Definition at line 134 of file pin_mapping.h.

◆ PM_RN2483_PORT

#define PM_RN2483_PORT   gpioPortA

Definition at line 133 of file pin_mapping.h.

◆ PM_SENS_EXT_PIN

#define PM_SENS_EXT_PIN   9

Definition at line 136 of file pin_mapping.h.

◆ PM_SENS_EXT_PORT

#define PM_SENS_EXT_PORT   gpioPortA

Definition at line 135 of file pin_mapping.h.

◆ RN2483_RESET_PIN

#define RN2483_RESET_PIN   10

Definition at line 122 of file pin_mapping.h.

◆ RN2483_RESET_PORT

#define RN2483_RESET_PORT   gpioPortA

Definition at line 121 of file pin_mapping.h.

◆ RN2483_RX_PIN

#define RN2483_RX_PIN   5

Definition at line 120 of file pin_mapping.h.

◆ RN2483_RX_PORT

#define RN2483_RX_PORT   gpioPortD

Definition at line 119 of file pin_mapping.h.

◆ RN2483_TX_PIN

#define RN2483_TX_PIN   4

Definition at line 118 of file pin_mapping.h.

◆ RN2483_TX_PORT

#define RN2483_TX_PORT   gpioPortD

Definition at line 117 of file pin_mapping.h.

◆ RN2483_UART

#define RN2483_UART   LEUART0

Definition at line 115 of file pin_mapping.h.

◆ RN2483_UART_LOC

#define RN2483_UART_LOC   0

Definition at line 116 of file pin_mapping.h.

◆ TEMP_DATA_PIN

#define TEMP_DATA_PIN   4

Definition at line 104 of file pin_mapping.h.

◆ TEMP_DATA_PORT

#define TEMP_DATA_PORT   gpioPortC

Definition at line 103 of file pin_mapping.h.

◆ TEMP_VDD_PIN

#define TEMP_VDD_PIN   11

Definition at line 106 of file pin_mapping.h.

◆ TEMP_VDD_PORT

#define TEMP_VDD_PORT   gpioPortB

Definition at line 105 of file pin_mapping.h.