Release Notes for STM32CubeU5 HAL and LL drivers

Copyright ©  2021 STMicroelectronics

Purpose

The STM32Cube HAL and LL, an STM32 abstraction layer embedded software, ensure maximized portability across STM32 portfolio.

The portable APIs layer provides a generic, multi instanced and simple set of APIs to interact with the upper layer (application, libraries and stacks). It is composed of native and extended APIs set. It is directly built around a generic architecture and allows the build-upon layers, like the middleware layer, to implement its functions without knowing in-depth the used STM32 device. This improves the library code reusability and guarantees an easy portability on other devices and STM32 families.

The Low Layer (LL) drivers are part of the STM32Cube firmware HAL that provides a basic set of optimized and one-shot services. The Low layer drivers, contrary to the HAL ones are not fully portable across the STM32 families; the availability of some functions depends on the physical availability of the relative features on the product. The Low Layer (LL) drivers are designed to offer the following features:

Update History

Main Changes

  • HAL and LL drivers Maintenance Release for STM32U575xx / STM32U585xx devices and new support of STM32U595xx, STM32U5A5xx, STM32U599xx and STM32U5A9xx devices (Please Refer to the release notes for details)
  • Add New LTDC, GFXMMU, DSI, GPU2D HAL drivers highlighting the graphics aspect of STM32U595/STM32U5A5/STM32U599/STM32U5A9 devices
  • Add New HAL XSPI driver which supports OCTOSPI and Hexa-Deca SPI interface for both STM32U575/STM32U585 and STM32U595/STM32U5A5/STM32U599/STM32U5A9 devices
  • All the HAL/LL drivers are updated to support both STM32U575/STM32U585 and STM32U595/STM32U5A5/STM32U599/STM32U5A9 devices
  • General updates to fix known defects and implementation enhancements
  • The HAL and LL drivers provided within this package are MISRA-C, MCU ASTYLE and CodeSonar compliant, and have been reviewed with a static analysis tool to eliminate possible run-time errors

- HAL Drivers updates

  • All the HAL drivers are updated to support both STM32U575/STM32U585 and STM32U595/STM32U5A5/STM32U599/STM32U5A9 devices
  • HAL ADC driver
    • Add the following functions:
      • HAL_ADCEx_MultiModeStart_DMA_Data32()
      • HAL_ADCEx_MultiModeGetValue_Data32()
    • Update the DMA data length management implementation according to source/destination width
    • Enhance HAL_ADCEx_Calibration_GetValue() function implementation for proper ADC4 instance support
    • Enhance HAL_ADC_DeInit() and HAL_ADC_ConfigChannel() function implementation
  • HAL DCACHE driver
    • Add HAL_DCACHE_IsEnabled API to check whether the DCACHE is enabled or not
    • Enhance HAL_DCACHE_UnRegisterCallback() API
    • Enhance the timeout management
    • Enhance error code management by :
      • Resetting DCACHE handle error code any time a new operation is launched
      • Adding HAL_DCACHE_ERROR_INVALID_OPERATION error code: used in HAL_DCACHE_SetReadBurstType() API when DCACHE is enabled
      • Adding HAL_DCACHE_ERROR_EVICTION_CLEAN error code: used in HAL_DCACHE_IRQHandler() API when DCACHE error interrupt flag is set
    • Change the returned HAL status when there is an ongoing operation from HAL_ERROR to HAL_BUSY
    • Change DCACHE handle state to HAL_DCACHE_STATE_READY any time a new operation is launched
  • HAL DMA driver
    • Enhance LinkAllocatedPort implementation
  • HAL GPIO driver
    • Reorder EXTI configuration in HAL_GPIO_Init() API
  • HAL GTZC driver
    • Rename GTZC_PERIPH_DCMI define to GTZC_PERIPH_DCMI_PSSI
  • HAL driver
    • Add the following functions:
      • HAL_SYSCFG_SetOTGPHYReferenceClockSelection()
        • HAL_SYSCFG_SetOTGPHYPowerDownConfig()
        • HAL_SYSCFG_EnableOTGPHY()
      • HAL_SYSCFG_EnableVddCompensationCell()
        • HAL_SYSCFG_EnableVddIO2CompensationCell()
        • HAL_SYSCFG_EnableVddHSPICompensationCell()
        • HAL_SYSCFG_DisableVddCompensationCell()
        • HAL_SYSCFG_DisableVddIO2CompensationCell()
        • HAL_SYSCFG_DisableVddHSPICompensationCell()
  • HAL HCD driver
    • Fix handling of ODDFRM bit in OTG_HCCHARx for Isochronous IN transactions
  • HAL ICACHE driver
    • Add HAL_ICACHE_IsEnabled() API to check whether the ICACHE is enabled or not
  • HAL LPTIM driver
    • Add HAL_LPTIM_IC_GetOffset() function
    • Rename HAL_LPTIM_ReadCompare to HAL_LPTIM_ReadCapturedValue
    • Add parameters checks in HAL_LPTIM_xxx_Start_DMA functions
  • HAL MMC driver
    • Add the following functions:
      • HAL_MMC_SleepDevice()
      • HAL_MMC_AwakeDevice()
  • HAL PCD driver
    • Add the following functions:
      • HAL_PCD_EP_Abort()
      • HAL_PCD_SetTestMode()
    • Correct received transfer length with USB DMA activated
    • Add handling of USB OUT Endpoint disable interrupt
    • Fix device IN endpoint isoc incomplete transfer interrupt handling
    • Fix USB device Isoc OUT Endpoint incomplete transfer interrupt handling
    • Set DCD timeout to minimum value of 300ms before starting BCD primary detection process
  • HAL PWR driver
    • Add the following functions:
      • HAL_PWREx_EnableUSBHSTranceiverSupply()
      • HAL_PWREx_DisableUSBHSTranceiverSupply()
      • Rename PWR_SRAMx_PAGEx_MODE_RETENTION to PWR_SRAMx_PAGEx_MODE
  • HAL RCC driver
    • Enhance HAL_RCC_ClockConfig() function implementation
    • Update HAL_RCC_OscConfig() function implementation on PWR clocking control
    • Update HAL_RCC_OscConfig() function implementation to be tolerant to an identical PLL1 parameters re-configuration
    • Enhance of PLL1 outputs clearing time in HAL_RCC_OscConfig()
    • Remove RCC_PLL_SOURCE_NONE from correct parameters list on PLL1 configuration
    • Rename RCC_PERIPHCLK_CLK48 to RCC_PERIPHCLK_ICLK defines
    • Rename RCC_CLK48CLKSOURCE_XXX to RCC_ICLK_CLKSOURCE_XXX defines
    • Rename __HAL_RCC_ADC1_XXX_YYY to __HAL_RCC_ADC12_XXX_YYY macros
    • Rename __HAL_RCC_USB_OTG_FS_CLK_XXX to __HAL_RCC_USB_CLK_XXX macros
    • Rename Clk48ClockSelection to IclkClockSelection in RCC_PeriphCLKInitTypeDef
  • HAL SPI driver
    • Fix compilation warning with GNU compiler
  • HAL TIM driver
    • Add IS_TIM_PERIOD macro in HAL_TIM_xxx_Init functions
  • HAL UART driver
    • Rework HAL_UART_DMAPause() function in order to use DMA instead of UART to pause data transfer
    • Rework HAL_UART_DMAResume() function in order to use DMA instead of UART to resume data transfer
  • HAL USART driver
    • Rework HAL_USART_DMAPause() function in order to use DMA instead of USART to pause data transfer
    • Rework HAL_USART_DMAResume() function in order to use DMA instead of USART to resume data transfer

LL Drivers updates

  • All the LL drivers are updated to support both STM32U575/STM32U585 and STM32U595/STM32U5A5/STM32U599/STM32U5A9 devices
  • LL ADC driver
    • Add the following functions:
      • LL_ADC_SetVrefProtection()
      • LL_ADC_GetVrefProtection()
  • LL I2C driver
    • Add I2C instances 5 and 6 configuration within LL driver
  • LL LPTIM driver
    • Add LL_LPTIM_IC_GET_OFFSET macro
    • Rename the following static inline functions:
      • LL_LPTIM_SetCompareCH1 to LL_LPTIM_OC_SetCompareCH1
      • LL_LPTIM_SetCompareCH2 to LL_LPTIM_OC_SetCompareCH2
      • LL_LPTIM_GetCompareCH1 to LL_LPTIM_OC_GetCompareCH1
      • LL_LPTIM_GetCompareCH2 to LL_LPTIM_OC_GetCompareCH2
  • LL OPAMP driver
    • Add __LL_OPAMP_COMMON_INSTANCE macro
  • LL RCC driver
    • Add the following functions:
      • LL_RCC_SetUSBPHYClockSource()
      • LL_RCC_PLL3_EnableDomain_HSPI_LTDC()
      • LL_RCC_PLL3_DisableDomain_HSPI_LTDC()
      • LL_RCC_PLL3_ConfigDomain_HSPI_LTDC()
      • LL_RCC_PLL1_IsEnabledDomain_SAI()
      • LL_RCC_PLL1_IsEnabledDomain_48M()
      • LL_RCC_PLL1_IsEnabledDomain_SYS()
      • LL_RCC_PLL2_IsEnabledDomain_SAI()
      • LL_RCC_PLL2_IsEnabledDomain_48M()
      • LL_RCC_PLL2_IsEnabledDomain_ADC()
      • LL_RCC_PLL3_IsEnabledDomain_SAI()
      • LL_RCC_PLL3_IsEnabledDomain_48M()
      • LL_RCC_PLL3_IsEnabledDomain_HSPI_LTDC()
    • Enhance the following functions implementation:
      • LL_RCC_GetUSARTClockFreq(): Fix LPUART1 returned frequency when PCLK3 is set as clock source
      • LL_RCC_GetPPPClockFreq: Add check of PLL output enable bit status
    • Rename the macro __LL_RCC_CALC_PLL3CLK_HSPI_FREQ to __LL_RCC_CALC_PLL3CLK_HSPI_LTDC_FREQ
    • Rename the static API RCC_PLL3_GetFreqDomain_HSPI to RCC_PLL3_GetFreqDomain_HSPI_LTDC
    • Rename LL_RCC_USART6_CLKSOURCE_PCLK2 to LL_RCC_USART6_CLKSOURCE_PCLK1
  • LL RTC driver
    • Add LL_RTC_IsActiveFlag_ITAMP7() function
  • LL USART driver
    • Add USART instance 6 configuration within LL driver
  • LL USB driver
    • Add USB_EPStopXfer() function

Backward compatibility ensured by legacy defines

Known Limitations

  • N/A

Backward compatibility

  • N/A

Main Changes

  • Patch release V1.0.2 of HAL and LL drivers for STM32U575xx / STM32U585xx devices

LL Drivers updates

  • LL DAC driver
    • Rename of the LPTIM1/3 trigger of the LL DAC to be in line with Reference Manual:
      • Rename LL_DAC_TRIG_EXT_LPTIM1_OUT to LL_DAC_TRIG_EXT_LPTIM1_CH1
      • Rename LL_DAC_TRIG_EXT_LPTIM3_OUT to LL_DAC_TRIG_EXT_LPTIM3_CH1
  • Backward compatibility ensured by legacy defines

Known Limitations

  • N/A

Backward compatibility

  • N/A

Main Changes

  • Patch release V1.0.1 of HAL and LL drivers for STM32U575xx / STM32U585xx devices

HAL Drivers updates

  • HAL ADC driver
    • Update the DMA data length management implementation according source/destination width
    • Finetune HAL_ADCEx_Calibration_GetValue API to return correct calibration value for ADC4
  • HAL DAC driver
    • Rename of the LPTIM1/3 trigger of the DAC to be in line with Reference Manual:
      • Rename DAC_TRIGGER_STOP_LPTIM1_OUT to DAC_TRIGGER_STOP_LPTIM1_CH1
      • Rename DAC_TRIGGER_STOP_LPTIM3_OUT to DAC_TRIGGER_STOP_LPTIM3_CH1
      • Rename DAC_TRIGGER_LPTIM1_OUT to DAC_TRIGGER_LPTIM1_CH1
      • Rename DAC_TRIGGER_LPTIM3_OUT to DAC_TRIGGER_LPTIM3_CH1
  • HAL DMA driver
    • Fix DMA register callback error returning in case of invalid callback.
    • Enhance HAL_DMA_GetLockChannelAttributes API implementation to detect wrong parameters values
    • Enhance IS_DMA_ATTRIBUTES macro implementation to detect uncovered cases.
    • Optimize DMA_List_CheckNodesBaseAddresses API implementation by reducing parameters number
    • Optimize DMA_List_CheckNodesTypes API implementation by reducing parameters number
  • HAL GTZC driver
    • Fix issue with the APIs HAL_GTZC_MPCBB_ConfigMem : The CFGLOCK register should be updated after the update of SECCFGR and PRIVCFGR
  • HAL I2C driver
    • Add handle errors support in polling mode
  • HAL RCC driver
    • Fix setting Flash latency from MSIRange in Oscillator Configuration

LL Drivers updates

  • LL I2C driver
    • Add LL_I2C_EnableFastModePlus, LL_I2C_DisableFastModePlus and LL_I2C_IsEnabledFastModePlus APIs

Known Limitations

  • N/A

Backward compatibility

  • N/A

Main Changes

  • First official release of HAL and LL drivers for STM32U575xx / STM32U585xx devices

Known Limitations

  • N/A