diff options
author | Giovanni Di Sirio <gdisirio@gmail.com> | 2015-04-17 08:57:15 +0000 |
---|---|---|
committer | Giovanni Di Sirio <gdisirio@gmail.com> | 2015-04-17 08:57:15 +0000 |
commit | 9f76d34cdcbfc5dbdaed44eeb9e5808753e404a5 (patch) | |
tree | 5114ade2d7ccda66b663a931e7cc14edc5e53703 | |
parent | d48d8da22f12a51daa278d3d29bc4f4572e93943 (diff) | |
download | ChibiOS-9f76d34cdcbfc5dbdaed44eeb9e5808753e404a5.tar.gz ChibiOS-9f76d34cdcbfc5dbdaed44eeb9e5808753e404a5.tar.bz2 ChibiOS-9f76d34cdcbfc5dbdaed44eeb9e5808753e404a5.zip |
Fixed bug #582.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@7898 35acf78f-673a-0410-8e92-d51de3d6d3f4
-rw-r--r-- | os/hal/ports/STM32/STM32F1xx/stm32_rcc.h | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/os/hal/ports/STM32/STM32F1xx/stm32_rcc.h b/os/hal/ports/STM32/STM32F1xx/stm32_rcc.h index 8aea87e06..c381427a6 100644 --- a/os/hal/ports/STM32/STM32F1xx/stm32_rcc.h +++ b/os/hal/ports/STM32/STM32F1xx/stm32_rcc.h @@ -299,6 +299,31 @@ * @api
*/
#define rccResetCAN1() rccResetAPB1(RCC_APB1RSTR_CAN1RST)
+
+/**
+ * @brief Enables the CAN2 peripheral clock.
+ *
+ * @param[in] lp low power enable flag
+ *
+ * @api
+ */
+#define rccEnableCAN2(lp) rccEnableAPB1(RCC_APB1ENR_CAN2EN, lp)
+
+/**
+ * @brief Disables the CAN2 peripheral clock.
+ *
+ * @param[in] lp low power enable flag
+ *
+ * @api
+ */
+#define rccDisableCAN2(lp) rccDisableAPB1(RCC_APB1ENR_CAN2EN, lp)
+
+/**
+ * @brief Resets the CAN2 peripheral.
+ *
+ * @api
+ */
+#define rccResetCAN2() rccResetAPB1(RCC_APB1RSTR_CAN2RST)
/** @} */
/**
|