Page 1 of 1

STM32L073 missing RCC defines for CRC

Posted: Thu Jan 22, 2026 10:37 am
by TheoMarjan
Hello all !

developing on the STM32L073RZ (on the nucleo board), I've activated the CRC driver of ChibiOS-Contrib. This raised that the rcc macros for CRC are not available. Looking at the Reference Manual of the STM32L0x3, page 123 confirms the existence of a compatible CRC peripheral and page 205 the availability (and necessity) of the configuration bit for RCC.

All [font=Courier New]stm32l0xxxx.h[/font] files have the [font=Courier New]RCC_AHBENR_CRCEN[/font] defines already properly set, only the macros seem to be missing in [font=Courier New]os/hal/ports/STM32/STM32L0xx/stm32_rcc.h[/font]. I've added the necessary lines and the CRC driver now works properly. I think the change should be integrated into the offical codebase :

Code: Select all


/**
 * @name    CRC peripherals specific RCC operations
 * @{
 */
/**
 * @brief   Enables the CRC peripheral clock.
 *
 * @param[in] lp        low power enable flag
 *
 * @api
 */
#define rccEnableCRC(lp) rccEnableAHB(RCC_AHBENR_CRCEN, lp)

/**
 * @brief   Disables the CRC peripheral clock.
 *
 * @api
 */
#define rccDisableCRC() rccDisableAHB(RCC_AHBENR_CRCEN)

/**
 * @brief   Resets the CRC peripheral.
 *
 * @api
 */
#define rccResetCRC() rccResetAHB(RCC_AHBRSTR_CRCRST)
/** @} */



Request for Comments :)

Kind regards,

Theo

Re: STM32L073 missing RCC defines for CRC

Posted: Thu Jan 22, 2026 11:57 am
by Giovanni
Hi,

Moving this topic in "Bug Reports" for "processing" (will add the macros).

Giovanni

Re: STM32L073 missing RCC defines for CRC

Posted: Mon Jan 26, 2026 9:40 am
by Giovanni
Hi,

Macros added to trunk code.

Giovanni