Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of mbed-src by
Diff: targets/hal/TARGET_Atmel/TARGET_SAM21/objects.h
- Revision:
- 592:a274ee790e56
- Parent:
- 579:53297373a894
--- a/targets/hal/TARGET_Atmel/TARGET_SAM21/objects.h Wed Jul 15 08:15:08 2015 +0100 +++ b/targets/hal/TARGET_Atmel/TARGET_SAM21/objects.h Fri Jul 17 09:15:10 2015 +0100 @@ -20,21 +20,26 @@ #include "PortNames.h" #include "PeripheralNames.h" #include "gpio_object.h" +#include "adc.h" +#include "extint.h" #ifdef __cplusplus extern "C" { #endif struct gpio_irq_s { + uint8_t irqmask; uint32_t port; uint32_t pin; uint32_t ch; + struct extint_chan_conf config_extint_chan; }; struct port_s { __IO uint32_t *OUTCLR; __IO uint32_t *OUTSET; __I uint32_t *IN; + __I uint32_t *OUT; PortName port; uint32_t mask; @@ -48,16 +53,17 @@ uint32_t character_size; uint32_t mux_setting; uint32_t baudrate; - uint32_t pinmux_pad0; - uint32_t pinmux_pad1; - uint32_t pinmux_pad2; - uint32_t pinmux_pad3; - PinName rxpin; - PinName txpin; + PinName pins[4]; #if DEVICE_SERIAL_ASYNCH uint32_t events; #endif }; + +struct analogin_s { + ADCName adc; + struct adc_module adc_instance; + struct adc_config config_adc; +}; /* struct pwmout_s { __IO uint32_t *MR; @@ -69,10 +75,6 @@ int index; }; -struct analogin_s { - ADCName adc; -}; - struct dac_s { DACName dac; }; @@ -90,6 +92,7 @@ struct spi_s { Sercom *spi; uint8_t mode; + PinName pins[4]; #if DEVICE_SPI_ASYNCH uint8_t status; uint32_t mask;