Contrib: RCC controls for CRC Topic is solved

Report here problems in any of ChibiOS components. This forum is NOT for support.
User avatar
kimmoli
Posts: 27
Joined: Sat Oct 01, 2016 8:02 pm
Has thanked: 11 times
Been thanked: 9 times
Contact:

Contrib: RCC controls for CRC  Topic is solved

Postby kimmoli » Sun Nov 20, 2016 1:02 pm

Using Hardware CRC from Chibios-Contrib needs rcc control functions for CRC peripheral. These are missing from stm32_rcc.

< barthess> kimmoli: there is no place for RCC stuff in contrib. Create topic on forum with patch attached.


Propsed patch will add them:
https://github.com/kimmoli/ChibiOS/comm ... 7d6fcc0951

Code: Select all

diff --git a/os/hal/ports/STM32/STM32F4xx/stm32_rcc.h b/os/hal/ports/STM32/STM32F4xx/stm32_rcc.h
index 6f3e269..4de320c 100644
--- a/os/hal/ports/STM32/STM32F4xx/stm32_rcc.h
+++ b/os/hal/ports/STM32/STM32F4xx/stm32_rcc.h
@@ -1551,6 +1551,36 @@
 /** @} */

 /**
+ * @name    CRC peripheral specific RCC operations
+ * @{
+ */
+/**
+ * @brief   Enables the CRC peripheral clock.
+ *
+ * @param[in] lp        low power enable flag
+ *
+ * @api
+ */
+#define rccEnableCRC(lp) rccEnableAHB1(RCC_AHB1ENR_CRCEN, lp)
+
+/**
+ * @brief   Disables the CRC peripheral clock.
+ *
+ * @param[in] lp        low power enable flag
+ *
+ * @api
+ */
+#define rccDisableCRC(lp) rccDisableAHB1(RCC_AHB1ENR_CRCEN, lp)
+
+/**
+ * @brief   Resets the CRC peripheral.
+ *
+ * @api
+ */
+#define rccResetCRC() rccResetAHB1(RCC_AHB1RSTR_CRCRST)
+/** @} */
+
+/**
  * @name    FSMC peripherals specific RCC operations
  * @{
  */

User avatar
RoccoMarco
Posts: 655
Joined: Wed Apr 24, 2013 4:11 pm
Location: Munich (Germany)
Has thanked: 83 times
Been thanked: 67 times
Contact:

Re: Contrib: RCC controls for CRC

Postby RoccoMarco » Sun Nov 20, 2016 5:15 pm

Thanks, I will take a look.
Ciao,
RM

User avatar
RoccoMarco
Posts: 655
Joined: Wed Apr 24, 2013 4:11 pm
Location: Munich (Germany)
Has thanked: 83 times
Been thanked: 67 times
Contact:

Re: Contrib: RCC controls for CRC

Postby RoccoMarco » Wed Dec 21, 2016 10:10 pm

Bumped
Ciao,
RM

User avatar
kimmoli
Posts: 27
Joined: Sat Oct 01, 2016 8:02 pm
Has thanked: 11 times
Been thanked: 9 times
Contact:

Re: Contrib: RCC controls for CRC

Postby kimmoli » Mon Mar 20, 2017 1:54 pm

bump

User avatar
Giovanni
Site Admin
Posts: 14455
Joined: Wed May 27, 2009 8:48 am
Location: Salerno, Italy
Has thanked: 1076 times
Been thanked: 922 times
Contact:

Re: Contrib: RCC controls for CRC

Postby Giovanni » Mon Mar 20, 2017 3:28 pm

Don't worry, posts in this forum are always considered unless marked "done" :)

Giovanni

User avatar
Giovanni
Site Admin
Posts: 14455
Joined: Wed May 27, 2009 8:48 am
Location: Salerno, Italy
Has thanked: 1076 times
Been thanked: 922 times
Contact:

Re: Contrib: RCC controls for CRC

Postby Giovanni » Sun Apr 09, 2017 7:54 am

Is this change F4-specific?

Giovanni

User avatar
Giovanni
Site Admin
Posts: 14455
Joined: Wed May 27, 2009 8:48 am
Location: Salerno, Italy
Has thanked: 1076 times
Been thanked: 922 times
Contact:

Re: Contrib: RCC controls for CRC

Postby Giovanni » Tue Apr 25, 2017 9:17 am

Added to the F4 only for the time being.

Giovanni


Return to “Bug Reports”

Who is online

Users browsing this forum: No registered users and 8 guests