msp430fxyz/include/periph_cpu.h File Reference

CPU specific definitions for internal peripheral handling. More...

Detailed Description

#include "cpu.h"
#include "msp430_regs.h"
+ Include dependency graph for msp430fxyz/include/periph_cpu.h:

Go to the source code of this file.

Macros

#define GPIO_UNDEF   (0xffff)
 Definition of a fitting UNDEF value.
 
#define HAVE_GPIO_T
 Define a custom type for GPIO pins.
 
typedef uint16_t gpio_t
 
#define GPIO_PIN(x, y)   ((gpio_t)(((x & 0xff) << 8) | (1 << (y & 0xff))))
 Mandatory function for defining a GPIO pins.
 
#define SPI_HWCS(x)   (SPI_CS_UNDEF)
 No support for HW chip select...
 
#define PERIPH_SPI_NEEDS_INIT_CS
 declare needed generic SPI functions
 
#define PERIPH_SPI_NEEDS_TRANSFER_BYTE
 
#define PERIPH_SPI_NEEDS_TRANSFER_REG
 
#define PERIPH_SPI_NEEDS_TRANSFER_REGS
 
enum  {
  P1 = 1, P2 = 2, P3 = 3, P4 = 4,
  P5 = 5, P6 = 6
}
 Available ports on MSP430 platforms. More...
 
void gpio_periph_mode (gpio_t pin, bool enable)
 Enable or disable a pin to be used by peripheral modules. More...
 

Enumeration Type Documentation

anonymous enum
Enumerator
P1 

PORT 1.

P2 

PORT 2.

P3 

PORT 3.

P4 

PORT 4.

P5 

PORT 5.

P6 

PORT 6.

Definition at line 104 of file msp430fxyz/include/periph_cpu.h.

Function Documentation

void gpio_periph_mode ( gpio_t  pin,
bool  enable 
)
Parameters
[in]pinpin to (de-)select
[in]enabletrue for enabling peripheral use, false for disabling it