t
Fork of mbed-dev by
Diff: targets/hal/TARGET_Atmel/TARGET_SAM_CortexM0P/pinmap_function.c
- Revision:
- 18:da299f395b9e
- Parent:
- 15:a81a8d6c1dfe
- Child:
- 64:41a834223ea3
--- a/targets/hal/TARGET_Atmel/TARGET_SAM_CortexM0P/pinmap_function.c Thu Nov 05 09:00:10 2015 +0000 +++ b/targets/hal/TARGET_Atmel/TARGET_SAM_CortexM0P/pinmap_function.c Mon Nov 09 13:30:11 2015 +0000 @@ -182,12 +182,21 @@ uint32_t pinmap_peripheral_sercom(PinName pin, uint32_t sercom_index) { uint32_t sercom_address[6] = { +#if (SAMD21) || (SAMR21) 0x42000800UL, // Base address of SERCOM0 0x42000C00UL, // Base address of SERCOM1 0x42001000UL, // Base address of SERCOM2 0x42001400UL, // Base address of SERCOM3 0x42001800UL, // Base address of SERCOM4 0x42001C00UL // Base address of SERCOM5 +#elif (SAML21) + 0x42000000UL, // Base address of SERCOM0 + 0x42000400UL, // Base address of SERCOM1 + 0x42000800UL, // Base address of SERCOM2 + 0x42000C00UL, // Base address of SERCOM3 + 0x42001000UL, // Base address of SERCOM4 + 0x43000400UL // Base address of SERCOM5 +#endif }; uint32_t index = sercom_index & 0x0F;