Release_Notes.html 115 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375
  1. <!DOCTYPE html>
  2. <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
  3. <head>
  4. <meta charset="utf-8" />
  5. <meta name="generator" content="pandoc" />
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
  7. <title>Release Notes for STM32F2xx HAL Drivers</title>
  8. <style type="text/css">
  9. code{white-space: pre-wrap;}
  10. span.smallcaps{font-variant: small-caps;}
  11. span.underline{text-decoration: underline;}
  12. div.column{display: inline-block; vertical-align: top; width: 50%;}
  13. </style>
  14. <link rel="stylesheet" href="_htmresc/mini-st.css" />
  15. <!--[if lt IE 9]>
  16. <script src="//cdnjs.cloudflare.com/ajax/libs/html5shiv/3.7.3/html5shiv-printshiv.min.js"></script>
  17. <![endif]-->
  18. </head>
  19. <body>
  20. <div class="row">
  21. <div class="col-sm-12 col-lg-4">
  22. <div class="card fluid">
  23. <div class="sectione dark">
  24. <center>
  25. <h1 id="release-notes-for-stm32f2xx-hal-drivers"><strong>Release Notes for STM32F2xx HAL Drivers</strong></h1>
  26. <p>Copyright © 2017 STMicroelectronics<br />
  27. </p>
  28. <a href="https://www.st.com" class="logo"><img src="_htmresc/st_logo.png" alt="ST logo" /></a>
  29. </center>
  30. </div>
  31. </div>
  32. <h1 id="license"><strong>License</strong></h1>
  33. This software component is licensed by ST under BSD 3-Clause license, the “License”; You may not use this component except in compliance with the License. You may obtain a copy of the License at:
  34. <center>
  35. <a href="https://opensource.org/licenses/BSD-3-Clause">https://opensource.org/licenses/BSD-3-Clause</a>
  36. </center>
  37. </div>
  38. <div class="col-sm-12 col-lg-8">
  39. <h1 id="update-history"><strong>Update History</strong></h1>
  40. <div class="collapse">
  41. <input type="checkbox" id="collapse-section1_2_7" aria-hidden="true"> <label for="collapse-section1_2_7" aria-hidden="true"><strong>V1.2.7 / 21-May-2021</strong></label>
  42. <div>
  43. <h2 id="main-changes">Main Changes</h2>
  44. <ul>
  45. <li>General updates to fix known defects.</li>
  46. </ul>
  47. <h2 id="contents">Contents</h2>
  48. <ul>
  49. <li><strong>HAL/LL ADC</strong> driver
  50. <ul>
  51. <li>Update timeout mechanism to avoid false timeout detection in case of preemption.</li>
  52. <li>Update HAL ADC driver to add include of the LL ADC driver.</li>
  53. <li>Update LL_ADC_DeInit() API to clear missing SQR3 register.</li>
  54. </ul></li>
  55. <li><strong>HAL CAN</strong> driver
  56. <ul>
  57. <li>Update HAL_CAN_Init() API to be aligned with reference manual and to avoid timeout error:
  58. <ul>
  59. <li>Update CAN Initialization sequence to set “request initialization” bit before exit from sleep mode.</li>
  60. </ul></li>
  61. </ul></li>
  62. <li><strong>HAL GPIO</strong> driver
  63. <ul>
  64. <li>Update HAL_GPIO_Init() API to avoid the configuration of PUPDR register when Analog mode is selected.</li>
  65. </ul></li>
  66. <li><strong>LL FMC</strong> driver
  67. <ul>
  68. <li>Fix compilation warning with gcc -Wpedantic compiler option.</li>
  69. </ul></li>
  70. <li><strong>HAL NAND</strong> driver
  71. <ul>
  72. <li>Update implementation of “HAL_NAND_Write_Page_16b” and “HAL_NAND_Read_Page_16b” APIs implementation to fix an issue with the page calculation of 8 bits memories.</li>
  73. <li>Update functions HAL_NAND_Read_SpareArea_16b() and HAL_NAND_Write_SpareArea_16b() to fix column address calculation issue.</li>
  74. </ul></li>
  75. <li><strong>HAL SDMMC</strong> driver
  76. <ul>
  77. <li>Update the definition of SDMMC_DATATIMEOUT constant in order to allow the user to redefine it in his proper application.</li>
  78. <li>SD_FindSCR() updated to resolve an issue with FIFO blocking when reading.</li>
  79. <li>Update the definition of SDMMC_DATATIMEOUT constant in order to allow the user to redefine it in his proper application.</li>
  80. <li>Add the block size settings in the initialization functions and remove it from read/write transactions to avoid repeated and inefficient reconfiguration.</li>
  81. <li>Update read/write functions in DMA mode in order to force the DMA direction.</li>
  82. <li>Deploy new functions MMC_ReadExtCSD() and SDMMC_CmdSendEXTCSD () that read and check the sectors number of the device in order to resolve the issue of wrongly reading big memory size.</li>
  83. </ul></li>
  84. <li><strong>HAL/LL SPI</strong> driver
  85. <ul>
  86. <li>Update to fix MISRA-C 2012 Rule-13.2.</li>
  87. <li>Update LL_SPI_TransmitData8() API to avoid casting the result to 8 bits.</li>
  88. </ul></li>
  89. <li><strong>HAL IRDA</strong> driver
  90. <ul>
  91. <li>Fixed typos in the IRDA State definition description.</li>
  92. </ul></li>
  93. <li><strong>HAL IWDG</strong> driver
  94. <ul>
  95. <li>Updated HAL_IWDG_Init() API in order to fix HAL_GetTick() timeout vulnerability issue.</li>
  96. <li>Add LSI startup time in default IWDG timeout calculation (HAL_IWDG_DEFAULT_TIMEOUT).</li>
  97. </ul></li>
  98. <li><strong>HAL/LL RTC</strong> driver
  99. <ul>
  100. <li>New APIs to subtract or add one hour to the calendar in one single operation without going through the initialization procedure (Daylight Saving):
  101. <ul>
  102. <li>Add HAL_RTC_DST_Add1Hour()</li>
  103. <li>HAL_RTC_DST_Sub1Hour()</li>
  104. <li>HAL_RTC_DST_SetStoreOperation()</li>
  105. <li>HAL_RTC_DST_ClearStoreOperation()</li>
  106. <li>HAL_RTC_DST_ReadStoreOperation()</li>
  107. </ul></li>
  108. <li>Update __HAL_RTC_…(__HANDLE__, …) macros to access registers through (__HANDLE__)-&gt;Instance pointer and avoid “unused variable” warnings.</li>
  109. <li>Correct month management in IS_LL_RTC_MONTH() macro.</li>
  110. </ul></li>
  111. <li><strong>HAL DMA</strong> driver
  112. <ul>
  113. <li>Update HAL_DMA_IRQHandler() API to set the DMA state before unlocking access to the DMA handle.</li>
  114. </ul></li>
  115. <li><strong>HAL EXTI</strong> driver
  116. <ul>
  117. <li>Update macros using LINE as a macro parameter in order to use EXTI_LINE instead to resolve parameter conflicts with standard C usage.</li>
  118. <li>Update HAL_EXTI_GetConfigLine() API to set default configuration value of Trigger and GPIOSel before checking each corresponding registers.</li>
  119. </ul></li>
  120. <li><strong>HAL SMARTCARD</strong> driver
  121. <ul>
  122. <li>Fixed typos in the SMARTCARD State definition description.</li>
  123. </ul></li>
  124. <li><strong>HAL/LL TIM</strong> driver
  125. <ul>
  126. <li>Made TIM_DMADelayPulseCplt callback as a private function.</li>
  127. <li>Update HAL_TIMEx_OnePulseN_Start and HAL_TIMEx_OnePulseN_Stop (pooling and IT mode) to take into consideration all OutputChannel parameters.</li>
  128. <li>Update input capture measurement in DMA mode to avoid zero return values at high frequencies.</li>
  129. <li>Updated LL_TIM_GetCounterMode() API to return the correct counter mode.</li>
  130. <li>Corrected reversed description of TIM_LL_EC_ONEPULSEMODE One Pulse Mode.</li>
  131. </ul></li>
  132. <li><strong>HAL I2C</strong> driver
  133. <ul>
  134. <li>Update to prevent several calls of Start bit:
  135. <ul>
  136. <li>Update I2C_MemoryTransmit_TXE_BTF() API to increment EventCount.</li>
  137. </ul></li>
  138. <li>Update to avoid I2C interrupt in endless loop:
  139. <ul>
  140. <li>Update HAL_I2C_Master_Transmit_IT(), HAL_I2C_Master_Receive_IT(), HAL_I2C_Master_Transmit_DMA() and HAL_I2C_Master_Receive_DMA() APIs to unlock the I2C peripheral before generating the start.</li>
  141. </ul></li>
  142. <li>Update to use the right macro to clear I2C ADDR flag inside I2C_Slave_ADDR() API as it’s indicated in the reference manual.</li>
  143. <li>Update HAL_I2C_EV_IRQHandler() and I2C_MasterTransmit_BTF() APIs to fix an issue where the transfer of the first few bytes to an I2C memory fails.</li>
  144. </ul></li>
  145. <li><strong>HAL RNG</strong> driver
  146. <ul>
  147. <li>Update timeout mechanism to avoid false timeout detection in case of preemption.</li>
  148. </ul></li>
  149. <li><strong>HAL UART</strong> driver
  150. <ul>
  151. <li>Enhance reception for idle services (ReceptionToIdle):
  152. <ul>
  153. <li>Add a new field (HAL_UART_RxTypeTypeDef) to the UART_HandleTypeDef structure to identify the type of ongoing reception.</li>
  154. <li>Add UART Reception Event Callback registration.</li>
  155. </ul></li>
  156. <li>Add reception specific APIs specific to reception for Idle transfer in different modes:
  157. <ul>
  158. <li>HAL_UARTEx_ReceiveToIdle(): Receive an amount of data in blocking mode until either the expected number of data is received or an IDLE event occurs.</li>
  159. <li>HAL_UARTEx_ReceiveToIdle_IT(): Receive an amount of data in interrupt mode until either the expected number of data is received or an IDLE event occurs.</li>
  160. <li>HAL_UARTEx_ReceiveToIdle_DMA(): Receive an amount of data in DMA mode until either the expected number of data is received or an IDLE event occurs.</li>
  161. </ul></li>
  162. <li>Update HAL_UART_Receive(), HAL_UART_Receive_IT() and HAL_UART_Receive_DMA() APIs to support the new enhancement of ReceptionToIdle.</li>
  163. <li>Fix wrong comment related to RX pin configuration within the description section.</li>
  164. <li>Correction on UART ReceptionType management in case of ReceptionToIdle API are called from RxEvent callback.</li>
  165. </ul></li>
  166. <li><strong>LL USART</strong> driver
  167. <ul>
  168. <li>Remove useless check on maximum BRR value by removing IS_LL_USART_BRR_MAX() macro.</li>
  169. </ul></li>
  170. </ul>
  171. </div>
  172. </div>
  173. <div class="collapse">
  174. <input type="checkbox" id="collapse-section13" aria-hidden="true"> <label for="collapse-section13" aria-hidden="true"><strong>V1.2.6 / 22-October-2020</strong></label>
  175. <div>
  176. <h2 id="main-changes-1">Main Changes</h2>
  177. <ul>
  178. <li>General updates to fix known defects.</li>
  179. </ul>
  180. <h2 id="contents-1">Contents</h2>
  181. <ul>
  182. <li><strong>HAL/LL I2C</strong> driver
  183. <ul>
  184. <li>Update to fix hardfault issue with HAL_I2C_Mem_Write_DMA() API:
  185. <ul>
  186. <li>Abort the right ongoing DMA transfer when memory write access request operation failed: fix typo “hdmarx” replaced by “hdmatx”</li>
  187. </ul></li>
  188. </ul></li>
  189. </ul>
  190. </div>
  191. </div>
  192. <div class="collapse">
  193. <input type="checkbox" id="collapse-section12" aria-hidden="true"> <label for="collapse-section12" aria-hidden="true"><strong>V1.2.5 / 09-September-2020</strong></label>
  194. <div>
  195. <h2 id="main-changes-2">Main Changes</h2>
  196. <ul>
  197. <li>General updates to fix known defects and enhancements implementation.</li>
  198. <li><strong>HAL</strong> driver
  199. <ul>
  200. <li>Enhance HAL_SetTickFreq() API robustness:
  201. <ul>
  202. <li>HAL_SetTickFreq(): update to restore the previous tick frequency when HAL_InitTick() configuration failed.</li>
  203. </ul></li>
  204. <li>Add new defines for ARM compiler V6:
  205. <ul>
  206. <li>__weak</li>
  207. <li>__packed</li>
  208. <li>__NOINLINE</li>
  209. </ul></li>
  210. <li>Update HAL_Init_Tick() API to proporely store the priority when using the non-default time base.</li>
  211. </ul></li>
  212. <li><strong>HAL/LL ADC</strong> driver
  213. <ul>
  214. <li>Update the type for the following ADC parameters in ADC_InitTypeDef structure to fix MISRA-C 2012 Rule-10.4 error
  215. <ul>
  216. <li><strong>uint32_t</strong> ContinuousConvMode to <strong>FunctionalState</strong> ContinuousConvMode</li>
  217. <li><strong>uint32_t</strong> DiscontinuousConvMode to <strong>FunctionalState</strong> DiscontinuousConvMode</li>
  218. <li><strong>uint32_t</strong> DMAContinuousRequests to <strong>FunctionalState</strong> DMAContinuousRequests</li>
  219. </ul></li>
  220. <li>Update the following APIs to set status HAL_ADC_STATE_ERROR_INTERNAL and error code HAL_ADC_ERROR_INTERNAL when error occurs:
  221. <ul>
  222. <li>HAL_ADC_Start()</li>
  223. <li>HAL_ADC_Start_IT()</li>
  224. <li>HAL_ADC_Start_DMA()</li>
  225. <li>HAL_ADCEx_InjectedStart()</li>
  226. <li>HAL_ADCEx_InjectedStart_IT()</li>
  227. <li>HAL_ADCEx_MultiModeStart_DMA()</li>
  228. </ul></li>
  229. <li>Update HAL_ADC_Stop_DMA() API to check if DMA state is Busy before calling HAL_DMA_Abort() API to avoid DMA internal error.</li>
  230. <li>Update LL_ADC_REG_Init() API to avoid enabling continuous mode and discontinuous mode simultaneously.</li>
  231. </ul></li>
  232. <li><strong>HAL/LL GPIO</strong> driver
  233. <ul>
  234. <li>Update HAL_GPIO_TogglePin() API to allow multi Pin’s toggling.</li>
  235. <li>Update LL_GPIO_TogglePin() API to improve robustness: use BSRR register instead of ODR register.</li>
  236. </ul></li>
  237. <li><strong>HAL/LL RCC</strong> driver
  238. <ul>
  239. <li>Add new HAL interfaces allowing to control the activation or deactivation of PLLI2S:
  240. <ul>
  241. <li>HAL_RCCEx_EnablePLLI2S()</li>
  242. <li>HAL_RCCEx_DisablePLLI2S()</li>
  243. </ul></li>
  244. <li>Add new HAL macros
  245. <ul>
  246. <li>__HAL_RCC_GET_RTC_SOURCE()allowing to get the RTC clock source</li>
  247. <li>__HAL_RCC_GET_RTC_HSE_PRESCALER()allowing to get the HSE clock divider for RTC peripheral.</li>
  248. </ul></li>
  249. <li>Update HAL_RCC_OscConfig() API to avoid overwriting a reserved bit
  250. <ul>
  251. <li>Update to use MODIFY_REG instead of WRITE_REG.</li>
  252. </ul></li>
  253. </ul></li>
  254. <li><strong>HAL/LL HASH</strong> driver
  255. <ul>
  256. <li>Fix Misra-C 2012 Rule-5.1 warning on identifiers to be distinct in the first 31 characters in renaming all <strong>HAL_HASH_xxx_Accumulate_yy()</strong> and <strong>HAL_HASHEx_xxx_Accumulate_yy()</strong> APIs respectively into <strong>HAL_HASH_xxx_Accmlt_yy()</strong> and <strong>HAL_HASHEx_xxx_Accmlt_yy()</strong></li>
  257. <li>Correct phase management issue when performing two successive hash operations on two different buffers</li>
  258. <li>Create new APIs to initialize the HASH peripheral then processes pInBuffer in interruption mode.
  259. <ul>
  260. <li>HASH_Accumulate_IT()</li>
  261. <li>HAL_HASH_SHA1_Accmlt_IT()</li>
  262. <li>HAL_HASH_MD5_Accmlt_IT()</li>
  263. </ul></li>
  264. <li>Create new APIs to wrap-up multi-buffer hashing processing in polling and interrupt modes
  265. <ul>
  266. <li>HAL_HASH_MD5_Accmlt_End()</li>
  267. <li>HAL_HASH_SHA1_Accmlt_End()</li>
  268. <li>HAL_HASH_MD5_Accmlt_End_IT()</li>
  269. <li>HAL_HASH_SHA1_Accmlt_End_IT()</li>
  270. </ul></li>
  271. <li>Ensure processing suspension flag is reset to HAL_HASH_SUSPEND_NONE value in HAL_HASH_Init() API</li>
  272. <li>Add comments to describe case of message made of several parts, not all with length multiple of 4 bytes.</li>
  273. <li>HASH_DMAXferCplt() callback API state improperly set to READY instead of BUSY fixed.</li>
  274. </ul></li>
  275. <li><strong>HAL NOR</strong> driver
  276. <ul>
  277. <li>Correct MISRA-C 2012-Rule-10.4_a / 14.4_d / 18.4 warnings in HAL NOR drivers</li>
  278. <li>Update address calculation in HAL_NOR_ProgramBuffer()</li>
  279. <li>Add new commands operations:
  280. <ul>
  281. <li>NOR_CMD_READ_ARRAY</li>
  282. <li>NOR_CMD_WORD_PROGRAM<br />
  283. </li>
  284. <li>NOR_CMD_BUFFERED_PROGRAM</li>
  285. <li>NOR_CMD_CONFIRM<br />
  286. </li>
  287. <li>NOR_CMD_BLOCK_ERASE<br />
  288. </li>
  289. <li>NOR_CMD_BLOCK_UNLOCK<br />
  290. </li>
  291. <li>NOR_CMD_READ_STATUS_REG</li>
  292. <li>NOR_CMD_CLEAR_STATUS_REG</li>
  293. </ul></li>
  294. <li>Apply adequate commands according to the command set field value
  295. <ul>
  296. <li>command set 1 for Micron JS28F512P33</li>
  297. <li>command set 2 for Micron M29W128G and Cypress S29GL128P</li>
  298. </ul></li>
  299. <li>Update some APIs in order to be compliant for memories with another command set.
  300. <ul>
  301. <li>HAL_NOR_Init()</li>
  302. <li>HAL_NOR_Read_ID()</li>
  303. <li>HAL_NOR_ReturnToReadMode()</li>
  304. <li>HAL_NOR_Read()</li>
  305. <li>HAL_NOR_Program()</li>
  306. <li>HAL_NOR_ReadBuffer()</li>
  307. <li>HAL_NOR_ProgramBuffer()</li>
  308. <li>HAL_NOR_Erase_Block()</li>
  309. <li>HAL_NOR_Erase_Chip()</li>
  310. <li>HAL_NOR_GetStatus()</li>
  311. </ul></li>
  312. </ul></li>
  313. <li><strong>HAL SRAM</strong> driver
  314. <ul>
  315. <li>General update to enhance HAL SRAM driver robustness
  316. <ul>
  317. <li>Update HAL_SRAM_Init() API to avoid activation of burst access for SRAM</li>
  318. </ul></li>
  319. </ul></li>
  320. <li><strong>LL FSMC</strong> driver
  321. <ul>
  322. <li>Remove useless casts.</li>
  323. <li>Update FSMC_NORSRAM_Init() API in order to resolve compilation issue with Microsoft Visual Studio 2017.</li>
  324. <li>Update FSMC_NORSRAM_Extended_Timing_Init() API in order to manage Bus turnaround phase duration FSMC_BWTR1_BUSTURN availability.</li>
  325. </ul></li>
  326. <li><strong>HAL/LL IWDG</strong> driver
  327. <ul>
  328. <li>Update HAL_IWDG_DEFAULT_TIMEOUT define value to consider LSI value instead of hardcoded value</li>
  329. </ul></li>
  330. <li><strong>HAL/LL I2C</strong> update
  331. <ul>
  332. <li>Update I2C_MasterReceiveRXNE() static API to avoid set the STOP bit again after the bit clearing by Hardware during the masking operation
  333. <ul>
  334. <li>Add new API I2C_WaitOnSTOPRequestThroughIT() to wait for stop bit.</li>
  335. </ul></li>
  336. <li>Update sequential APIs to avoid requesting a START when a STOP condition is not fully treated
  337. <ul>
  338. <li>Wait the end of STOP treatment by polling (with a timeout) the STOP bit on Control register CR1</li>
  339. </ul></li>
  340. <li>Update HAL_I2C_ER_IRQHandler() API to fix acknowledge failure issue with I2C memory IT processes
  341. <ul>
  342. <li>Add stop condition generation when NACK occurs.</li>
  343. </ul></li>
  344. </ul></li>
  345. <li><strong>HAL/LL I2S</strong> driver
  346. <ul>
  347. <li>Update HAL_I2S_DMAStop() API to be more safe
  348. <ul>
  349. <li>Add a check on BSY, TXE and RXNE flags before disabling the I2S</li>
  350. </ul></li>
  351. <li>Update HAL_I2S_DMAStop() API to fix multi-call transfer issue(to avoid re-initializing the I2S for the next transfer).
  352. <ul>
  353. <li>Add __HAL_I2SEXT_FLUSH_RX_DR() and __HAL_I2S_FLUSH_RX_DR() macros to flush the remaining data inside DR registers.</li>
  354. <li>Add new ErrorCode define: HAL_I2S_ERROR_BUSY_LINE_RX</li>
  355. </ul></li>
  356. </ul></li>
  357. <li><strong>HAL/LL SPI</strong> driver
  358. <ul>
  359. <li>Update SPI_DMAReceiveCplt() API to handle efficiently the repeated transfers.
  360. <ul>
  361. <li>Disable TX DMA request only in bidirectional receive mode</li>
  362. </ul></li>
  363. <li>Update HAL_SPI_Init() API
  364. <ul>
  365. <li>To avoid setting the BaudRatePrescaler in case of Slave Motorola Mode</li>
  366. <li>Use the bit-mask for SPI configuration</li>
  367. </ul></li>
  368. <li>Update Transmit/Receive processes in half-duplex mode
  369. <ul>
  370. <li>Disable the SPI instance before setting BDIOE bit</li>
  371. </ul></li>
  372. <li>Fix wrong timeout management
  373. <ul>
  374. <li>Calculate Timeout based on a software loop to avoid blocking issue if Systick is disabled</li>
  375. </ul></li>
  376. </ul></li>
  377. <li><strong>HAL/LL UART</strong> driver
  378. <ul>
  379. <li>Update UART BRR calculation for ROM size gain</li>
  380. <li>Update UART polling and interruption processes to fix issues related to accesses out of user specified buffer.
  381. <ul>
  382. <li>Update UART_Transmit_IT(), UART_Receive_IT(), HAL_UART_Transmit() and HAL_UART_Receive() APIs.</li>
  383. </ul></li>
  384. </ul></li>
  385. <li><strong>HAL SMARTCARD</strong> driver
  386. <ul>
  387. <li>Update SMARTCARD transmission and reception APIs to handle memory corruption
  388. <ul>
  389. <li>HAL_SMARTCARD_Transmit(), HAL_SMARTCARD_Receive(), HAL_SMARTCARD_Transmit_IT() and HAL_SMARTCARD_Receive_IT()</li>
  390. </ul></li>
  391. </ul></li>
  392. <li><strong>HAL/LL TIM</strong> driver
  393. <ul>
  394. <li>Align HAL/LL TIM driver with latest updates and enhancements</li>
  395. <li>Update Encoder interface mode to keep TIM_CCER_CCxNP bits low
  396. <ul>
  397. <li>Add TIM_ENCODERINPUTPOLARITY_RISING and TIM_ENCODERINPUTPOLARITY_FALLING definitions to determine encoder input polarity.</li>
  398. <li>Add IS_TIM_ENCODERINPUT_POLARITY() macro to check the encoder input polarity.</li>
  399. <li>Update HAL_TIM_Encoder_Init() API</li>
  400. <li>Replace IS_TIM_IC_POLARITY() macro by IS_TIM_ENCODERINPUT_POLARITY() macro.</li>
  401. </ul></li>
  402. <li>Fix bug when using multiple DMA request to different channels of same timer
  403. <ul>
  404. <li>Introduce DMA burst state management mechanism
  405. <ul>
  406. <li>Add a new structure for DMA Burst States definition : HAL_TIM_DMABurstStateTypeDef</li>
  407. <li>Update __HAL_TIM_RESET_HANDLE_STATE to support DMABurstState</li>
  408. <li>Add a new API HAL_TIM_DMABurstState() to get the actual state of a DMA burst operation</li>
  409. <li>Add DMABurstState, the DMA burst operation state, in the TIM_HandleTypeDef structure</li>
  410. <li>Add new API TIM_DMAErrorCCxN() for TIM DMA error callback (complementary channel)</li>
  411. <li>Add new API TIM_DMADelayPulseNCplt() for TIM DMA Delay Pulse complete callback (complementary channel)</li>
  412. </ul></li>
  413. </ul></li>
  414. <li>Implement TIM channel state management mechanism
  415. <ul>
  416. <li>Add new macro
  417. <ul>
  418. <li>TIM_CHANNEL_STATE_SET_ALL and TIM_CHANNEL_N_STATE_SET_ALL</li>
  419. <li>TIM_CHANNEL_STATE_SET and TIM_CHANNEL_N_STATE_SET</li>
  420. <li>TIM_CHANNEL_STATE_GET and TIM_CHANNEL_N_STATE_GET</li>
  421. </ul></li>
  422. </ul></li>
  423. <li>Add new API HAL_TIM_GetActiveChannel()</li>
  424. <li>Add new API HAL_TIM_GetChannelState() to get actual state of the TIM channel</li>
  425. <li>Add a new structure for TIM channel States definition : HAL_TIM_ChannelStateTypeDef</li>
  426. <li>Update __HAL_TIM_RESET_HANDLE_STATE to support ChannelState and ChannelNState</li>
  427. <li>Add a new element in the TIM_HandleTypeDef structure : ChannelState to manage TIM channel operation state</li>
  428. <li>Add a new element in the TIM_HandleTypeDef structure : ChannelNState to manage TIM complementary channel operation state</li>
  429. <li>Update HAL_TIMEx_MasterConfigSynchronization() API to avoid functional errors and assert fails when using some TIM instances as input trigger.
  430. <ul>
  431. <li>Replace IS_TIM_SYNCHRO_INSTANCE() macro by IS_TIM_MASTER_INSTANCE() macro.</li>
  432. <li>Add IS_TIM_SLAVE_INSTANCE() macro to check on TIM_SMCR_MSM bit.</li>
  433. </ul></li>
  434. <li>Remove ‘register’ storage class specifier from LL TIM driver.</li>
  435. <li>Add new API HAL_TIM_DMABurst_MultiWriteStart() allowing to configure the DMA Burst to transfer multiple Data from the memory to the TIM peripheral</li>
  436. <li>Add new API HAL_TIM_DMABurst_MultiReadStart() allowing to configure the DMA Burst to transfer Data from the TIM peripheral to the memory</li>
  437. </ul></li>
  438. <li><strong>HAL/LL USB</strong> driver
  439. <ul>
  440. <li>Bug fix: USB_ReadPMA() and USB_WritePMA() by ensuring 16-bits access to USB PMA memory</li>
  441. <li>Bug fix: correct USB RX count calculation</li>
  442. <li>Fix USB Bulk transfer double buffer mode</li>
  443. <li>Remove register keyword from USB defined macros as no more supported by C++ compiler</li>
  444. <li>Minor rework on USBD_Start() and USBD_Stop() APIs: stopping device will be handled by HAL_PCD_DeInit() API.</li>
  445. <li>Remove non used API for USB device mode.</li>
  446. </ul></li>
  447. <li><strong>LL UTILS</strong> driver
  448. <ul>
  449. <li>UTILS_SetFlashLatency() API renamed to LL_SetFlashLatency() and set exportable.</li>
  450. </ul></li>
  451. </ul>
  452. </div>
  453. </div>
  454. <div class="collapse">
  455. <input type="checkbox" id="collapse-section11" aria-hidden="true"> <label for="collapse-section11" aria-hidden="true"><strong>V1.2.4 / 31-December-2019</strong></label>
  456. <div>
  457. <h2 id="main-changes-3">Main Changes</h2>
  458. <ul>
  459. <li>General updates to fix known defects and enhancements implementation</li>
  460. <li><strong>HAL/LL GPIO</strong> update
  461. <ul>
  462. <li>Update GPIO initialization sequence to avoid unwanted pulse on GPIO Pin’s</li>
  463. </ul></li>
  464. <li><strong>HAL I2C</strong> update
  465. <ul>
  466. <li>Update HAL_I2C_EV_IRQHandler() API to fix I2C send break issue
  467. <ul>
  468. <li>Add additional check on hi2c-&gt;hdmatx, hdmatx-&gt;XferCpltCallback, hi2c-&gt;hdmarx, hdmarx-&gt;XferCpltCallback in I2C_Master_SB() API to avoid enabling DMA request when IT mode is used.</li>
  469. </ul></li>
  470. <li>Update HAL_I2C_ER_IRQHandler() API to fix acknowledge failure issue with I2C memory IT processes
  471. <ul>
  472. <li>Add stop condition generation when NACK occurs.</li>
  473. </ul></li>
  474. <li>Update HAL_I2C_Init() API to force software reset before setting new I2C configuration.</li>
  475. <li>Update HAL I2C processes to report ErrorCode when wrong I2C start condition occurs
  476. <ul>
  477. <li>Add new ErrorCode define: HAL_I2C_WRONG_START</li>
  478. <li>Set ErrorCode parameter in I2C handle to HAL_I2C_WRONG_START</li>
  479. </ul></li>
  480. <li>Update I2C_DMAXferCplt(), I2C_DMAError() and I2C_DMAAbort() APIs to fix hardfault issue when hdmatx and hdmarx parameters in i2c handle aren’t initialized (NULL pointer).
  481. <ul>
  482. <li>Add additional check on hi2c-&gt;hdmtx and hi2c-&gt;hdmarx before resetting DMA Tx/Rx complete callbacks.</li>
  483. </ul></li>
  484. </ul></li>
  485. <li><strong>HAL IRDA</strong> update
  486. <ul>
  487. <li>Update IRDA interruption handler to manage correctly the overrun interrupt
  488. <ul>
  489. <li>Add in the HAL_IRDA_IRQHandler() API a check on USART_CR1_RXNEIE bit when an overrun interrupt occurs.</li>
  490. </ul></li>
  491. </ul></li>
  492. <li><strong>HAL SMARTCARD</strong> update
  493. <ul>
  494. <li>Update SMARTCARD interruption handler to manage correctly the overrun interrupt.
  495. <ul>
  496. <li>Add in the HAL_SMARTCARD_IRQHandler() API a check on USART_CR1_RXNEIE bit when an overrun interrupt occurs.</li>
  497. </ul></li>
  498. </ul></li>
  499. <li><strong>HAL UART</strong> update
  500. <ul>
  501. <li>Update UART polling processes to handle efficiently the Lock mechanism
  502. <ul>
  503. <li>Move the process unlock at the top of the HAL_UART_Receive() and HAL_UART_Transmit() API.</li>
  504. </ul></li>
  505. <li>Update UART interruption handler to manage correctly the overrun interrupt
  506. <ul>
  507. <li>Add in the HAL_UART_IRQHandler() API a check on USART_CR1_RXNEIE bit when an overrun interrupt occurs.</li>
  508. </ul></li>
  509. </ul></li>
  510. <li><strong>HAL USART</strong> update
  511. <ul>
  512. <li>Update USART interruption handler to manage correctly the overrun interrupt
  513. <ul>
  514. <li>Add in the HAL_USART_IRQHandler() API a check on USART_CR1_RXNEIE bit when an overrun interrupt occurs.</li>
  515. </ul></li>
  516. </ul></li>
  517. </ul>
  518. </div>
  519. </div>
  520. <div class="collapse">
  521. <input type="checkbox" id="collapse-section10" aria-hidden="true"> <label for="collapse-section10" aria-hidden="true"><strong>V1.2.3 / 26-June-2019</strong></label>
  522. <div>
  523. <h2 id="main-changes-4">Main Changes</h2>
  524. <ul>
  525. <li>General updates to fix known defects and enhancements implementation</li>
  526. <li>HAL drivers clean up: remove double casting ‘uint32_t’ and ‘U’</li>
  527. <li>General updates to fix CodeSonar compilation warnings</li>
  528. <li>General updates to fix the user manual .chm files</li>
  529. <li>Add support of HAL callback registration feature</li>
  530. <li>Add new <strong>HAL EXTI</strong> driver</li>
  531. <li><strong>The following changes done on the HAL drivers require an update on the application code based on older HAL versions</strong>
  532. <ul>
  533. <li><strong>HAL/LL Generic</strong> update
  534. <ul>
  535. <li>Add support of <strong>HAL callback registration</strong> feature
  536. <ul>
  537. <li>The feature disabled by default is available for the following HAL drivers:
  538. <ul>
  539. <li><strong>ADC, CAN, CRYP, DAC, DCMI, ETH, HASH, HCD, I2C, UART, USART, IRDA, SMARTCARD,</strong></li>
  540. <li><strong>MMC, NAND, NOR, PCCARD, PCD, RNG, RTC, SD, SRAM, SPI, I2S, TIM and WWDG</strong></li>
  541. </ul></li>
  542. <li>The feature may be enabled individually per HAL PPP driver by setting the corresponding definition USE_HAL_PPP_REGISTER_CALLBACKS to 1U in stm32f2xx_hal_conf.h project configuration file (template file stm32f2xx_hal_conf_template.h available from Drivers/STM32F2xx_HAL_Driver/Inc)</li>
  543. <li>Once enabled , the user application may resort to HAL_PPP_RegisterCallback() to register specific callback function(s) and unregister it(them) with HAL_PPP_UnRegisterCallback()</li>
  544. </ul></li>
  545. </ul></li>
  546. <li><strong>Rework of HAL CRYP driver (compatibility break)</strong>
  547. <ul>
  548. <li>HAL CRYP driver has been redesigned with new API’s, to bypass limitations on data Encryption/Decryption management present with previous HAL CRYP driver version.</li>
  549. <li>The new HAL CRYP driver is the recommended version. It is located as usual in Drivers/STM32F2xx_HAL_Driver/Src and Drivers/STM32f2xx_HAL_Driver/Inc folders. It can be enabled through switch HAL_CRYP_MODULE_ENABLED in stm32f2xx_hal_conf.h</li>
  550. <li>The legacy HAL CRYP driver is no longer supported.</li>
  551. </ul></li>
  552. <li><strong>Rework of HAL CAN driver (compatibility break)</strong>
  553. <ul>
  554. <li>A new HAL CAN driver has been redesigned with new APIs, to bypass limitations on CAN Tx/Rx FIFO management present with previous HAL CAN driver version.</li>
  555. <li>The new HAL CAN driver is the recommended version. It is located as usual in Drivers/STM32F2xx_HAL_Driver/Src and Drivers/STM32f2xx_HAL_Driver/Inc folders. It can be enabled through switch HAL_CAN_MODULE_ENABLED in stm32f2xx_hal_conf.h</li>
  556. <li>The legacy HAL CAN driver is also present in the release in Drivers/STM32F2xx_HAL_Driver/Src/Legacy and Drivers/STM32F2xx_HAL_Driver/Inc/Legacy folders for software compatibility reasons. Its usage is not recommended as deprecated. It can however be enabled through switch HAL_CAN_LEGACY_MODULE_ENABLED in stm32f2xx_hal_conf.h</li>
  557. </ul></li>
  558. </ul></li>
  559. <li><strong>HAL/LL Generic</strong> update
  560. <ul>
  561. <li>Update HAL driver to allow user to change systick period to 1ms, 10 ms or 100 ms :
  562. <ul>
  563. <li>Add the following API’s :
  564. <ul>
  565. <li>HAL_GetTickPrio(): Returns a tick priority.</li>
  566. <li>HAL_SetTickFreq(): Sets new tick frequency.</li>
  567. <li>HAL_GetTickFreq(): Returns tick frequency.</li>
  568. </ul></li>
  569. <li>Add HAL_TickFreqTypeDef enumeration for the different Tick Frequencies: 10 Hz, 100 Hz and 1KHz (default).</li>
  570. </ul></li>
  571. <li>Add UNUSED() macro implementation to avoid GCC warning
  572. <ul>
  573. <li>The warning is detected when the UNUSED() macro is called from C++ file</li>
  574. </ul></li>
  575. <li>General updates to fix MISRA 2012 compilation errors
  576. <ul>
  577. <li>HAL_IS_BIT_SET()/HAL_IS_BIT_CLR() macros implementation update</li>
  578. <li>“stdio.h” include updated with “stddef.h”</li>
  579. </ul></li>
  580. <li>Add HAL_GetUIDw0(), HAL_GetUIDw1() and HAL_GetUIDw2() API in order to returns the unique device identifier</li>
  581. </ul></li>
  582. <li><strong>HAL CAN</strong> update
  583. <ul>
  584. <li>Fields of CAN_InitTypeDef structure are reworked:
  585. <ul>
  586. <li>SJW to SyncJumpWidth, BS1 to TimeSeg1, BS2 to TimeSeg2, TTCM to TimeTriggeredMode, ABOM to AutoBusOff, AWUM to AutoWakeUp, NART to AutoRetransmission (inversed), RFLM to ReceiveFifoLocked and TXFP to TransmitFifoPriority</li>
  587. </ul></li>
  588. <li>Rename CAN_FilterConfTypeDef structure to CAN_FilterTypeDef and update some fields:
  589. <ul>
  590. <li>FilterNumber to FilterBank</li>
  591. <li>BankNumber to SlaveStartFilterBank</li>
  592. </ul></li>
  593. <li>Rename CanTxMsgTypeDef structure to CAN_TxHeaderTypeDef and update some fields:
  594. <ul>
  595. <li>Data to TransmitGlobalTime</li>
  596. </ul></li>
  597. <li>Rename CanRxMsgTypeDef structure to CAN_RxHeaderTypeDef and update some fields:
  598. <ul>
  599. <li>Data to Timestamp</li>
  600. <li>FMI to FilterMatchIndex</li>
  601. </ul></li>
  602. <li>Update possible values list for FilterActivation parameter in CAN_FilterTypeDef structure
  603. <ul>
  604. <li>CAN_FILTER_ENABLE instead of ENABLE</li>
  605. <li>CAN_FILTER_DISABLE instead of DISABLE</li>
  606. </ul></li>
  607. <li>HAL_CAN_Init() is split into both HAL_CAN_Init() and HAL_CAN_Start() API’s</li>
  608. <li>HAL_CAN_Transmit() is replaced by HAL_CAN_AddTxMessage() to place Tx Request, then HAL_CAN_GetTxMailboxesFreeLevel() for polling until completion.</li>
  609. <li>HAL_CAN_Transmit_IT() is replaced by HAL_CAN_ActivateNotification() to enable transmit IT, then HAL_CAN_AddTxMessage() for place Tx request.</li>
  610. <li>HAL_CAN_Receive() is replaced by HAL_CAN_GetRxFifoFillLevel() for polling until reception, then HAL_CAN_GetRxMessage()</li>
  611. <li>to get Rx message.</li>
  612. <li>HAL_CAN_Receive_IT() is replaced by HAL_CAN_ActivateNotification() to enable receive IT, then HAL_CAN_GetRxMessage()</li>
  613. <li>in the receive callback to get Rx message</li>
  614. <li>HAL_CAN_Slepp() is renamed as HAL_CAN_RequestSleep()</li>
  615. <li>HAL_CAN_TxCpltCallback() is split into HAL_CAN_TxMailbox0CompleteCallback(), HAL_CAN_TxMailbox1CompleteCallback() and HAL_CAN_TxMailbox2CompleteCallback().</li>
  616. <li>HAL_CAN_RxCpltCallback is split into HAL_CAN_RxFifo0MsgPendingCallback() and HAL_CAN_RxFifo1MsgPendingCallback().</li>
  617. <li>More complete “How to use the new driver” is detailed in the driver header section itself.</li>
  618. <li><em>Refer to the following example to identify the changes</em></li>
  619. </ul></li>
  620. <li><strong>HAL CRC</strong> update
  621. <ul>
  622. <li>Update __HAL_CRC_DR_RESET() macro</li>
  623. <li>Update HAL_CRC_DeInit() API to
  624. <ul>
  625. <li>Be able to return HAL status when CRC is is already busy</li>
  626. <li>DeInit the low level hardware after reset IDR register content</li>
  627. </ul></li>
  628. <li>Remove extra call to HAL_LOCK/HAL_UNLOCK from the followings API’s:
  629. <ul>
  630. <li>HAL_CRC_Accumulate()</li>
  631. <li>HAL_CRC_Calculate()</li>
  632. </ul></li>
  633. </ul></li>
  634. <li><strong>HAL CRYP</strong> update
  635. <ul>
  636. <li><strong>The CRYP_InitTypeDef</strong> is no more supported, changed by <strong>CRYP_ConfigTypedef</strong> to allow changing parameters</li>
  637. <li>Using HAL_CRYP_setConfig() API without reinitialize the CRYP IP using the HAL_CRYP_Init() API</li>
  638. <li>New parameters added in the <strong>CRYP_ConfigTypeDef</strong> structure: <strong>B0</strong> and <strong>DataWidthUnit</strong></li>
  639. <li>Input data size and error code parameters are added in the <strong>CRYP_HandleTypeDef</strong> structure</li>
  640. <li>Add new APIs to manage the CRYP configuration:
  641. <ul>
  642. <li>HAL_CRYP_SetConfig()</li>
  643. <li>HAL_CRYP_GetConfig()</li>
  644. </ul></li>
  645. <li>Add new APIs to encrypt and decrypt data:
  646. <ul>
  647. <li>HAL_CRYP_Encypt()</li>
  648. <li>HAL_CRYP_Decypt()</li>
  649. <li>HAL_CRYP_Encypt_IT()</li>
  650. <li>HAL_CRYP_Decypt_IT()</li>
  651. <li>HAL_CRYP_Encypt_DMA()</li>
  652. <li>HAL_CRYP_Decypt_DMA()</li>
  653. </ul></li>
  654. <li>More complete “How to use the new driver” is detailed in the driver header section itself.</li>
  655. <li><em>Refer to the following example to identify the changes</em></li>
  656. </ul></li>
  657. <li><strong>HAL DAC</strong> update
  658. <ul>
  659. <li>Overall rework of the driver for a more efficient implementation
  660. <ul>
  661. <li>Update HAL_DAC_Start(), HAL_DAC_Start_DMA(), HAL_DAC_Stop_DMA() and HAL_DAC_ConfigChannel() API to
  662. <ul>
  663. <li>Update lock mechanism for DAC process</li>
  664. <li>Optimize code by using direct register read</li>
  665. </ul></li>
  666. <li>Update HAL_DAC_IRQHandler() function to
  667. <ul>
  668. <li>Add error management in case DMA errors through HAL_DAC_DMAUnderrunCallbackCh1() and HAL_DACEx_DMAUnderrunCallbackCh2()</li>
  669. <li>Optimize code by using direct register read</li>
  670. </ul></li>
  671. </ul></li>
  672. </ul></li>
  673. <li><strong>HAL DCMI</strong> update
  674. <ul>
  675. <li>Update HAL_DCMI_Start_DMA() function to Enable the DCMI peripheral</li>
  676. <li>Add new timeout implementation based on cpu cycles for DCMI stop</li>
  677. <li>Update lock mechanism for DCMI process</li>
  678. <li>Update HAL_DCMI_IRQHandler() function to:
  679. <ul>
  680. <li>Optimize code by using direct register read</li>
  681. </ul></li>
  682. <li>The extension files stm32f2xx_hal_dcmi_ex.c/.h is added and kept empty for projects compatibility reason</li>
  683. <li>Add DCMI_SyncUnmaskTypeDef structure and HAL_DCMI_ConfigSyncUnmask() API to manage embedded synchronization delimiters unmasks</li>
  684. <li>HAL DCMI driver clean-up: remove non referenced callback APIs: HAL_DCMI_VsyncCallback() and HAL_DCMI_HsyncCallback()</li>
  685. </ul></li>
  686. <li><strong>HAL DMA</strong> update
  687. <ul>
  688. <li>Add clean of callbacks in HAL_DMA_DeInit() API</li>
  689. <li>Remove FIFO error enabling in “HAL_DMA_Start_IT”
  690. <ul>
  691. <li>when FIFO error monitoring is requested in IT model, the macro __HAL_DMA_ENABLE_IT can be used to enable the FIFO error IT at the user Msp functio</li>
  692. </ul></li>
  693. </ul></li>
  694. <li><strong>HAL FLASH</strong> update
  695. <ul>
  696. <li>HAL_FLASH_Unlock() update to return state error when the FLASH is already unlocked</li>
  697. </ul></li>
  698. <li><strong>HAL GPIO</strong> update
  699. <ul>
  700. <li>HAL_GPIO_TogglePin() API implementation update: to improve robustness</li>
  701. <li>HAL_GPIO_DeInit() API update to ensure clear all GPIO EXTI pending interrupts.</li>
  702. </ul></li>
  703. <li><strong>HAL HASH</strong> update
  704. <ul>
  705. <li>Overall rework of the driver for a more efficient implementation
  706. <ul>
  707. <li>HASH API changes for MISRA-C 2012 compliance</li>
  708. <li>Update HASH_Start_DMA() to add check on HASH_CR_MDMAT bit before checking input buffer length in case of multi-buffer processing</li>
  709. <li>Fill-up empty statement in HAL_HASH_DMAFeed_ProcessSuspend() to correct CodeSonar warning</li>
  710. </ul></li>
  711. </ul></li>
  712. <li><strong>HAL I2C</strong> update
  713. <ul>
  714. <li>I2C API changes for MISRA-C 2012 compliance:
  715. <ul>
  716. <li>Rename HAL_I2C_Master_Sequential_Transmit_IT() to HAL_I2C_Master_Seq_Transmit_IT()</li>
  717. <li>Rename HAL_I2C_Master_Sequentiel_Receive_IT() to HAL_I2C_Master_Seq_Receive_IT()</li>
  718. <li>Rename HAL_I2C_Slave_Sequentiel_Transmit_IT() to HAL_I2C_Slave_Seq_Transmit_IT()</li>
  719. <li>Rename HAL_I2C_Slave_Sequentiel_Receive_DMA() to HAL_I2C_Slave_Seq_Receive_DMA()</li>
  720. </ul></li>
  721. <li>Add support of I2C repeated start feature in DMA Mode With the following new API’s
  722. <ul>
  723. <li>HAL_I2C_Master_Seq_Transmit_DMA()</li>
  724. <li>HAL_I2C_Master_Seq_Receive_DMA()</li>
  725. <li>HAL_I2C_Slave_Seq_Transmit_DMA()</li>
  726. <li>HAL_I2C_Slave_Seq_Receive_DMA()</li>
  727. </ul></li>
  728. <li>Add new I2C transfer options to easy manage the sequential transfers
  729. <ul>
  730. <li>I2C_OTHER_FRAME</li>
  731. <li>I2C_OTHER_AND_LAST_FRAME</li>
  732. </ul></li>
  733. <li>Fix I2C send break issue in IT processes
  734. <ul>
  735. <li>Add additional check on hi2c-&gt;hdmatxand hi2c-&gt;hdmarx to avoid the DMA request enable when ITmode is used.</li>
  736. </ul></li>
  737. </ul></li>
  738. <li><strong>HAL UART/USART/IrDA/SMARTCARD</strong> update
  739. <ul>
  740. <li>Overall rework of the driver for a more efficient implementation
  741. <ul>
  742. <li>Improve I/O operation functions: separate transfer process and <em>PPP</em> state management</li>
  743. <li>Update the HAL_<em>PPP</em>_IRQHandler function by optimizing the management of interrupt errors</li>
  744. <li>Align driver with the Reference Manual regarding registers and bit definition naming</li>
  745. </ul></li>
  746. </ul></li>
  747. <li><strong>LL IWDG</strong> update
  748. <ul>
  749. <li>Update LL inline macros to use IWDGx parameter instead of IWDG instance defined in CMSIS device</li>
  750. </ul></li>
  751. <li><strong>HAL RNG</strong> update
  752. <ul>
  753. <li>Add ErrorCode parameter in HAL RNG Handler structure</li>
  754. <li>Add HAL_RNG_GetError() API</li>
  755. <li>HAL Lock/Unlock mechanism update</li>
  756. </ul></li>
  757. <li><strong>HAL/LL RTC</strong> update
  758. <ul>
  759. <li>HAL/ LL drivers optimization
  760. <ul>
  761. <li>HAL driver: remove unused variables</li>
  762. <li>LL driver: getter APIs optimization</li>
  763. </ul></li>
  764. </ul></li>
  765. <li><strong>HAL/LL RCC</strong> update
  766. <ul>
  767. <li>Update HAL_RCC_DeInit() and LL_RCC_DeInit() APIs to
  768. <ul>
  769. <li>Be able to return HAL/LL status</li>
  770. <li>Add checks for HSI, PLL and PLLI2S ready before modifying RCC CFGR registers</li>
  771. <li>Clear all interrupt flags</li>
  772. <li>Initialize systick interrupt period</li>
  773. </ul></li>
  774. </ul></li>
  775. <li><strong>HAL SDMMC</strong> update
  776. <ul>
  777. <li>Add API HAL_SD_ConfigSpeedBusOperation() to configure the SD card speed bus mode</li>
  778. <li>Fix and improve state and error management</li>
  779. <li>Fix preprocessing compilation issue with SDIO STA STBITERR interrupt</li>
  780. <li>Align driver with the Reference Manual regarding registers and bit definition naming</li>
  781. </ul></li>
  782. <li><strong>HAL SPI</strong> update
  783. <ul>
  784. <li>Overall rework of the driver for a more efficient implementation
  785. <ul>
  786. <li>Add the following new macros:
  787. <ul>
  788. <li>SPI_CHECK_FLAG()</li>
  789. <li>SPI_CHECK_IT_SOURCE()</li>
  790. </ul></li>
  791. <li>Update HAL_SPI_StateTypeDef structure to add new state: HAL_SPI_STATE_ABORT</li>
  792. <li>Add HAL_SPI_Abort() to manage abort issue in SPI TX or Rx mode only</li>
  793. <li>Update HAL_SPI_Transmit()/HAL_SPI_Receive() API’s to fix memory overflow issue.</li>
  794. <li>Update HAL_SPI_Transmit_DMA : checking hmdtx instead of hdmrx.</li>
  795. <li>Update HAL_SPI_IRQHandler() function to
  796. <ul>
  797. <li>Add error management in case DMA errors through HAL_DMA_Abort_IT() and ErrorCallback()</li>
  798. <li>Optimize code by using direct register read</li>
  799. </ul></li>
  800. <li>Align driver with the Reference Manual regarding registers and bit definition naming</li>
  801. </ul></li>
  802. </ul></li>
  803. <li><strong>HAL I2S</strong> update
  804. <ul>
  805. <li>Overall rework of the driver for a more efficient implementation
  806. <ul>
  807. <li>Add the following new macros:
  808. <ul>
  809. <li>I2S_CHECK_FLAG()</li>
  810. <li>I2S_CHECK_IT_SOURCE()</li>
  811. </ul></li>
  812. <li>Update HAL_I2S_Transmit()/HAL_I2S_Receive() API’s to fix memory overflow issue</li>
  813. <li>Update HAL_SPI_IRQHandler() function to
  814. <ul>
  815. <li>Add error management in case DMA errors through HAL_DMA_Abort_IT() and ErrorCallback()</li>
  816. <li>Optimize code by using direct register read</li>
  817. </ul></li>
  818. <li>Add extra call to HAL_LOCK/HAL_UNLOCK to the followings API’s:
  819. <ul>
  820. <li>HAL_I2S_Transmit()</li>
  821. <li>HAL_I2S_Receive()</li>
  822. <li>HAL_I2S_Transmit_IT()</li>
  823. <li>HAL_I2S_Receive_IT()</li>
  824. <li>HAL_I2S_Transmit_DMA()</li>
  825. <li>HAL_I2S_Receive_DMA()</li>
  826. </ul></li>
  827. <li>Align driver with the Reference Manual regarding registers and bit definition naming</li>
  828. </ul></li>
  829. </ul></li>
  830. <li><strong>HAL/LL TIM</strong> update
  831. <ul>
  832. <li>Move the following TIM structures from stm32f4xx_hal_tim_ex.h into stm32f4xx_hal_tim.h
  833. <ul>
  834. <li>TIM_MasterConfigTypeDef()</li>
  835. <li>TIM_BreakDeadTimeConfigTypeDef()</li>
  836. </ul></li>
  837. <li>Add new TIM Callbacks API’s:
  838. <ul>
  839. <li>HAL_TIM_PeriodElapsedHalfCpltCallback()</li>
  840. <li>HAL_TIM_IC_CaptureHalfCpltCallback()</li>
  841. <li>HAL_TIM_PWM_PulseFinishedHalfCpltCallback()</li>
  842. <li>HAL_TIM_TriggerHalfCpltCallback()</li>
  843. </ul></li>
  844. <li>TIM API changes for MISRA-C 2012 compliance:
  845. <ul>
  846. <li>Rename HAL_TIM_SlaveConfigSynchronization to HAL_TIM_SlaveConfigSynchro</li>
  847. <li>Rename HAL_TIM_SlaveConfigSynchronization_IT to HAL_TIM_SlaveConfigSynchro_IT</li>
  848. <li>Rename HAL_TIMEx_ConfigCommutationEvent to HAL_TIMEx_ConfigCommutEvent</li>
  849. <li>Rename HAL_TIMEx_ConfigCommutationEvent_IT to HAL_TIMEx_ConfigCommutEvent_IT</li>
  850. <li>Rename HAL_TIMEx_ConfigCommutationEvent_DMA to HAL_TIMEx_ConfigCommutEvent_DMA</li>
  851. <li>Rename HAL_TIMEx_CommutationCallback to HAL_TIMEx_CommutCallback</li>
  852. <li>Rename HAL_TIMEx_DMACommutationCplt to TIMEx_DMACommutationCplt</li>
  853. </ul></li>
  854. <li>Add a call to HAL_DMA_Abort_IT from HAL_TIM_XXX_Stop_DMA</li>
  855. </ul></li>
  856. <li><strong>HAL/LL USB</strong> update
  857. <ul>
  858. <li>Rework USB interrupt handler and improve HS DMA support in Device mode</li>
  859. <li>Fix BCD handling for OTG instance in device mode</li>
  860. <li>cleanup reference to low speed in device mode</li>
  861. <li>Allow writing TX FIFO in case of transfer length is equal to available space in the TX FIFO</li>
  862. <li>Fix Toggle OUT interrupt channel in host mode</li>
  863. <li>Add new callback to be used to handle usb device connection/disconnection
  864. <ul>
  865. <li>HAL_HCD_PortEnabled_Callback()</li>
  866. <li>HAL_HCD_PortDisabled_Callback()</li>
  867. </ul></li>
  868. <li>Update to prevent reactivate host interrupt channel</li>
  869. <li>Updated USB_WritePacket(), USB_ReadPacket()APIs to prevent compilation warning with GCC GNU v8.2.0</li>
  870. <li>Rework USB_EPStartXfer() API to enable theUSB endpoint before unmasking the TX FiFo empty interrupt in case DMA is not used</li>
  871. <li>USB HAL_HCD_Init() and HAL_PCD_Init() APIsupdated to avoid enabling USB DMA feature for OTG FS instance, USB DMAfeature is available only on OTG HS Instance</li>
  872. <li>Remove duplicated line in hal_hcd.c header file comment section</li>
  873. <li>Rework USB HAL driver to use instancePCD_SPEED_xxx, HCD_SPEED_xx speeds instead of OTG register Core speed definition during the instance initialization</li>
  874. <li>Software Quality improvement with a fix ofCodeSonar warning on PCD_Port_IRQHandler() and HCD_Port_IRQHandler()interrupt handlers</li>
  875. </ul></li>
  876. <li><strong>HAL UTILS</strong> update
  877. <ul>
  878. <li>Update LL_GetFlashSize() API to return uint32_t instead of uint16_t</li>
  879. </ul></li>
  880. </ul>
  881. </div>
  882. </div>
  883. <div class="collapse">
  884. <input type="checkbox" id="collapse-section9" aria-hidden="true"> <label for="collapse-section9" aria-hidden="true"><strong>V1.2.2 / 29-September-2017</strong></label>
  885. <div>
  886. <h2 id="main-changes-5">Main Changes</h2>
  887. <ul>
  888. <li>General updates to fix known defects and enhancements implementation</li>
  889. <li>Fix compilation warning with GCC compiler</li>
  890. <li>Remove Date and version from header files</li>
  891. <li><strong>HAL Generic</strong> update
  892. <ul>
  893. <li>Update __weak and __packed defined values for ARM compiler</li>
  894. <li>Update __ALIGN_BEGIN and __ALIGN_END defined values for ARM compiler</li>
  895. </ul></li>
  896. <li><strong>HAL I2C</strong> update
  897. <ul>
  898. <li>Update Interface APIs headers to remove confusing message about device address</li>
  899. <li>UpdateI2C_MasterReceive_RXNE() and I2C_MasterReceive_BTF() static APIs to fix badHandling of NACK in I2C master receive process.</li>
  900. </ul></li>
  901. <li><strong>HAL RCC</strong> update
  902. <ul>
  903. <li>Update HAL_RCC_GetOscConfig()API to:
  904. <ul>
  905. <li>set PLLR in theRCC_OscInitStruct</li>
  906. <li>check on null pointer</li>
  907. <li>Update HAL_RCC_ClockConfig()API to:</li>
  908. <li>check on null pointer</li>
  909. <li>optimize code size byupdating the handling method of the SWS bits</li>
  910. <li>update to use __HAL_FLASH_GET_LATENCY() flash macro instead of using direct registeraccess to LATENCY bits in FLASH ACR register.</li>
  911. </ul></li>
  912. <li>Update HAL_RCC_DeInit() to
  913. <ul>
  914. <li>Be able to return HAL status (HAL_OK, HAL_TIMEOUT and HAL_ERROR)</li>
  915. <li>Add checks for HSI, PLL and PLLI2S ready before modifying RCC CFGR registers</li>
  916. <li>Clear all interrupt flags</li>
  917. <li>Initialize systick interrupt period</li>
  918. </ul></li>
  919. <li>Update HAL_RCC_GetSysClockFreq() to avoid risk of rounding error which may leads to a wrong returned value.</li>
  920. </ul></li>
  921. <li><strong>HAL RNG</strong> update
  922. <ul>
  923. <li>HAL_RNG_Init() remove Lock()/Unlock()</li>
  924. </ul></li>
  925. <li><strong>HAL MMC</strong> update
  926. <ul>
  927. <li>HAL_MMC_Erase() API: add missing () to fix compilation warning detected with SW4STM32 when extra feature is enabled.</li>
  928. </ul></li>
  929. <li><strong>LL DMA</strong> update
  930. <ul>
  931. <li>Update to clear DMA flags using WRITE_REG() instead SET_REG() API to avoid read access to the IFCR register that is write only.</li>
  932. <li>Update values for the following defines: DMA_FLAG_FEIF0_4 and DMA_FLAG_DMEIF0_4</li>
  933. </ul></li>
  934. <li><strong>LL RTC</strong> update
  935. <ul>
  936. <li>Fix warning with static analyzer</li>
  937. </ul></li>
  938. <li><strong>LL USART</strong> update
  939. <ul>
  940. <li>Add assert macros to check USART BaudRate register</li>
  941. </ul></li>
  942. <li><strong>LL I2C</strong> update
  943. <ul>
  944. <li>Rename IS_I2C_CLOCK_SPEED()and IS_I2C_DUTY_CYCLE() respectively to IS_LL_I2C_CLOCK_SPEED() andIS_LL_I2C_DUTY_CYCLE() to avoid incompatible macros redefinition.</li>
  945. </ul></li>
  946. </ul>
  947. </div>
  948. </div>
  949. <div class="collapse">
  950. <input type="checkbox" id="collapse-section8" aria-hidden="true"> <label for="collapse-section8" aria-hidden="true"><strong>V1.2.1 / 14-April-2017</strong></label>
  951. <div>
  952. <h2 id="main-changes-6">Main Changes</h2>
  953. <ul>
  954. <li>General updates to fix known defects and enhancements implementation</li>
  955. <li><strong>HAL CONF Template</strong> update
  956. <ul>
  957. <li>Add support for HAL MMC driver.</li>
  958. </ul></li>
  959. <li><strong>HAL CAN</strong> update
  960. <ul>
  961. <li>Addmanagement of overrun error.</li>
  962. <li>Allowpossibility to receive messages from the 2 RX FIFOs in parallel viainterrupt.</li>
  963. <li>Fix messagelost issue with specific sequence of transmit requests.</li>
  964. <li>Handletransmission failure with error callback, when NART is enabled.</li>
  965. <li>Add __HAL_CAN_CANCEL_TRANSMIT() call to abort transmission whentimeout is reached</li>
  966. </ul></li>
  967. </ul>
  968. </div>
  969. </div>
  970. <div class="collapse">
  971. <input type="checkbox" id="collapse-section7" aria-hidden="true"> <label for="collapse-section7" aria-hidden="true"><strong>V1.2.0 / 17-March-2017</strong></label>
  972. <div>
  973. <h2 id="main-changes-7">Main Changes</h2>
  974. <ul>
  975. <li><strong>Add Low Layer drivers allowing performance and footprint optimization</strong>
  976. <ul>
  977. <li>Low Layer drivers APIs provide register level programming: require deep knowledge of peripherals described in STM32F2xx Reference Manuals</li>
  978. <li>Low Layer drivers are available for: ADC, Cortex, CRC, DAC, DMA, EXTI, GPIO, I2C, IWDG, PWR, RCC, RNG, RTC, SPI, TIM, USART, WWDG peripherals and additional Low Level Bus, System and Utilities APIs.</li>
  979. <li>Low Layer drivers APIs are implemented as static inline function in new Inc/stm32f2xx_ll_ppp.h files for PPP peripherals, there is no configuration file and each stm32f2xx_ll_ppp.h file must be included in user code.</li>
  980. </ul></li>
  981. <li>General updates to fix known defects and enhancements implementation</li>
  982. <li>Fix extra warnings with GCC compiler</li>
  983. <li>HAL drivers clean up: remove double casting ‘uint32_t’ and ‘U’</li>
  984. <li>Add new <strong>HAL MMC</strong> driver</li>
  985. <li><strong>The following changes done on the HAL drivers require an update on the application code based on older HAL versions</strong>
  986. <ul>
  987. <li><strong>HAL SD</strong> update
  988. <ul>
  989. <li>Overall rework of the driver for a more efficient implementation
  990. <ul>
  991. <li>Modify initialization API and structures</li>
  992. <li>Modify Read / Write sequences: separate transfer process and SD Cards state management</li>
  993. <li>Adding interrupt mode for Read / Write operations</li>
  994. <li>Update the HAL_SD_IRQHandler function by optimizing the management of interrupt errors</li>
  995. </ul></li>
  996. <li>Refer to the following example to identify the changes: BSP example and USB_Device/MSC_Standalone application</li>
  997. </ul></li>
  998. <li><strong>HAL NAND</strong> update</li>
  999. <li>Modify NAND_AddressTypeDef, NAND_DeviceConfigTypeDef and NAND_HandleTypeDef structures fields</li>
  1000. <li>Add new HAL_NAND_ConfigDevice API</li>
  1001. </ul></li>
  1002. <li><strong>HAL</strong> update
  1003. <ul>
  1004. <li>Modify default HAL_Delay implementation to guarantee minimum delay</li>
  1005. <li>Add HAL_GetUID API : returns the unique device identifier</li>
  1006. </ul></li>
  1007. <li><strong>HAL Cortex</strong> update
  1008. <ul>
  1009. <li>Move HAL_MPU_Disable() and HAL_MPU_Enable() from stm32f2xx_hal_cortex.h to stm32f2xx_hal_cortex.c</li>
  1010. <li>Clear the whole MPU control register in HAL_MPU_Disable() API</li>
  1011. </ul></li>
  1012. <li><strong>HAL FLASH</strong> update
  1013. <ul>
  1014. <li>IS_FLASH_ADDRESS() macro update to support OTP range</li>
  1015. <li>FLASH_Program_DoubleWord(): Replace 64-bit accesses with 2 double-words operations</li>
  1016. </ul></li>
  1017. <li><strong>HAL GPIO</strong> update
  1018. <ul>
  1019. <li>Update IS_GPIO_PIN() macro implementation to be more safe</li>
  1020. </ul></li>
  1021. <li><strong>HAL RCC</strong> update
  1022. <ul>
  1023. <li>Update IS_RCC_PLLQ_VALUE() macro implementation: the minimum accepted value is 2 instead of 4</li>
  1024. <li>Update to refer to AHBPrescTable[] and APBPrescTable[] tables defined in system_stm32f2xx.c file instead of APBAHBPrescTable[] table.</li>
  1025. </ul></li>
  1026. <li><strong>HAL DMA</strong> update
  1027. <ul>
  1028. <li>HAL_DMA_Init(): update to check compatibility between FIFO threshold level and size of the memory burst</li>
  1029. </ul></li>
  1030. <li><strong>HAL UART/USART/IrDA/SMARTCARD</strong> (referenced as PPP here below)
  1031. <ul>
  1032. <li>DMA Receive process; the code has been updated to clear the PPP OVR flag before enabling DMA receive request.</li>
  1033. <li>Add transfer abort APIs and associated callbacks :
  1034. <ul>
  1035. <li>HAL_PPP_Abort()</li>
  1036. <li>HAL_PPP_AbortTransmit()</li>
  1037. <li>HAL_PPP_AbortReceive()</li>
  1038. <li>HAL_PPP_Abort_IT()</li>
  1039. <li>HAL_PPP_AbortTransmit_IT()</li>
  1040. <li>HAL_PPP_AbortReceive_IT()</li>
  1041. <li>HAL_PPP_AbortCpltCallback()</li>
  1042. <li>HAL_PPP_AbortTransmitCpltCallback()</li>
  1043. <li>HAL_PPP_AbortReceiveCpltCallback()</li>
  1044. </ul></li>
  1045. </ul></li>
  1046. <li><strong>HAL CAN</strong> update
  1047. <ul>
  1048. <li>Remove Lock mechanism from HAL_CAN_Transmit_IT() and HAL_CAN_Receive_IT() processes</li>
  1049. <li>HAL CAN driver optimization</li>
  1050. </ul></li>
  1051. <li><strong>HAL TIM</strong> update
  1052. <ul>
  1053. <li>Add __HAL_TIM_MOE_DISABLE_UNCONDITIONALLY() macro to disable Master output without check on TIM channel state.</li>
  1054. <li>Update HAL_TIMEx_ConfigBreakDeadTime() to fix TIM BDTR register corruption.</li>
  1055. </ul></li>
  1056. <li><strong>HAL I2C</strong> update
  1057. <ul>
  1058. <li>Update HAL_I2C_Master_Transmit() and HAL_I2C_Slave_Transmit() to avoid sending extra bytes at the end of the transmit processes</li>
  1059. <li>UpdateHAL_I2C_Mem_Read() API to fix wrong check on misused parameter “Size”</li>
  1060. <li>UpdateI2C_MasterReceive_RXNE() and I2C_MasterReceive_BTF() static APIs toenhance Master sequential reception process.</li>
  1061. </ul></li>
  1062. <li><strong>HAL SPI</strong> update
  1063. <ul>
  1064. <li>Add transfer abort APIs and associated callbacks in interrupt mode
  1065. <ul>
  1066. <li>HAL_SPI_Abort()</li>
  1067. <li>HAL_SPI_Abort_IT()</li>
  1068. <li>HAL_SPI_AbortCpltCallback()</li>
  1069. </ul></li>
  1070. </ul></li>
  1071. <li><strong>HAL USB PCD</strong> update
  1072. <ul>
  1073. <li>Flush all TX FIFOs on USB Reset</li>
  1074. <li>Remove Lock mechanism from HAL_PCD_EP_Transmit() and HAL_PCD_EP_Receive() API’s</li>
  1075. </ul></li>
  1076. <li><strong>LL USB</strong> update
  1077. <ul>
  1078. <li>Enable DMA Burst mode for USB OTG HS</li>
  1079. <li>Fix SD card detection issue</li>
  1080. </ul></li>
  1081. <li><strong>LL SDMMC</strong> update
  1082. <ul>
  1083. <li>Add new SDMMC_CmdSDEraseStartAdd, SDMMC_CmdSDEraseEndAdd, SDMMC_CmdOpCondition and SDMMC_CmdSwitch functions</li>
  1084. </ul></li>
  1085. </ul>
  1086. </div>
  1087. </div>
  1088. <div class="collapse">
  1089. <input type="checkbox" id="collapse-section6" aria-hidden="true"> <label for="collapse-section6" aria-hidden="true"><strong>V1.1.3 / 29-June-2016</strong></label>
  1090. <div>
  1091. <h2 id="main-changes-8">Main Changes</h2>
  1092. <ul>
  1093. <li>General updates to fix known defects and enhancements implementation</li>
  1094. <li>Enhance HAL delay and time base implementation:
  1095. <ul>
  1096. <li>Add new drivers stm32f2xx_hal_timebase_tim_template.c, stm32f2xx_hal_timebase_rtc_alarm_template.c and stm32f2xx_hal_timebase_rtc_wakeup_template.c which override the native HAL time base functions (defined as weak) to either use the TIM or the RTC as time base tick source. For more details about the usage of these drivers, please refer to HAL_TimeBase examples and FreeRTOS-based applications</li>
  1097. </ul></li>
  1098. <li><strong>The following changes done on the HAL drivers require an update on the application code based on HAL V1.1.2</strong>
  1099. <ul>
  1100. <li>HAL UART, USART, IRDA, SMARTCARD, SPI, I2C (referenced as PPP here below) drivers
  1101. <ul>
  1102. <li>Add PPP error management during DMA process. This requires the following updates on user application:
  1103. <ul>
  1104. <li>Configure and enable the PPP IRQ in HAL_PPP_MspInit() function</li>
  1105. <li>In stm32f2xx_it.c file, PPP_IRQHandler() function: add a call to HAL_PPP_IRQHandler() function</li>
  1106. <li>Add and customize the Error Callback API: HAL_PPP_ErrorCallback()</li>
  1107. </ul></li>
  1108. <li>HAL I2C driver:◾Update to avoid waiting on STOPF/BTF/AF flag under DMA ISR by using the PPP end of transfer interrupt in theDMA transfer process. This requires the following updates on user application:
  1109. <ul>
  1110. <li>Configure and enable the PPP IRQ in HAL_PPP_MspInit() function</li>
  1111. <li>In stm32f2xx_it.c file, PPP_IRQHandler() function: add a call to HAL_PPP_IRQHandler() function</li>
  1112. </ul></li>
  1113. <li>I2C transfer processes IT update: NACK during addressing phase is managed through I2C Error interrupt instead of HAL state</li>
  1114. </ul></li>
  1115. <li>HAL IWDG driver: rework overall driver for better implementation
  1116. <ul>
  1117. <li>Remove HAL_IWDG_Start(), HAL_IWDG_MspInit() and HAL_IWDG_GetState() APIs</li>
  1118. </ul></li>
  1119. <li>HAL WWDG driver: rework overall driver for better implementation
  1120. <ul>
  1121. <li>Remove HAL_WWDG_Start(), HAL_WWDG_Start_IT(), HAL_WWDG_MspDeInit() and HAL_WWDG_GetState() APIs</li>
  1122. <li>Update the HAL_WWDG_Refresh(WWDG_HandleTypeDef *hwwdg, uint32_t counter) function and API by removing the “counter” parameter</li>
  1123. </ul></li>
  1124. </ul></li>
  1125. <li><strong>HAL Generic</strong> update
  1126. <ul>
  1127. <li>stm32f2xx_hal_conf_template.h
  1128. <ul>
  1129. <li>Optimize HSE Startup Timeout value from 5000ms to 100 ms</li>
  1130. <li>Add new define LSE_STARTUP_TIMEOUT</li>
  1131. <li>Add new define USE_SPI_CRC for code cleanup when the CRC calculation is disabled.</li>
  1132. </ul></li>
  1133. <li>Update HAL drivers to support MISRA C 2004 rule 10.6</li>
  1134. <li>Add new template driver to configure timebase using TIMER :
  1135. <ul>
  1136. <li>stm32f2xx_hal_timebase_tim_template.c</li>
  1137. </ul></li>
  1138. </ul></li>
  1139. <li><strong>HAL CAN</strong> update
  1140. <ul>
  1141. <li>Update HAL_CAN_Transmit() and HAL_CAN_Transmit_IT() functions to unlock process when all Mailboxes are busy</li>
  1142. </ul></li>
  1143. <li><strong>HAL DCMI</strong> update
  1144. <ul>
  1145. <li>Rename DCMI_DMAConvCplt to DCMI_DMAXferCplt</li>
  1146. <li>Update HAL_DCMI_Start_DMA() function to Enable the DCMI peripheral</li>
  1147. <li>Add new timeout implementation based on cpu cycles for DCMI stop</li>
  1148. <li>Add HAL_DCMI_Suspend() function to suspend DCMI capture</li>
  1149. <li>Add HAL_DCMI_Resume() function to resume capture after DCMI suspend</li>
  1150. <li>Update lock mechanism for DCMI process</li>
  1151. <li>Update HAL_DCMI_IRQHandler() function to
  1152. <ul>
  1153. <li>Add error management in case DMA errors through XferAbortCallback() and HAL_DMA_Abort_IT()</li>
  1154. <li>Optimize code by using direct register read</li>
  1155. </ul></li>
  1156. </ul></li>
  1157. <li><strong>HAL DMA</strong> update
  1158. <ul>
  1159. <li>Add new APIs HAL_DMA_RegisterCallback() and HAL_DMA_UnRegisterCallback to register/unregister the different callbacks identified by the enum typedef HAL_DMA_CallbackIDTypeDef</li>
  1160. <li>Add new API HAL_DMA_Abort_IT() to abort DMA transfer under interrupt context
  1161. <ul>
  1162. <li>The new registered Abort callback is called when DMA transfer abortion is completed</li>
  1163. </ul></li>
  1164. <li>Add the check of compatibility between FIFO threshold level and size of the memory burst in the HAL_DMA_Init() API</li>
  1165. <li>Add new Error Codes: HAL_DMA_ERROR_PARAM, HAL_DMA_ERROR_NO_XFER and HAL_DMA_ERROR_NOT_SUPPORTED</li>
  1166. <li>Remove all DMA states related to MEM0/MEM1 in HAL_DMA_StateTypeDef</li>
  1167. </ul></li>
  1168. <li><strong>HAL ETH</strong> update
  1169. <ul>
  1170. <li>Removal of ETH MAC debug register defines</li>
  1171. </ul></li>
  1172. <li><strong>HAL HCD</strong> update
  1173. <ul>
  1174. <li>Update HCD_Port_IRQHandler() to unmask disconnect IT only when the port is disable</li>
  1175. </ul></li>
  1176. <li><strong>HAL I2C</strong> update
  1177. <ul>
  1178. <li>Add support of I2C repeated start feature:
  1179. <ul>
  1180. <li>With the following new API’s
  1181. <ul>
  1182. <li>HAL_I2C_Master_Sequential_Transmit_IT()</li>
  1183. <li>HAL_I2C_Master_Sequential_Receive_IT()</li>
  1184. <li>HAL_I2C_Master_Abort_IT()</li>
  1185. <li>HAL_I2C_Slave_Sequential_Transmit_IT()</li>
  1186. <li>HAL_I2C_Slave_Sequential_Receive_IT()</li>
  1187. <li>HAL_I2C_EnableListen_IT()</li>
  1188. <li>HAL_I2C_DisableListen_IT()</li>
  1189. </ul></li>
  1190. <li>Add new user callbacks:
  1191. <ul>
  1192. <li>HAL_I2C_ListenCpltCallback()</li>
  1193. <li>HAL_I2C_AddrCallback()</li>
  1194. </ul></li>
  1195. </ul></li>
  1196. <li>Update to generate STOP condition when a acknowledge failure error is detected</li>
  1197. <li>Several update on HAL I2C driver to implement the new I2C state machine:
  1198. <ul>
  1199. <li>Add new API to get the I2C mode: HAL_I2C_GetMode()</li>
  1200. <li>Update I2C process to manage the new I2C states.</li>
  1201. </ul></li>
  1202. <li>Fix wrong behaviour in single byte transmission</li>
  1203. <li>Update I2C_WaitOnFlagUntilTimeout() to manage the NACK feature.</li>
  1204. <li>Update I2C transmission process to support the case data size equal 0</li>
  1205. <li>Update Polling management:
  1206. <ul>
  1207. <li>The Timeout value must be estimated for the overall process duration: the Timeout measurement is cumulative</li>
  1208. </ul></li>
  1209. <li>Add the management of Abort service: Abort DMA transfer through interrupt
  1210. <ul>
  1211. <li>In the case of Master Abort IT transfer usage:
  1212. <ul>
  1213. <li>Add new user HAL_I2C_AbortCpltCallback() to inform user of the end of abort process</li>
  1214. <li>A new abort state is defined in the HAL_I2C_StateTypeDef structure</li>
  1215. </ul></li>
  1216. </ul></li>
  1217. <li>Add the management of I2C peripheral errors, ACK failure and STOP condition detection during DMA process. This requires the following updates on user application:
  1218. <ul>
  1219. <li>Configure and enable the I2C IRQ in HAL_I2C_MspInit() function</li>
  1220. <li>In stm32f2xx_it.c file, I2C_IRQHandler() function: add a call to HAL_I2C_IRQHandler() function</li>
  1221. <li>Add and customize the Error Callback API: HAL_I2C_ErrorCallback()</li>
  1222. </ul></li>
  1223. <li>NACK error during addressing phase is returned through interrupt instead of previously through I2C transfer API’s</li>
  1224. <li>I2C addressing phase is updated to be managed using interrupt instead of polling (Only for HAL I2C driver)
  1225. <ul>
  1226. <li>Add new static functions to manage I2C SB, ADDR and ADD10 flags</li>
  1227. </ul></li>
  1228. </ul></li>
  1229. <li><strong>HAL IRDA</strong> update
  1230. <ul>
  1231. <li>Several update on HAL IRDA driver to implement the new UART state machine:
  1232. <ul>
  1233. <li>Add new field in IRDA_HandleTypeDef structure: “rxState”, IRDA state information related to Rx Operations</li>
  1234. <li>Rename “state” field in UART_HandleTypeDef structure by “gstate”: IRDA state information related to global Handle management and Tx Operations</li>
  1235. <li>Update IRDA process to manage the new UART states.</li>
  1236. <li>Update __HAL_IRDA_RESET_HANDLE_STATE() macro to handle the new IRDA state parameters (gState, rxState)</li>
  1237. </ul></li>
  1238. <li>Removal of IRDA_TIMEOUT_VALUE define</li>
  1239. <li>Update IRDA_BRR() Macro to fix wrong baudrate calculation</li>
  1240. <li>Update Polling management:
  1241. <ul>
  1242. <li>The user Timeout value must be estimated for the overall process duration: the Timeout measurement is cumulative</li>
  1243. </ul></li>
  1244. <li>Update DMA process:
  1245. <ul>
  1246. <li>Update the management of IRDA peripheral errors during DMA process. This requires the following updates in user application:
  1247. <ul>
  1248. <li>Configure and enable the IRDA IRQ in HAL_IRDA_MspInit() function</li>
  1249. <li>In stm32f2xx_it.c file, IRDA_IRQHandler() function: add a call to HAL_IRDA_IRQHandler() function</li>
  1250. <li>Add and customize the Error Callback API: HAL_IRDA_ErrorCallback()</li>
  1251. </ul></li>
  1252. </ul></li>
  1253. </ul></li>
  1254. <li><strong>HAL IWDG</strong> update
  1255. <ul>
  1256. <li>Overall rework of the driver for a more efficient implementation
  1257. <ul>
  1258. <li>Remove the following APIs:
  1259. <ul>
  1260. <li>HAL_IWDG_Start()</li>
  1261. <li>HAL_IWDG_MspInit()</li>
  1262. <li>HAL_IWDG_GetState()</li>
  1263. </ul></li>
  1264. <li>Update implementation:
  1265. <ul>
  1266. <li>HAL_IWDG_Init(): this function insures the configuration and the start of the IWDG counter</li>
  1267. <li>HAL_IWDG_Refresh(): this function insures the reload of the IWDG counter</li>
  1268. </ul></li>
  1269. <li>Refer to the following example to identify the changes: IWDG_Example</li>
  1270. </ul></li>
  1271. </ul></li>
  1272. <li><strong>HAL NOR</strong> update
  1273. <ul>
  1274. <li>Update NOR_ADDR_SHIFT macro implementation</li>
  1275. </ul></li>
  1276. <li><strong>HAL PCD</strong> update
  1277. <ul>
  1278. <li>Update HAL_PCD_IRQHandler() to get HCLK frequency before setting TRDT value</li>
  1279. </ul></li>
  1280. <li><strong>HAL RCC</strong> update
  1281. <ul>
  1282. <li>Add new default define value for HSI calibration “RCC_HSICALIBRATION_DEFAULT”</li>
  1283. <li>Optimize Internal oscillators and PLL startup timeout</li>
  1284. <li>Update to avoid the disable for HSE/LSE oscillators before setting the new RCC HSE/LSE configuration and add the following notes in HAL_RCC_OscConfig() API description:
  1285. <ul>
  1286. <li><ul>
  1287. <li><span class="citation" data-cites="note">@note</span> Transitions LSE Bypass to LSE On and LSE On to LSE Bypass are not</li>
  1288. </ul></li>
  1289. <li><ul>
  1290. <li>supported by this API. User should request a transition to LSE Off</li>
  1291. </ul></li>
  1292. <li><ul>
  1293. <li>first and then LSE On or LSE Bypass.</li>
  1294. </ul></li>
  1295. <li><ul>
  1296. <li><span class="citation" data-cites="note">@note</span> Transition HSE Bypass to HSE On and HSE On to HSE Bypass are not</li>
  1297. </ul></li>
  1298. <li><ul>
  1299. <li>supported by this API. User should request a transition to HSE Off</li>
  1300. </ul></li>
  1301. <li><ul>
  1302. <li>first and then HSE On or HSE Bypass.◦Optimize the HAL_RCC_ClockConfig() API implementation</li>
  1303. </ul></li>
  1304. </ul></li>
  1305. <li>Update HAL_RCC_ClockConfig() function to adjust the SystemCoreClock</li>
  1306. <li>HAL_RCCEx_PeriphCLKConfig() API: update to fix the RTC clock configuration issue</li>
  1307. </ul></li>
  1308. <li><strong>HAL RTC</strong> update
  1309. <ul>
  1310. <li>Add new timeout implementation based on cpu cycles for ALRAWF, ALRBWF and WUTWF flags</li>
  1311. </ul></li>
  1312. <li><strong>HAL SMARTCARD</strong> update
  1313. <ul>
  1314. <li>Several update on HAL SMARTCARD driver to implement the new UART state machine:
  1315. <ul>
  1316. <li>Add new field in SMARTCARD_HandleTypeDef structure: “rxState”, SMARTCARDstate information related to Rx Operations</li>
  1317. <li>Rename “state” field in UART_HandleTypeDef structure by “gstate”: SMARTCARDstate information related to global Handle management and Tx Operations</li>
  1318. <li>Update SMARTCARD process to manage the new UART states.</li>
  1319. <li>Update __HAL_SMARTCARD_RESET_HANDLE_STATE() macro to handle the new SMARTCARD state parameters (gState, rxState)</li>
  1320. </ul></li>
  1321. <li>Update SMARTCARD_BRR() macro to fix wrong baudrate calculation</li>
  1322. <li>Update Polling management:
  1323. <ul>
  1324. <li>The user Timeout value must be estimated for the overall process duration: the Timeout measurement is cumulative</li>
  1325. </ul></li>
  1326. <li>Update DMA process:
  1327. <ul>
  1328. <li>Update the management of SMARTCARD peripheral errors during DMA process. This requires the following updates in user application:
  1329. <ul>
  1330. <li>Configure and enable the SMARTCARD IRQ in HAL_SMARTCARD_MspInit() function</li>
  1331. <li>In stm32f2xx_it.c file, SMARTCARD_IRQHandler() function: add a call to HAL_SMARTCARD_IRQHandler() function</li>
  1332. <li>Add and customize the Error Callback API: HAL_SMARTCARD_ErrorCallback()</li>
  1333. </ul></li>
  1334. </ul></li>
  1335. </ul></li>
  1336. <li><strong>HAL SPI</strong> update
  1337. <ul>
  1338. <li>Major Update to improve performance in polling/interrupt mode to reach max frequency:
  1339. <ul>
  1340. <li>Polling mode:
  1341. <ul>
  1342. <li>Replace use of SPI_WaitOnFlagUnitTimeout() funnction by “if” statement to check on RXNE/TXE flags while transferring data</li>
  1343. <li>Use API data pointer instead of SPI handle data pointer</li>
  1344. <li>Use a Goto implementation instead of “if..else” statements</li>
  1345. </ul></li>
  1346. </ul></li>
  1347. <li>Interrupt mode:
  1348. <ul>
  1349. <li>Minimize access on SPI registers</li>
  1350. <li>Split the SPI modes into dedicated static functions to minimize checking statements under HAL_IRQHandler():</li>
  1351. <li>1lines/2lines modes</li>
  1352. <li>8 bit/ 16 bits data formats</li>
  1353. <li>CRC calculation enabled/disabled</li>
  1354. <li>Remove waiting loop under ISR when closing the communication</li>
  1355. </ul></li>
  1356. <li>All modes
  1357. <ul>
  1358. <li>Adding switch USE_SPI_CRC to minimize number of statements when CRC calculation is disabled
  1359. <ul>
  1360. <li>Update Timeout management to check on global process</li>
  1361. <li>Update Error code management in all processes</li>
  1362. <li>Update DMA process:◾Add the management of SPI peripheral errors during DMA process. This requires the following updates in the user application:</li>
  1363. <li>Configure and enable the SPI IRQ in HAL_SPI_MspInit() function</li>
  1364. <li>In stm32f2xx_it.c file, SPI_IRQHandler() function: add a call to HAL_SPI_IRQHandler() function</li>
  1365. <li>Add and customize the Error Callback API: HAL_SPI_ErrorCallback()</li>
  1366. <li>Refer to the following example which describe the changes: SPI_FullDuplex_ComDMA</li>
  1367. </ul></li>
  1368. </ul></li>
  1369. </ul></li>
  1370. <li><strong>HAL UART</strong> update
  1371. <ul>
  1372. <li>Several update on HAL UART driver to implement the new UART state machine:
  1373. <ul>
  1374. <li>Add new field in UART_HandleTypeDef structure: “rxState”, UART state information related to Rx Operations</li>
  1375. <li>Rename “state” field in UART_HandleTypeDef structure by “gstate”: UART state information related to global Handle management and Tx Operations</li>
  1376. <li>Update UART process to manage the new UART states.</li>
  1377. <li>Update __HAL_UART_RESET_HANDLE_STATE() macro to handle the new UART state parameters (gState, rxState)</li>
  1378. </ul></li>
  1379. <li>Update UART_BRR_SAMPLING16() and UART_BRR_SAMPLING8() Macros to fix wrong baudrate calculation.</li>
  1380. <li>Update Polling management:
  1381. <ul>
  1382. <li>The user Timeout value must be estimated for the overall process duration: the Timeout measurement is cumulative</li>
  1383. </ul></li>
  1384. <li>Update DMA process:
  1385. <ul>
  1386. <li>Update the management of UART peripheral errors during DMA process. This requires the following updates in user application:
  1387. <ul>
  1388. <li>Configure and enable the UART IRQ in HAL_UART_MspInit() function</li>
  1389. <li>In stm32f2xx_it.c file, UART_IRQHandler() function: add a call to HAL_UART_IRQHandler() function</li>
  1390. <li>Add and customize the Error Callback API: HAL_UART_ErrorCallback()</li>
  1391. </ul></li>
  1392. </ul></li>
  1393. </ul></li>
  1394. <li><strong>HAL USART</strong> update
  1395. <ul>
  1396. <li>Update Polling management:
  1397. <ul>
  1398. <li>The user Timeout value must be estimated for the overall process duration: the Timeout measurement is cumulative</li>
  1399. </ul></li>
  1400. <li>Update DMA process:
  1401. <ul>
  1402. <li>Update the management of USART peripheral errors during DMA process. This requires the following updates in user application:
  1403. <ul>
  1404. <li>Configure and enable the USART IRQ in HAL_USART_MspInit() function</li>
  1405. <li>In stm32f2xx_it.c file, USART_IRQHandler() function: add a call to HAL_USART_IRQHandler() function</li>
  1406. <li>Add and customize the Error Callback API: HAL_USART_ErrorCallback()</li>
  1407. </ul></li>
  1408. </ul></li>
  1409. </ul></li>
  1410. <li><strong>HAL WWDG</strong> update
  1411. <ul>
  1412. <li>Overall rework of the driver for more efficient implementation
  1413. <ul>
  1414. <li>Remove the following APIs:
  1415. <ul>
  1416. <li>HAL_WWDG_Start()</li>
  1417. <li>HAL_WWDG_Start_IT()</li>
  1418. <li>HAL_WWDG_MspDeInit()</li>
  1419. <li>HAL_WWDG_GetState()</li>
  1420. </ul></li>
  1421. <li>Update implementation:
  1422. <ul>
  1423. <li>HAL_WWDG_Init()</li>
  1424. <li>A new parameter in the Init structure: EWIMode
  1425. <ul>
  1426. <li>HAL_WWDG_MspInit()</li>
  1427. </ul></li>
  1428. <li>HAL_WWDG_Refresh()
  1429. <ul>
  1430. <li>This function insures the reload of the counter</li>
  1431. <li>The “counter” parameter has been removed</li>
  1432. </ul></li>
  1433. <li>HAL_WWDG_IRQHandler()</li>
  1434. <li>HAL_WWDG_EarlyWakeupCallback() is the new prototype of HAL_WWDG_WakeUpCallback()</li>
  1435. </ul></li>
  1436. </ul></li>
  1437. <li>Refer to the following example to identify the changes: WWDG_Example</li>
  1438. </ul></li>
  1439. </ul>
  1440. </div>
  1441. </div>
  1442. <div class="collapse">
  1443. <input type="checkbox" id="collapse-section5" aria-hidden="true"> <label for="collapse-section5" aria-hidden="true"><strong>V1.1.2 / 11-December-2015</strong></label>
  1444. <div>
  1445. <h2 id="main-changes-9">Main Changes</h2>
  1446. <ul>
  1447. <li><strong>HAL RCC</strong> update
  1448. <ul>
  1449. <li>Fix compilation errors with the __HAL_RCC_DAC_IS_CLK_DISABLED(), __HAL_RCC_CRYP_IS_CLK_DISABLED() and __HAL_RCC_HASH_IS_CLK_DISABLED() macros</li>
  1450. </ul></li>
  1451. <li><strong>HAL ETH</strong> update
  1452. <ul>
  1453. <li>Update HAL_ETH_Init() function to add timeout on the Software reset management</li>
  1454. </ul></li>
  1455. </ul>
  1456. </div>
  1457. </div>
  1458. <div class="collapse">
  1459. <input type="checkbox" id="collapse-section4" aria-hidden="true"> <label for="collapse-section4" aria-hidden="true"><strong>V1.1.1 / 20-November-2015</strong></label>
  1460. <div>
  1461. <h2 id="main-changes-10">Main Changes</h2>
  1462. <ul>
  1463. <li>General updates to fix known defects and enhancements implementation</li>
  1464. <li><strong>One change done on the HAL CRYP requires an update on the application code based on HAL V1.1.0</strong>
  1465. <ul>
  1466. <li>Update HAL_CRYP_DESECB_Decrypt() API to invert pPlainData and pCypherData parameters</li>
  1467. </ul></li>
  1468. <li><strong>HAL generic</strong> update
  1469. <ul>
  1470. <li>Update HAL weak empty callbacks to prevent unused argument compilation warnings with some compilers by calling the following line:
  1471. <ul>
  1472. <li>UNUSED(hppp);</li>
  1473. </ul></li>
  1474. <li>HSE_STARTUP_TIMEOUT constant has been corrected in stm32f2xx_hal_conf_template.h file, its value changed from 5000 to 100.</li>
  1475. </ul></li>
  1476. <li><strong>HAL CORTEX</strong> update
  1477. <ul>
  1478. <li>Remove duplication for __HAL_CORTEX_SYSTICKCLK_CONFIG() macro</li>
  1479. </ul></li>
  1480. <li><strong>HAL HASH</strong> update
  1481. <ul>
  1482. <li>Rename HAL_HASH_STATETypeDef to HAL_HASH_StateTypeDef</li>
  1483. <li>Rename HAL_HASH_PhaseTypeDef to HAL_HASH_PhaseTypeDef</li>
  1484. </ul></li>
  1485. <li><strong>HAL RCC</strong> update
  1486. <ul>
  1487. <li>Add new macros __HAL_RCC_PPP_IS_CLK_ENABLED() to check on Clock enable/disable status</li>
  1488. <li>Update __HAL_RCC_USB_OTG_FS_CLK_DISABLE() macro to remove the disable for the SYSCFG</li>
  1489. </ul></li>
  1490. <li><strong>HAL FLASH</strong> update
  1491. <ul>
  1492. <li>__HAL_FLASH_INSTRUCTION_CACHE_RESET() macro: update to reset ICRST bit in the ACR register after setting it.</li>
  1493. </ul></li>
  1494. <li><strong>HAL CRYP</strong> update
  1495. <ul>
  1496. <li>Update HAL_CRYP_DESECB_Decrypt() API to fix the inverted pPlainData and pCypherData parameters issue</li>
  1497. </ul></li>
  1498. <li><strong>HAL TIM</strong> update
  1499. <ul>
  1500. <li>Update HAL_TIM_ConfigClockSource() API to check only the required parameters</li>
  1501. </ul></li>
  1502. <li><strong>HAL NAND</strong> update
  1503. <ul>
  1504. <li>Update HAL_NAND_Read_Page()/HAL_NAND_Write_Page()/HAL_NAND_Read_SpareArea() APIs to manage correctly the NAND Page access</li>
  1505. </ul></li>
  1506. <li><strong>HAL CAN</strong> update
  1507. <ul>
  1508. <li>Update to use “=” instead of “|=” to clear flags in the MSR, TSR, RF0R and RF1R registers</li>
  1509. </ul></li>
  1510. <li><strong>HAL PCD</strong> update
  1511. <ul>
  1512. <li>Fix typo in __HAL_USB_OTG_HS_WAKEUP_EXTI_ENABLE_RISING_FALLING_EDGE() macro implementation</li>
  1513. </ul></li>
  1514. <li><strong>LL FSMC</strong> update
  1515. <ul>
  1516. <li>Update the FSMC_NORSRAM_Extended_Timing_Init() API to remove the check on CLKDIvison and DataLatency parameters</li>
  1517. </ul></li>
  1518. </ul>
  1519. </div>
  1520. </div>
  1521. <div class="collapse">
  1522. <input type="checkbox" id="collapse-section3" aria-hidden="true"> <label for="collapse-section3" aria-hidden="true"><strong>V1.1.0 / 09-October-2015</strong></label>
  1523. <div>
  1524. <h2 id="main-changes-11">Main Changes</h2>
  1525. <ul>
  1526. <li><strong>Maintenance release to fix known defects and enhancements implementation</strong></li>
  1527. <li><strong>Macros and literals renaming to ensure compatibles across STM32 series</strong>, backward compatibility maintained thanks to new added file stm32_hal_legacy.h under /Inc/Legacy</li>
  1528. <li>Add *.chm UM for all drivers</li>
  1529. <li>Update drivers to be C++ compliant</li>
  1530. <li>Several update on source code formatting, for better UM generation (i.e. Doxygen tags updated)</li>
  1531. <li><strong>Four changes done on the HAL requires an update on the application code based on HAL V1.0.1</strong>
  1532. <ul>
  1533. <li>LSI_VALUE constant has been corrected in stm32f2xx_hal_conf.h file, its value changed from 40 KHz to 32 KHz</li>
  1534. <li>UART, USART, IRDA and SMARTCARD (referenced as PPP here below) drivers: in DMA transmit process, the code has been updated to avoid waiting on TC flag under DMA ISR, PPP TC interrupt is used instead. Below the update to be done on user application:
  1535. <ul>
  1536. <li>Configure and enable the USART IRQ in HAL_PPP_MspInit() function</li>
  1537. <li>In stm32f2xx_it.c file, PPP_IRQHandler() function: add a call to HAL_PPP_IRQHandler() function</li>
  1538. </ul></li>
  1539. <li>CRYP driver updated to support multi instance,so user must ensure that the new parameter Instance is initialized in his application(CRYPHandle.Instance = CRYP)</li>
  1540. <li>HASH IT process: update to call the HAL_HASH_InCpltCallback() at the end of the complete buffer instead of every each 512 bits</li>
  1541. </ul></li>
  1542. <li><strong>HAL generic</strong> update
  1543. <ul>
  1544. <li>stm32f2xx_hal_def.h
  1545. <ul>
  1546. <li>Remove NULL definition and add include for stdio.h</li>
  1547. <li>Add UNUSED() macro</li>
  1548. <li>Add a new define __NOINLINE to be used for the no inline code independent from tool chain</li>
  1549. </ul></li>
  1550. <li>stm32f2xx_hal_conf_template.h
  1551. <ul>
  1552. <li>Add a new define for LSI default value LSI_VALUE</li>
  1553. <li>Add a new define for LSE default value LSE_VALUE</li>
  1554. <li>Add a new define for Tick interrupt priority TICK_INT_PRIORITY (needed for the enhanced time base implementation)</li>
  1555. </ul></li>
  1556. <li>Enhance HAL delay and time base implementation
  1557. <ul>
  1558. <li>Systick timer is used by default as source of time base, but user can eventually implement his proper time base source (a general purpose timer for example or other time source)</li>
  1559. <li>Functions affecting time base configurations are declared as __Weak to make override possible in case of other implementations in user file, for more details please refer to HAL_TimeBase example</li>
  1560. </ul></li>
  1561. <li>Fix flag clear procedure: use atomic write operation “=” instead of ready-modify-write operation “|=” or “&amp;=”</li>
  1562. <li>Fix on Timeout management, Timeout value set to 0 passed to API automatically exits the function after checking the flag without any wait</li>
  1563. <li>Common update for the following communication peripherals: SPI, UART, USART and IRDA
  1564. <ul>
  1565. <li>Add DMA circular mode support</li>
  1566. <li>Remove lock from recursive process</li>
  1567. </ul></li>
  1568. <li>Add new macro __HAL_RESET_HANDLE_STATE to reset a given handle state</li>
  1569. <li>Add a new attribute for functions executed from internal SRAM and depending from Compiler implementation</li>
  1570. <li>When USE_RTOS == 1 (in stm32f2xx_hal_conf.h), the __HAL_LOCK() is not defined instead of being defined empty</li>
  1571. <li>Miscellaneous comments and formatting update</li>
  1572. <li>Update all macros and literals naming to be upper case</li>
  1573. <li>ErrorCode parameter in PPP_HandleTypeDef structure updated to uint32_t instead of enum HAL_PPP_ErrorTypeDef</li>
  1574. <li>Remove the unused FLAG and IT assert macros</li>
  1575. <li>stm32f2xx_hal_ppp.c
  1576. <ul>
  1577. <li>HAL_PPP_Init(): update to force the HAL_PPP_STATE_RESET before calling the HAL_PPP_MspInit()</li>
  1578. </ul></li>
  1579. <li>Important Note: aliases has been added for any API naming change, to keep compatibility with previous version</li>
  1580. </ul></li>
  1581. <li><strong>HAL ADC</strong> update
  1582. <ul>
  1583. <li>ADC HAL state machine update to use bit fields instead of enum:
  1584. <ul>
  1585. <li>HAL_ADC_StateTypeDef enum fields are replaced by respective defines</li>
  1586. </ul></li>
  1587. <li>Add new literal: ADC_SOFTWARE_START to be used as possible value for the ExternalTrigConv parameter in the ADC_InitTypeDef structure to select the ADC software trigger mode.</li>
  1588. <li>IS_ADC_CHANNEL() macro update to don’t assert stop the ADC_CHANNEL_TEMPSENSOR value</li>
  1589. <li>HAL_ADC_PollForConversion(): update to manage particular case when ADC configured in DMA mode and ADC sequencer with several ranks and polling for end of each conversion</li>
  1590. <li>HAL_ADC_Start()/HAL_ADC_Start_IT() /HAL_ADC_Start_DMA() update:
  1591. <ul>
  1592. <li>unlock the process before starting the ADC software conversion.</li>
  1593. <li>Optimize the ADC stabilization delays</li>
  1594. </ul></li>
  1595. <li>__HAL_ADC_GET_IT_SOURCE() update macro implementation</li>
  1596. <li>Add more details in ‘How to use this driver’ section</li>
  1597. <li>Add new literal: ADC_INJECTED_SOFTWARE_START to be used as possible value for the ExternalTrigInjecConvEdge parameter in the ADC_InitTypeDef structure to select the ADC software trigger mode.</li>
  1598. </ul></li>
  1599. <li><strong>HAL DAC</strong> update
  1600. <ul>
  1601. <li>Enhance the DMA channelconfiguration when used with DAC</li>
  1602. <li>HAL_DAC_ConfigChannel(): update the access to the DAC peripheral registers via the hdac handle instance</li>
  1603. <li>HAL_DAC_IRQHandler(): update to check on both DAC_FLAG_DMAUDR1 and DAC_FLAG_DMAUDR2</li>
  1604. <li>HAL_DACEx_NoiseWaveGenerate(): update to reset DAC CR register before setting the new DAC configuration</li>
  1605. <li>HAL_DACEx_TriangleWaveGenerate(): update to reset DAC CR register before setting the new DAC configuration</li>
  1606. <li>Add new macro to check if the specified DAC interrupt source is enabled or disabled
  1607. <ul>
  1608. <li>__HAL_DAC_GET_IT_SOURCE()</li>
  1609. </ul></li>
  1610. <li>HAL_DACEx_TriangleWaveGeneration() update to use DAC CR bit mask definition</li>
  1611. <li>HAL_DACEx_NoiseWaveGeneration() update to use DAC CR bit mask definition</li>
  1612. </ul></li>
  1613. <li><strong>HAL CAN</strong> update
  1614. <ul>
  1615. <li>Unlock the CAN process when communication error occurred</li>
  1616. <li>CanTxMsgTypeDef structure: update to use uint8_t Data[8] instead of uint32_t Data[8]</li>
  1617. <li>CanRxMsgTypeDef structure: update to use uint8_t Data[8] instead of uint32_t Data[8]</li>
  1618. </ul></li>
  1619. <li><strong>HAL CORTEX</strong> update
  1620. <ul>
  1621. <li>Add new macro IS_NVIC_DEVICE_IRQ() to check on negative values of IRQn parameter</li>
  1622. <li>Add specific API for MPU management
  1623. <ul>
  1624. <li>add MPU_Region_InitTypeDef structure</li>
  1625. <li>add new function HAL_MPU_ConfigRegion()</li>
  1626. </ul></li>
  1627. </ul></li>
  1628. <li><strong>HAL CRYP</strong> update
  1629. <ul>
  1630. <li>HAL_CRYP_DESECB_Decrypt_DMA(): fix the inverted pPlainData and pCypherData parameters issue</li>
  1631. <li>Add restriction for the CCM Encrypt/Decrypt API’s that only DataType equal to 8bits is supported</li>
  1632. <li>Update to manage multi instance:
  1633. <ul>
  1634. <li>Add new parameter Instance in the CRYP_HandleTypeDef Handle structure.</li>
  1635. <li>Add new parameter in all HAL CRYP macros
  1636. <ul>
  1637. <li>example: __HAL_CRYP_ENABLE() updated by __HAL_CRYP_ENABLE(<strong>HANDLE</strong>)</li>
  1638. </ul></li>
  1639. </ul></li>
  1640. </ul></li>
  1641. <li><strong>HAL DCMI</strong> update
  1642. <ul>
  1643. <li>HAL_DCMI_ConfigCROP(): Invert assert macros to check Y0 and Ysize parameters</li>
  1644. </ul></li>
  1645. <li><strong>HAL DMA</strong> update
  1646. <ul>
  1647. <li>Overall driver update for code optimization</li>
  1648. <li>add StreamBaseAddress and StreamIndex new fields in the DMA_HandleTypeDef structure</li>
  1649. <li>add DMA_Base_Registers private structure</li>
  1650. <li>add static function DMA_CalcBaseAndBitshift()
  1651. <ul>
  1652. <li>update HAL_DMA_Init() function to use the new added static function</li>
  1653. <li>update HAL_DMA_DeInit() function to optimize clear flag operations</li>
  1654. <li>update HAL_DMA_Start_IT() function to optimize interrupts enable</li>
  1655. <li>update HAL_DMA_PollForTransfer() function to optimize check on flags</li>
  1656. <li>update HAL_DMA_IRQHandler() function to optimize interrupt flag management</li>
  1657. </ul></li>
  1658. <li>Fix in HAL_DMA_PollForTransfer() to:
  1659. <ul>
  1660. <li>set DMA error code in case of HAL_ERROR status</li>
  1661. <li>set HAL Unlock before DMA state update</li>
  1662. </ul></li>
  1663. <li>HAL_DMA_Init(): Update to clear the DBM bit in the SxCR register before setting the new configuration</li>
  1664. <li>DMA_SetConfig(): add to clear the DBM bit in the SxCR register</li>
  1665. </ul></li>
  1666. <li><strong>HAL FLASH</strong> update
  1667. <ul>
  1668. <li>update HAL_FLASH_Program_IT() function by removing the pending flag clear</li>
  1669. <li>update HAL_FLASH_IRQHandler() function to improve erase operation procedure</li>
  1670. <li>update FLASH_WaitForLastOperation() function by checking on end of operation flag</li>
  1671. <li>Add “HAL_” prefix in the defined values for the FLASH error code</li>
  1672. <li>Example: FLASH_ERROR_PGP renamed by <strong>HAL</strong>_FLASH_ERROR_PGP</li>
  1673. <li>Clear the Flash ErrorCode in the FLASH_WaitForLastOperation() function</li>
  1674. <li>Update FLASH_SetErrorCode() function to use “|=” operant to update the Flash ErrorCode parameter in the FLASH handle</li>
  1675. <li>IS_FLASH_ADDRESS(): Update the macro check using ‘&lt;=’ condition instead of ‘&lt;’</li>
  1676. <li>IS_OPTIONBYTE(): Update the macro check using ‘&lt;=’ condition instead of ‘&lt;’</li>
  1677. <li>Add “FLASH_” prefix in the defined values of FLASH Type Program parameter</li>
  1678. <li>Example: TYPEPROGRAM_BYTE renamed by <strong>FLASH</strong>_TYPEPROGRAM_BYTE</li>
  1679. <li>Add “FLASH_” prefix in the defined values of FLASH Type Erase parameter</li>
  1680. <li>Example: TYPEERASE_SECTORS renamed by <strong>FLASH</strong>_TYPEERASE_SECTORS</li>
  1681. <li>Add “FLASH_” prefix in the defined values of FLASH Voltage Range parameter</li>
  1682. <li>Example: VOLTAGE_RANGE_1 renamed by <strong>FLASH</strong>_VOLTAGE_RANGE_1</li>
  1683. <li>Add “OB_” prefix in the defined values of FLASH WRP State parameter</li>
  1684. <li>Example: WRPSTATE_ENABLE renamed by <strong>OB</strong>_WRPSTATE_ENABLE</li>
  1685. <li>__HAL_FLASH_INSTRUCTION_CACHE_RESET() macro: update to reset ICRST bit in the ACR register after setting it.</li>
  1686. <li>__HAL_FLASH_DATA_CACHE_RESET() macro: update to reset DCRST bit in the ACR register after setting it.</li>
  1687. <li>FLASH_OB_GetRDP() API update to return uint8_t instead of FlagStatus</li>
  1688. <li>__HAL_FLASH_GET_LATENCY() new macro add to get the flash latency</li>
  1689. </ul></li>
  1690. <li><strong>HAL ETH</strong> update
  1691. <ul>
  1692. <li>Update HAL_ETH_GetReceivedFrame_IT() function to return HAL_ERROR if the received packet is not complete</li>
  1693. <li>Use HAL_Delay() instead of counting loop</li>
  1694. <li>__HAL_ETH_MAC_CLEAR_FLAG() macro is removed: the MACSR register is read only</li>
  1695. <li>Add the following macros used toWake up the device from STOP mode by Ethernet event :
  1696. <ul>
  1697. <li>__HAL_ETH_WAKEUP_EXTI_ENABLE_IT()</li>
  1698. <li>__HAL_ETH_WAKEUP_EXTI_DISABLE_IT()</li>
  1699. <li>__HAL_ETH_WAKEUP_EXTI_GET_FLAG()</li>
  1700. <li>__HAL_ETH_WAKEUP_EXTI_CLEAR_FLAG()</li>
  1701. <li>__HAL_ETH_WAKEUP_EXTI_ENABLE_RISING_EGDE_TRIGGER()</li>
  1702. <li>__HAL_ETH_WAKE_EXTI_ENABLE_FALLING_EGDE_TRIGGER()</li>
  1703. <li>__HAL_ETH_WAKE_EXTI_ENABLE_FALLINGRISING_TRIGGER()</li>
  1704. </ul></li>
  1705. <li>Rename literals
  1706. <ul>
  1707. <li>ETH_PROMISCIOUSMODE_ENABLE by ETH_PROMISCUOUS_MODE_ENABLE</li>
  1708. <li>ETH_PROMISCIOUSMODE_DISABLE by ETH_PROMISCUOUS_MODE_DISABLE</li>
  1709. </ul></li>
  1710. <li>Remove illegal space ETH_MAC_READCONTROLLER_FLUSHING macro</li>
  1711. <li>Update ETH_MAC_READCONTROLLER_XXX defined values (XXX can be IDLE, READING_DATA and READING_STATUS)</li>
  1712. </ul></li>
  1713. <li><strong>HAL PWR</strong> update
  1714. <ul>
  1715. <li>HAL_PWR_ConfigPVD(): add clear of the EXTI trigger before new configuration</li>
  1716. <li>Fix in HAL_PWR_EnterSTANDBYMode() to not clear Wakeup flag (WUF), which need to be cleared at application level before to call this function</li>
  1717. <li>HAL_PWR_EnterSLEEPMode()
  1718. <ul>
  1719. <li>Remove disable and enable of SysTick Timer</li>
  1720. <li>Update to clear SLEEPDEEP bit of Cortex System Control Register (SCB-&gt;SCR) before entering in sleep mode</li>
  1721. <li>Update usage of __WFE() in low power entry function: if there is a pending event, calling __WFE() will not enter the CortexM3 core to sleep mode. The solution is to made the call below; the first __WFE() is always ignored and clears the event if one was already pending, the second is always applied
  1722. <ul>
  1723. <li>__SEV()</li>
  1724. <li>__WFE()</li>
  1725. <li>__WFE()</li>
  1726. </ul></li>
  1727. </ul></li>
  1728. <li>Add new macro for software event generation __HAL_PWR_PVD_EXTI_GENERATE_SWIT()</li>
  1729. <li>Remove the following defines form Generic driver and add them under extension driver because they are only used within extension functions.</li>
  1730. <li>CR_FPDS_BB: used within HAL_PWREx_EnableFlashPowerDown() function</li>
  1731. <li>CSR_BRE_BB: used within HAL_PWREx_EnableBkUpReg() function</li>
  1732. <li>Add new API to manage SLEEPONEXIT and SEVONPEND bits of SCR register
  1733. <ul>
  1734. <li>HAL_PWR_DisableSleepOnExit()</li>
  1735. <li>HAL_PWR_EnableSleepOnExit()</li>
  1736. <li>HAL_PWR_EnableSEVOnPend()</li>
  1737. <li>HAL_PWR_DisableSEVOnPend()</li>
  1738. </ul></li>
  1739. <li>HAL_PWR_EnterSLEEPMode()
  1740. <ul>
  1741. <li>Update to clear the CORTEX SLEEPDEEP bit of SCR register before entering in sleep mode</li>
  1742. </ul></li>
  1743. <li>Add new PVD configuration modes
  1744. <ul>
  1745. <li>PWR_PVD_MODE_NORMAL</li>
  1746. <li>PWR_PVD_MODE_EVENT_RISING</li>
  1747. <li>PWR_PVD_MODE_EVENT_FALLING</li>
  1748. <li>PWR_PVD_MODE_EVENT_RISING_FALLING</li>
  1749. </ul></li>
  1750. <li>Add new macros to manage PVD Trigger
  1751. <ul>
  1752. <li>__HAL_PWR_PVD_EXTI_ENABLE_RISING_EDGE()</li>
  1753. <li>__HAL_PWR_PVD_EXTI_DISABLE_RISING_EDGE(</li>
  1754. <li>__HAL_PWR_PVD_EXTI_ENABLE_FALLING_EDGE()</li>
  1755. <li>__HAL_PWR_PVD_EXTI_DISABLE_FALLING_EDGE()</li>
  1756. <li>__HAL_PWR_PVD_EXTI_ENABLE_RISING_FALLING_EDGE()</li>
  1757. <li>__HAL_PWR_PVD_EXTI_DISABLE_RISING_FALLING_EDGE()</li>
  1758. </ul></li>
  1759. <li>PVD macros:
  1760. <ul>
  1761. <li>Remove the <strong>EXTILINE</strong> parameter</li>
  1762. <li>Update to use prefix "__HAL_PWR_PVD_" instead of prefix "__HAL_PVD"</li>
  1763. </ul></li>
  1764. <li>Rename HAL_PWR_PVDConfig() function by HAL_PWR_ConfigPVD()</li>
  1765. </ul></li>
  1766. <li><strong>HAL GPIO</strong> update
  1767. <ul>
  1768. <li>Rename GPIO_SPEED_LOW define to GPIO_SPEED_FREQ_LOW</li>
  1769. <li>Rename GPIO_SPEED_MEDIUM define to GPIO_SPEED_FREQ_MEDIUM</li>
  1770. <li>Rename GPIO_SPEED_FAST define to GPIO_SPEED_FREQ_HIGH</li>
  1771. <li>Rename GPIO_SPEED_HIGH define to GPIO_SPEED_FREQ_VERY_HIGH</li>
  1772. <li>Add a new macro __HAL_GPIO_EXTI_GENERATE_SWIT() to manage the generation of software interrupton selected EXTI line</li>
  1773. <li>HAL_GPIO_Init(): use temporary variable when modifying the registers, to avoid unexpected transition in the GPIO pin configuration</li>
  1774. <li>Remove IS_GET_GPIO_PIN macro</li>
  1775. <li>Add a new function HAL_GPIO_LockPin()</li>
  1776. <li>Update the following HAL GPIO macros description: rename EXTI_Linex by GPIO_PIN_x
  1777. <ul>
  1778. <li>__HAL_GPIO_EXTI_CLEAR_IT()</li>
  1779. <li>__HAL_GPIO_EXTI_GET_IT()</li>
  1780. <li>__HAL_GPIO_EXTI_CLEAR_FLAG()</li>
  1781. <li>__HAL_GPIO_EXTI_GET_FLAG()</li>
  1782. </ul></li>
  1783. <li>HAL_GPIO_Init()/HAL_GPIO_DeInit(): add a call to the CMSIS assert macro to check GPIO instance: IS_GPIO_ALL_INSTANCE()</li>
  1784. <li>Rename __HAL_GET_GPIO_SOURCE() by GPIO_GET_INDEX() and move this later to file stm32f2xx_hal_gpio_ex.h</li>
  1785. <li>HAL_GPIO_DeInit(): Update to check if GPIO Pin x is already used in EXTI mode on another GPIO Port before De-Initialize the EXTI registers</li>
  1786. </ul></li>
  1787. <li><strong>HAL HASH</strong> update
  1788. <ul>
  1789. <li>HAL_HASH_MD5_Start_IT(): fix input address management issue</li>
  1790. <li>HAL_HASH_<strong>MODE</strong>_Start_IT() (<strong>MODE</strong> stands for MD5 and SHA1) updates:
  1791. <ul>
  1792. <li>Fix processing fail for small input buffers</li>
  1793. <li>Update to unlock the process and call return HAL_OK at the end of HASH processing to avoid incorrectly repeating software</li>
  1794. <li>Update to properly manage the HashITCounter</li>
  1795. <li>Update to call the HAL_HASH_InCpltCallback() at the end of the complete buffer instead of every each 512 bits</li>
  1796. </ul></li>
  1797. <li>__HAL_HASH_GET_FLAG() update to check the right register when the DINNE flag is selected</li>
  1798. <li>HAL_HASH_SHA1_Accumulate() updates:
  1799. <ul>
  1800. <li>Add a call to the new IS_HASH_SHA1_BUFFER_SIZE() macro to check the size parameter.</li>
  1801. <li>Add the following note in API description
  1802. <ul>
  1803. <li><ul>
  1804. <li><span class="citation" data-cites="note">@note</span> Input buffer size in bytes must be a multiple of 4 otherwise the digest computation is corrupted.</li>
  1805. </ul></li>
  1806. </ul></li>
  1807. </ul></li>
  1808. </ul></li>
  1809. <li><strong>HAL RCC</strong> update
  1810. <ul>
  1811. <li>HAL_RCCEx_PeriphCLKConfig() updates:
  1812. <ul>
  1813. <li>Update the LSE check condition after backup domain reset: update to check LSE ready flag when LSE oscillator is already enabled instead of check on LSE oscillator only when LSE is used as RTC clock source</li>
  1814. </ul></li>
  1815. <li>In HAL_RCC_ClockConfig()function: update the AHB clock divider before clock switch to new source</li>
  1816. <li>Allow to calibrate the HSI when it is used as system clock source</li>
  1817. <li>Reorganize the RCC macros to make them more clear</li>
  1818. <li>Rename the following Macros
  1819. <ul>
  1820. <li>__PPP_CLK_ENABLE() by __HAL_RCC_PPP_CLK_ENABLE()</li>
  1821. <li>__PPP_CLK_DISABLE() by __HAL_RCC_PPP_CLK_DISABLE()</li>
  1822. <li>__PPP_FORCE_RESET() by __HAL_RCC_PPP_FORCE_RESET()</li>
  1823. <li>__PPP_RELEASE_RESET() by __HAL_RCC_PPP_RELEASE_RESET()</li>
  1824. <li>__PPP_CLK_SLEEP_ENABLE() by __HAL_RCC_PPP_CLK_SLEEP_ENABLE()</li>
  1825. <li>__PPP_CLK_SLEEP_DISABLE() by __HAL_RCC_PPP_CLK_SLEEP_DISABLE()</li>
  1826. </ul></li>
  1827. <li>Add description of RCC known Limitations</li>
  1828. <li>HAL_RCC_OscConfig() fix issues:
  1829. <ul>
  1830. <li>Remove the disable of HSE oscillator when HSE_BYPASS is used as system clock source or as PPL clock source</li>
  1831. <li>Add a check on HSERDY flag when HSE_BYPASS is selected as new state for HSE oscillator.</li>
  1832. </ul></li>
  1833. <li>Rename __HAL_RCC_I2SCLK() by __HAL_RCC_I2S_Config()</li>
  1834. <li>__HAL_RCC_PPP_CLK_ENABLE(): Implement workaround to cover RCC limitation regarding peripheral enable delay</li>
  1835. <li>HAL_RCC_OscConfig() fix issues:
  1836. <ul>
  1837. <li>Add a check on LSERDY flag when LSE_BYPASS is selected as new state for LSE oscillator.</li>
  1838. </ul></li>
  1839. <li>__HAL_RCC_HSE_CONFIG() macro: add the comment below:
  1840. <ul>
  1841. <li><ul>
  1842. <li><span class="citation" data-cites="note">@note</span> Transition HSE Bypass to HSE On and HSE On to HSE Bypass are not supported by this macro.</li>
  1843. </ul></li>
  1844. <li><ul>
  1845. <li>User should request a transition to HSE Off first and then HSE On or HSE Bypass.</li>
  1846. </ul></li>
  1847. </ul></li>
  1848. <li>__HAL_RCC_LSE_CONFIG() macro: add the comment below:
  1849. <ul>
  1850. <li><ul>
  1851. <li><span class="citation" data-cites="note">@note</span> Transition LSE Bypass to LSE On and LSE On to LSE Bypass are not supported by this macro.</li>
  1852. </ul></li>
  1853. <li><ul>
  1854. <li>User should request a transition to LSE Off first and then LSE On or LSE Bypass.</li>
  1855. </ul></li>
  1856. </ul></li>
  1857. <li>Add the following new macros for PLL source and PLLM selection :
  1858. <ul>
  1859. <li>__HAL_RCC_PLL_PLLSOURCE_CONFIG()</li>
  1860. <li>__HAL_RCC_PLL_PLLM_CONFIG()</li>
  1861. </ul></li>
  1862. <li>Add __HAL_RCC_SYSCLK_CONFIG() new macro to configure the system clock source (SYSCLK)</li>
  1863. <li>__HAL_RCC_GET_SYSCLK_SOURCE() updates:</li>
  1864. <li>Add new RCC Literals:
  1865. <ul>
  1866. <li>RCC_SYSCLKSOURCE_STATUS_HSI</li>
  1867. <li>RCC_SYSCLKSOURCE_STATUS_HSE</li>
  1868. <li>RCC_SYSCLKSOURCE_STATUS_PLLCLK</li>
  1869. </ul></li>
  1870. <li>Update macro description to refer to the literals above</li>
  1871. </ul></li>
  1872. <li><strong>HAL I2S</strong> update
  1873. <ul>
  1874. <li>HAL_I2S_Init(): add check on I2S instance using CMSIS macro IS_I2S_ALL_INSTANCE()</li>
  1875. <li>HAL_I2S_IRQHandler() update for compliance with C++</li>
  1876. <li>Add use of tmpreg variable in __HAL_I2S_CLEAR_OVRFLAG() and __HAL_I2S_CLEAR_UDRFLAG() macro for compliance with C++</li>
  1877. <li>HAL_I2S_GetError(): update to return uint32_t instead of HAL_I2S_ErrorTypeDef enumeration</li>
  1878. <li>HAL_I2S_Transmit() API update to check on busy flag only for I2S slave mode</li>
  1879. </ul></li>
  1880. <li><strong>HAL I2C</strong> update
  1881. <ul>
  1882. <li>I2C Polling/IT/DMA processes: move the wait loop on busy flag at the top of the processes, to ensure that software not perform any write access to I2C_CR1 register before hardware clearing STOP bit and to avoid also the waiting loop on BUSY flag under I2C/DMA ISR.</li>
  1883. <li>Update busy flag Timeout value</li>
  1884. <li>I2C Master Receive Processes update to disable ACK before generate the STOP</li>
  1885. <li>Update to clear the POS bit in the CR1 register at the begging of all the HAL I2C processes</li>
  1886. <li>Add use of tmpreg variable in __HAL_I2C_CLEAR_ADDRFLAG() and __HAL_I2C_CLEAR_STOPFLAG() macro for compliance with C++</li>
  1887. </ul></li>
  1888. <li><strong>HAL IrDA</strong> update
  1889. <ul>
  1890. <li>Add specific macros to manage the flags cleared only by a software sequence ◾__HAL_IRDA_CLEAR_PEFLAG()
  1891. <ul>
  1892. <li>__HAL_ IRDA _CLEAR_FEFLAG()</li>
  1893. <li>__HAL_ IRDA _CLEAR_NEFLAG()</li>
  1894. <li>__HAL_ IRDA _CLEAR_OREFLAG()</li>
  1895. <li>__HAL_ IRDA _CLEAR_IDLEFLAG()</li>
  1896. </ul></li>
  1897. <li>Add several enhancements without affecting the driver functionalities
  1898. <ul>
  1899. <li>Remove the check on RXNE set after reading the Data in the DR register</li>
  1900. <li>Update HAL_IRDA_Transmit_IT() to enable IRDA_IT_TXE instead of IRDA_IT_TC</li>
  1901. </ul></li>
  1902. <li>Add the following APIs used within DMA process ◾HAL_StatusTypeDef HAL_IRDA_DMAPause(IRDA_HandleTypeDef *hirda);
  1903. <ul>
  1904. <li>HAL_StatusTypeDef HAL_IRDA_DMAResume(IRDA_HandleTypeDef *hirda);</li>
  1905. <li>HAL_StatusTypeDef HAL_IRDA_DMAStop(IRDA_HandleTypeDef *hirda);<br />
  1906. </li>
  1907. <li>void HAL_IRDA_TxHalfCpltCallback(IRDA_HandleTypeDef *hirda);</li>
  1908. <li>void HAL_IRDA_RxHalfCpltCallback(IRDA_HandleTypeDef *hirda);</li>
  1909. </ul></li>
  1910. <li>DMA transmit process; the code has been updated to avoid waiting on TC flag under DMA ISR, IrDA TC interrupt is used instead. Below the update to be done on user application:
  1911. <ul>
  1912. <li>Configure and enable the USART IRQ in HAL_IRDA_MspInit() function</li>
  1913. <li>In stm32f2xx_it.c file, UASRTx_IRQHandler() function: add a call to HAL_IRDA_IRQHandler() function</li>
  1914. </ul></li>
  1915. <li>IT transmit process; the code has been updated to avoid waiting on TC flag under IRDA ISR, IrDA TC interrupt is used instead. No impact on user application</li>
  1916. <li>Rename Macros: add prefix "__HAL"
  1917. <ul>
  1918. <li>__IRDA_ENABLE() by __HAL_IRDA_ENABLE()</li>
  1919. <li>__IRDA_DISABLE() by __HAL_IRDA_DISABLE()</li>
  1920. </ul></li>
  1921. <li>Add new user macros to manage the sample method feature
  1922. <ul>
  1923. <li>__HAL_IRDA_ONE_BIT_SAMPLE_ENABLE()</li>
  1924. <li>__HAL_IRDA_ONE_BIT_SAMPLE_DISABLE()</li>
  1925. </ul></li>
  1926. <li>HAL_IRDA_Transmit_IT(): update to remove the enable of the parity error interrupt</li>
  1927. <li>Add use of tmpreg variable in __HAL_IRDA_CLEAR_PEFLAG() macro for compliance with C++</li>
  1928. <li>HAL_IRDA_Transmit_DMA() update to follow the right procedure “Transmission using DMA” in the reference manual
  1929. <ul>
  1930. <li>Add clear the TC flag in the SR register before enabling the DMA transmit request</li>
  1931. </ul></li>
  1932. </ul></li>
  1933. <li><strong>HAL SPI</strong> update
  1934. <ul>
  1935. <li>SPI interface is used in synchronous polling mode: at high clock rates like SPI prescaler 2 and 4, calling</li>
  1936. <li>AL_SPI_TransmitReceive() returns with error HAL_TIMEOUT</li>
  1937. <li>HAL_SPI_TransmitReceive_DMA() does not clean up the TX DMA, so any subsequent SPI calls return the DMA error</li>
  1938. <li>HAL_SPI_Transmit_DMA() is failing when data size is equal to 1 byte</li>
  1939. <li>Add the following APIs used within the DMA process
  1940. <ul>
  1941. <li>HAL_StatusTypeDef HAL_SPI_DMAPause(SPI_HandleTypeDef *hspi);</li>
  1942. <li>HAL_StatusTypeDef HAL_SPI_DMAResume(SPI_HandleTypeDef *hspi);</li>
  1943. <li>HAL_StatusTypeDef HAL_SPI_DMAStop(SPI_HandleTypeDef *hspi);</li>
  1944. <li>void HAL_SPI_TxHalfCpltCallback(SPI_HandleTypeDef *hspi);</li>
  1945. <li>void HAL_SPI_RxHalfCpltCallback(SPI_HandleTypeDef *hspi);</li>
  1946. <li>void HAL_SPI_TxRxHalfCpltCallback(SPI_HandleTypeDef *hspi);</li>
  1947. </ul></li>
  1948. <li>HAL_SPI_TransmitReceive_DMA() update to remove the DMA Tx Error Callback initialization when SPI RxOnly mode is selected</li>
  1949. <li>Add use of UNUSED(tmpreg) in __HAL_SPI_CLEAR_MODFFLAG(), __HAL_SPI_CLEAR_OVRFLAG(), __HAL_SPI_CLEAR_FREFLAG() to fix “Unused variable” warning with TrueSTUDIO.</li>
  1950. <li>Rename Literals: remove “D” from “DISABLED” and “ENABLED”
  1951. <ul>
  1952. <li>SPI_TIMODE_DISABLE<strong>D</strong> by SPI_TIMODE_DISABLE</li>
  1953. <li>SPI_TIMODE_ENABLE<strong>D</strong> by SPI_TIMODE_ENABLE</li>
  1954. <li>SPI_CRCCALCULATION_DISABLE<strong>D</strong> by SPI_CRCCALCULATION_DISABLE</li>
  1955. <li>SPI_CRCCALCULATION_ENABLE<strong>D</strong> by SPI_CRCCALCULATION_ENABLE</li>
  1956. </ul></li>
  1957. <li>Add use of tmpreg variable in __HAL_SPI_CLEAR_MODFFLAG(), __HAL_SPI_CLEAR_FREFLAG() and __HAL_SPI_CLEAR_OVRFLAG() macros for compliance with C++</li>
  1958. <li>HAL_SPI_Transmit_DMA()/HAL_SPI_Receive_DMA()/HAL_SPI_TransmitReceive_DMA() update to unlock the process before enabling the SPI peripheral</li>
  1959. <li>HAL_SPI_Transmit_DMA() update to manage correctly the DMA TX stream in SPI Full duplex mode</li>
  1960. <li>Section SPI_Exported_Functions_Group2 update to remove duplication in *.chm UM</li>
  1961. <li>Fix the wrong definition of HAL_SPI_ERROR_FLAG literal</li>
  1962. </ul></li>
  1963. <li><strong>HAL CRC</strong> update
  1964. <ul>
  1965. <li>These macros are added to read/write the CRC IDR register: __HAL_CRC_SET_IDR() and __HAL_CRC_GET_IDR()</li>
  1966. </ul></li>
  1967. <li>__HAL_CRC_SET_IDR() macro implementation change to use WRITE_REG() instead of MODIFY_REG()</li>
  1968. <li><strong>HAL LL SDMMC</strong> update
  1969. <ul>
  1970. <li>Use of CMSIS constants instead of magic values</li>
  1971. <li>Miscellaneous update in functions internal coding</li>
  1972. <li>IS_SDIO_ALL_INSTANCE() macro moved to CMSIS files</li>
  1973. </ul></li>
  1974. <li><strong>HAL NAND</strong> update
  1975. <ul>
  1976. <li>Fix issue of macros returning wrong address for NAND blocks</li>
  1977. <li>Fix issue for read/write NAND page/spare area</li>
  1978. <li>Rename NAND Address structure to NAND_AddressTypeDef instead of NAND_AddressTypedef</li>
  1979. <li>Update the used algorithm of these functions
  1980. <ul>
  1981. <li>HAL_NAND_Read_Page()</li>
  1982. <li>HAL_NAND_Write_Page()</li>
  1983. <li>HAL_NAND_Read_SpareArea()</li>
  1984. <li>HAL_NAND_Write_SpareArea()</li>
  1985. </ul></li>
  1986. <li>HAL_NAND_Write_Page(): move initialization of tickstart before while loop</li>
  1987. <li>HAL_NAND_Erase_Block(): add whait until NAND status is ready before exiting this function</li>
  1988. </ul></li>
  1989. <li><strong>HAL NOR</strong> update
  1990. <ul>
  1991. <li>Add the NOR addressbank macro used within the API</li>
  1992. <li>Update NOR APIimplementation to avoid the use of NOR address bank hard coded</li>
  1993. <li>NOR Status literals renamed
  1994. <ul>
  1995. <li>NOR_SUCCESS by HAL_NOR_STATUS_SUCCESS</li>
  1996. <li>NOR_ONGOING by HAL_NOR_STATUS_ONGOING</li>
  1997. <li>NOR_ERROR by HAL_NOR_STATUS_ERROR</li>
  1998. <li>NOR_TIMEOUT by HAL_NOR_STATUS_TIMEOUT</li>
  1999. </ul></li>
  2000. <li>HAL_NOR_GetStatus() update to fix Timeout issue and exit from waiting loop when timeout occurred</li>
  2001. </ul></li>
  2002. <li><strong>HAL PCCARD</strong> update</li>
  2003. <li>Rename PCCARD Address structure to HAL_PCCARD_StatusTypeDef instead of CF_StatusTypedef</li>
  2004. <li>PCCARD Status literals renamed
  2005. <ul>
  2006. <li>CF_SUCCESS by HAL_PCCARD_STATUS_SUCCESS</li>
  2007. <li>CF_ONGOING by HAL_PCCARD_STATUS_ONGOING</li>
  2008. <li>CF_ERROR by HAL_PCCARD_STATUS_ERROR</li>
  2009. <li>CF_TIMEOUT by HAL_PCCARD_STATUS_TIMEOUT</li>
  2010. </ul></li>
  2011. <li>Update “CF” by “PCCARD” in functions, literals and macros</li>
  2012. <li><strong>HAL HCD</strong> update
  2013. <ul>
  2014. <li>HCD_StateTypeDef structure members renamed</li>
  2015. <li>These macro are renamed
  2016. <ul>
  2017. <li>__HAL_GET_FLAG(<strong>HANDLE</strong>, <strong>INTERRUPT</strong>) by __HAL_HCD_GET_FLAG(<strong>HANDLE</strong>, <strong>INTERRUPT</strong>)</li>
  2018. <li>__HAL_IS_INVALID_INTERRUPT(<strong>HANDLE</strong>) by __HAL_HCD_IS_INVALID_INTERRUPT(<strong>HANDLE</strong>)</li>
  2019. </ul></li>
  2020. <li>Update to use local variable in USB Host channel re-activation</li>
  2021. </ul></li>
  2022. <li><strong>HAL PCD</strong> update
  2023. <ul>
  2024. <li>HAL_PCD_SetTxFiFo() and HAL_PCD_SetRxFiFo() renamed into HAL_PCDEx_SetTxFiFo() and HAL_PCDEx_SetRxFiFo() and moved to the extension files stm32f2xx_hal_pcd_ex.h/.c</li>
  2025. <li>PCD_StateTypeDef structure members renamed</li>
  2026. <li>Fix incorrect masking of TxFIFOEmpty</li>
  2027. <li>stm32f2xx_ll_usb.c: fix issue in HS mode</li>
  2028. <li>New macros added
  2029. <ul>
  2030. <li>__HAL_PCD_IS_PHY_SUSPENDED()</li>
  2031. <li>__HAL_USB_HS_EXTI_GENERATE_SWIT()</li>
  2032. <li>__HAL_USB_FS_EXTI_GENERATE_SWIT()</li>
  2033. </ul></li>
  2034. <li>These macro are renamed
  2035. <ul>
  2036. <li>__HAL_GET_FLAG(<strong>HANDLE</strong>, <strong>INTERRUPT</strong>) by __HAL_PCD_GET_FLAG(<strong>HANDLE</strong>, <strong>INTERRUPT</strong>)</li>
  2037. <li>__HAL_CLEAR_FLAG(<strong>HANDLE</strong>, <strong>INTERRUPT</strong>) by __HAL_PCD_CLEAR_FLAG(<strong>HANDLE</strong>, <strong>INTERRUPT</strong>)<br />
  2038. </li>
  2039. <li>__HAL_IS_INVALID_INTERRUPT(<strong>HANDLE</strong>) by __HAL_PCD_IS_INVALID_INTERRUPT(<strong>HANDLE</strong>)<br />
  2040. </li>
  2041. <li>__HAL_PCD_UNGATE_CLOCK(<strong>HANDLE</strong>) by __HAL_PCD_UNGATE_PHYCLOCK(<strong>HANDLE</strong>)</li>
  2042. <li>__HAL_PCD_GATE_CLOCK(<strong>HANDLE</strong>) by __HAL_PCD_GATE_PHYCLOCK(<strong>HANDLE</strong>)</li>
  2043. </ul></li>
  2044. <li>Rename functions
  2045. <ul>
  2046. <li>HAL_PCD_<strong>Active</strong>RemoteWakeup() by HAL_PCD_<strong>Activate</strong>RemoteWakeup()</li>
  2047. <li>HAL_PCD_<strong>DeActive</strong>RemoteWakeup() by HAL_PCD_<strong>DeActivate</strong>RemoteWakeup()</li>
  2048. </ul></li>
  2049. <li>Rename literals
  2050. <ul>
  2051. <li>USB_FS_EXTI_TRIGGER_RISING_EDGE by USB_OTG_FS_WAKEUP_EXTI_RISING_EDGE</li>
  2052. <li>USB_FS_EXTI_TRIGGER_FALLING_EDGE by USB_OTG_FS_WAKEUP_EXTI_FALLING_EDGE</li>
  2053. <li>USB_FS_EXTI_TRIGGER_BOTH_EDGE() by USB_OTG_FS_WAKEUP_EXTI_RISING_FALLING_EDGE</li>
  2054. <li>USB_HS_EXTI_TRIGGER_RISING_EDGE by USB_OTG_HS_WAKEUP_EXTI_RISING_EDGE</li>
  2055. <li>USB_HS_EXTI_TRIGGER_FALLING_EDGE by USB_OTG_HS_WAKEUP_EXTI_FALLING_EDGE</li>
  2056. <li>USB_HS_EXTI_TRIGGER_BOTH_EDGE by USB_OTG_HS_WAKEUP_EXTI_RISING_FALLING_EDGE</li>
  2057. <li>USB_HS_EXTI_LINE_WAKEUP by USB_OTG_HS_WAKEUP_EXTI_LINE</li>
  2058. <li>USB_FS_EXTI_LINE_WAKEUP by USB_OTG_FS_WAKEUP_EXTI_LINE</li>
  2059. </ul></li>
  2060. <li>Rename USB EXTI macros (FS, HS referenced as <strong>SUBBLOCK</strong> here below)
  2061. <ul>
  2062. <li>__HAL_USB_<strong>SUBBLOCK</strong>_EXTI_ENABLE_IT() by __HAL_USB_OTG_<strong>SUBBLOCK</strong>_WAKEUP_EXTI_ENABLE_IT()<br />
  2063. </li>
  2064. <li>__HAL_USB_<strong>SUBBLOCK</strong>_EXTI_DISABLE_IT() by __HAL_USB_OTG_<strong>SUBBLOCK</strong>_WAKEUP_EXTI_DISABLE_IT()</li>
  2065. <li>__HAL_USB_<strong>SUBBLOCK</strong>_EXTI_GET_FLAG() by __HAL_USB_OTG_<strong>SUBBLOCK</strong>_WAKEUP_EXTI_GET_FLAG()</li>
  2066. <li>__HAL_USB_<strong>SUBBLOCK</strong>_EXTI_CLEAR_FLAG() by __HAL_USB_OTG_<strong>SUBBLOCK</strong>_WAKEUP_EXTI_CLEAR_FLAG()</li>
  2067. <li>__HAL_USB_<strong>SUBBLOCK</strong>_EXTI_SET_RISING_EGDE_TRIGGER() by __HAL_USB_OTG_<strong>SUBBLOCK</strong>_WAKEUP_EXTI_ENABLE_RISING_EDGE()</li>
  2068. <li>__HAL_USB_<strong>SUBBLOCK</strong>_EXTI_SET_FALLING_EGDE_TRIGGER() by __HAL_USB_OTG_<strong>SUBBLOCK</strong>_WAKEUP_EXTI_ENABLE_FALLING_EDGE()</li>
  2069. <li>__HAL_USB_<strong>SUBBLOCK</strong>_EXTI_SET_FALLINGRISING_TRIGGER() by __HAL_USB_OTG_<strong>SUBBLOCK</strong>_WAKEUP_EXTI_ENABLE_RISING_FALLING_EDGE()</li>
  2070. <li>__HAL_USB_<strong>SUBBLOCK</strong>_EXTI_GENERATE_SWIT() by __HAL_USB_OTG_SUBBLOCK_WAKEUP_EXTI_GENERATE_SWIT()</li>
  2071. </ul></li>
  2072. <li>HAL_PCD_IRQHandler API: fix the bad Configuration of Turnaround Time</li>
  2073. </ul></li>
  2074. <li><strong>HAL RNG</strong> update
  2075. <ul>
  2076. <li>Add new functions
  2077. <ul>
  2078. <li>HAL_RNG_GenerateRandomNumber(): to generate a 32-bits random number, return random value in argument and return HAL status.</li>
  2079. <li>HAL_RNG_GenerateRandomNumber_IT(): to start generation of the 32-bits random number, user should call the HAL_RNG_ReadLastRandomNumber() function under the HAL_RNG_ReadyCallback() to get the generated random value.</li>
  2080. <li>HAL_RNG_ReadLastRandomNumber(): to return the last random value stored in the RNG handle</li>
  2081. </ul></li>
  2082. <li>HAL_RNG_GetRandomNumber(): return value update (obsolete), replaced by HAL_RNG_GenerateRandomNumber()</li>
  2083. <li>HAL_RNG_GetRandomNumber_IT(): wrong implementation (obsolete), replaced by HAL_RNG_GenerateRandomNumber_IT()</li>
  2084. <li>__HAL_RNG_CLEAR_FLAG() macro (obsolete), replaced by new __HAL_RNG_CLEAR_IT() macro</li>
  2085. <li>Add new define for RNG ready interrupt: RNG_IT_DRDY</li>
  2086. </ul></li>
  2087. <li><strong>HAL RTC</strong> update
  2088. <ul>
  2089. <li>Update HAL_RTCEx_SetWakeUpTimer() and HAL_RTCEx_SetWakeUpTimer_IT() functions to properly check on the WUTWF flag</li>
  2090. <li>HAL_RTC_GetTime() and HAL_RTC_GetDate(): add the comment below</li>
  2091. <li><ul>
  2092. <li><span class="citation" data-cites="note">@note</span> You must call HAL_RTC_GetDate() after HAL_RTC_GetTime() to unlock the values</li>
  2093. </ul></li>
  2094. <li><ul>
  2095. <li>in the higher-order calendar shadow registers to ensure consistency between the time and date values.</li>
  2096. </ul></li>
  2097. <li><ul>
  2098. <li>Reading RTC current time locks the values in calendar shadow registers until Current date is read.</li>
  2099. </ul></li>
  2100. <li>Rename literals: add prefix "__HAL"
  2101. <ul>
  2102. <li>FORMAT_BIN by RTC_FORMAT_BIN</li>
  2103. <li>FORMAT_BCD by RTC_FORMAT_BCD</li>
  2104. </ul></li>
  2105. <li>Rename macros (ALARM, WAKEUPTIMER and TIMESTAMP referenced as <strong>SUBBLOCK</strong> here below)
  2106. <ul>
  2107. <li>__HAL_RTC_EXTI_ENABLE_IT() by __HAL_RTC_<strong>SUBBLOCK</strong>_EXTI_ENABLE_IT()</li>
  2108. <li>__HAL_RTC_EXTI_DISABLE_IT() by __HAL_RTC_<strong>SUBBLOCK</strong>_EXTI_DISABLE_IT()</li>
  2109. <li>__HAL_RTC_EXTI_CLEAR_FLAG() by __HAL_RTC_<strong>SUBBLOCK</strong>_EXTI_CLEAR_FLAG()</li>
  2110. <li>__HAL_RTC_EXTI_GENERATE_SWIT() by __HAL_RTC_<strong>SUBBLOCK</strong>_EXTI_GENERATE_SWIT()</li>
  2111. </ul></li>
  2112. <li>Add new macros (ALARM, WAKEUPTIMER and TAMPER_TIMESTAMP referenced as <strong>SUBBLOCK</strong> here below)
  2113. <ul>
  2114. <li>__HAL_RTC_<strong>SUBBLOCK</strong>_GET_IT_SOURCE()</li>
  2115. <li>__HAL_RTC_<strong>SUBBLOCK</strong>_EXTI_ENABLE_EVENT()</li>
  2116. <li>__HAL_RTC_<strong>SUBBLOCK</strong>_EXTI_DISABLE_EVENT()</li>
  2117. <li>__HAL_RTC_<strong>SUBBLOCK</strong>_EXTI_ENABLE_FALLING_EDGE()</li>
  2118. <li>__HAL_RTC_<strong>SUBBLOCK</strong>_EXTI_DISABLE_FALLING_EDGE()</li>
  2119. <li>__HAL_RTC_<strong>SUBBLOCK</strong>_EXTI_ENABLE_RISING_EDGE()</li>
  2120. <li>__HAL_RTC_<strong>SUBBLOCK</strong>_EXTI_DISABLE_RISING_EDGE()</li>
  2121. <li>__HAL_RTC_<strong>SUBBLOCK</strong>_EXTI_ENABLE_RISING_FALLING_EDGE()</li>
  2122. <li>__HAL_RTC_<strong>SUBBLOCK</strong>_EXTI_DISABLE_RISING_FALLING_EDGE()</li>
  2123. <li>__HAL_RTC_<strong>SUBBLOCK</strong>_EXTI_GET_FLAG()</li>
  2124. </ul></li>
  2125. <li>Update to use CMSIS mask definition instead of hardcoded values (EXTI_IMR_IM17, EXTI_IMR_IM19..)</li>
  2126. <li>__HAL_RTC_TAMPER_TIMESTAMP_EXTI_GET_FLAG() macro: fix implementation issue</li>
  2127. <li>__HAL_RTC_ALARM_GET_IT(), __HAL_RTC_ALARM_CLEAR_FLAG(), __HAL_RTC_WAKEUPTIMER_CLEAR_FLAG(), __HAL_RTC_TIMESTAMP_CLEAR_FLAG() and __HAL_RTC_TAMPER_CLEAR_FLAG() macros implementation changed: remove unused cast</li>
  2128. <li>IS_RTC_TAMPER() macro: update to use literal instead of hardcoded value</li>
  2129. <li>Update to define hardware independent literals names:
  2130. <ul>
  2131. <li>Rename RTC_TAMPERPIN_PC13 by RTC_TAMPERPIN_DEFAULT</li>
  2132. <li>Rename RTC_TAMPERPIN_PA0 by RTC_TAMPERPIN_POS1</li>
  2133. <li>Rename RTC_TAMPERPIN_PI8 by RTC_TAMPERPIN_POS1</li>
  2134. <li>Rename RTC_TIMESTAMPPIN_PC13 by RTC_TIMESTAMPPIN_DEFAULT</li>
  2135. <li>Rename RTC_TIMESTAMPPIN_PA0 by RTC_TIMESTAMPPIN_POS1</li>
  2136. <li>Rename RTC_TIMESTAMPPIN_PI8 by RTC_TIMESTAMPPIN_POS1</li>
  2137. </ul></li>
  2138. </ul></li>
  2139. <li><strong>HAL SD</strong> update
  2140. <ul>
  2141. <li>Rename SD_CMD_SD_APP_STAUS by SD_CMD_SD_APP_STATUS</li>
  2142. <li>SD_PowerON() updated to add 1ms required power up waiting time before starting the SD initialization sequence</li>
  2143. <li>SD_DMA_RxCplt()/SD_DMA_TxCplt(): add a call to HAL_DMA_Abort()</li>
  2144. <li>HAL_SD_ReadBlocks() update to set the defined DATA_BLOCK_SIZE as SDIO DataBlockSize parameter</li>
  2145. <li>HAL_SD_ReadBlocks_DMA()/HAL_SD_WriteBlocks_DMA() update to call the HAL_DMA_Start_IT() function withDMA Datalength set to BlockSize/4 as the DMA is configured in word</li>
  2146. </ul></li>
  2147. <li><strong>HAL SMARTCARD</strong> update
  2148. <ul>
  2149. <li>Add specific macros to manage the flags cleared only by a software sequence ◾__HAL_SMARTCARD_CLEAR_PEFLAG()
  2150. <ul>
  2151. <li>__HAL_SMARTCARD_CLEAR_FEFLAG()</li>
  2152. <li>__HAL_SMARTCARD_CLEAR_NEFLAG()</li>
  2153. <li>__HAL_SMARTCARD_CLEAR_OREFLAG()</li>
  2154. <li>__HAL_SMARTCARD_CLEAR_IDLEFLAG()</li>
  2155. </ul></li>
  2156. <li>Add several enhancements without affecting the driver functionalities
  2157. <ul>
  2158. <li>Add a new state HAL_SMARTCARD_STATE_BUSY_TX_RX and all processes has been updated accordingly</li>
  2159. <li>Update HAL_SMARTCARD_Transmit_IT() to enable SMARTCARD_IT_TXE instead of SMARTCARD_IT_TC</li>
  2160. </ul></li>
  2161. <li>DMA transmit process; the code has been updated to avoid waiting on TC flag under DMA ISR, SMARTCARD TC interrupt is used instead. Below the update to be done on user application:
  2162. <ul>
  2163. <li>Configure and enable the USART IRQ in HAL_SAMRTCARD_MspInit() function</li>
  2164. <li>In stm32f2xx_it.c file, UASRTx_IRQHandler() function: add a call to HAL_SMARTCARD_IRQHandler() function</li>
  2165. </ul></li>
  2166. <li>IT transmit process; the code has been updated to avoid waiting on TC flag under SMARTCARD ISR, SMARTCARD TC interrupt is used instead. No impact on user application</li>
  2167. <li>Rename macros: add prefix "__HAL"
  2168. <ul>
  2169. <li>__SMARTCARD_ENABLE() by __HAL_SMARTCARD_ENABLE()</li>
  2170. <li>__SMARTCARD_DISABLE() by __HAL_SMARTCARD_DISABLE()</li>
  2171. <li>__SMARTCARD_ENABLE_IT() by __HAL_SMARTCARD_ENABLE_IT()</li>
  2172. <li>__SMARTCARD_DISABLE_IT() by __HAL_SMARTCARD_DISABLE_IT()</li>
  2173. <li>__SMARTCARD_DMA_REQUEST_ENABLE() by __HAL_SMARTCARD_DMA_REQUEST_ENABLE()</li>
  2174. <li>__SMARTCARD_DMA_REQUEST_DISABLE() by __HAL_SMARTCARD_DMA_REQUEST_DISABLE()</li>
  2175. </ul></li>
  2176. <li>Rename literals: remove “D” from “DISABLED” and “ENABLED”
  2177. <ul>
  2178. <li>SMARTCARD_NACK_ENABLED by SMARTCARD_NACK_ENABLE</li>
  2179. <li>SMARTCARD_NACK_DISABLED by SMARTCARD_NACK_DISABLE</li>
  2180. </ul></li>
  2181. <li>Add new user macros to manage the sample method feature
  2182. <ul>
  2183. <li>__HAL_SMARTCARD_ONE_BIT_SAMPLE_ENABLE()</li>
  2184. <li>__HAL_SMARTCARD_ONE_BIT_SAMPLE_DISABLE()</li>
  2185. </ul></li>
  2186. <li>Add use of tmpreg variable in __HAL_SMARTCARD_CLEAR_PEFLAG() macro for compliance with C++</li>
  2187. <li>HAL_SMARTCARD_Transmit_DMA() update to follow the right procedure “Transmission using DMA” in the reference manual
  2188. <ul>
  2189. <li>Add clear the TC flag in the SR register before enabling the DMA transmit request</li>
  2190. <li>HAL_SMARTCARD_Transmit_IT() update to force the disable for the ERR interrupt to avoid the OVR interrupt</li>
  2191. <li>HAL_SMARTCARD_IRQHandler() update check condition for transmission end</li>
  2192. <li>Clean up: remove the following literals that aren’t used in smartcard mode
  2193. <ul>
  2194. <li>SMARTCARD_PARITY_NONE</li>
  2195. <li>SMARTCARD_WORDLENGTH_8B</li>
  2196. <li>SMARTCARD_STOPBITS_1</li>
  2197. <li>SMARTCADR_STOPBITS_2</li>
  2198. </ul></li>
  2199. </ul></li>
  2200. </ul></li>
  2201. <li><strong>HAL TIM</strong> update
  2202. <ul>
  2203. <li>HAL_TIM_IRQHandler(): update to check the input capture channel 3 and 4 in CCMR2 instead of CCMR1</li>
  2204. <li>__HAL_TIM_SET_PRESCALER() updated to use ‘=’ instead of ‘|=’</li>
  2205. <li>Add thefollowing macro in TIM HAL driver</li>
  2206. <li>__HAL_TIM_GET_COMPARE()</li>
  2207. <li>__HAL_TIM_GET_COUNTER()</li>
  2208. <li>__HAL_TIM_GET_AUTORELOAD()</li>
  2209. <li>__HAL_TIM_GET_CLOCKDIVISION()</li>
  2210. <li>__HAL_TIM_GET_ICPRESCALER()</li>
  2211. <li>Add TIM_CHANNEL_ALL as possible value for all Encoder Start/Stop APIs Description</li>
  2212. <li>HAL_TIM_OC_ConfigChannel() remove call to IS_TIM_FAST_STATE() assert macro</li>
  2213. <li>HAL_TIM_PWM_ConfigChannel() add a call to IS_TIM_FAST_STATE() assert macro to check the OCFastMode parameter</li>
  2214. <li>TIM_DMADelayPulseCplt() Update to set the TIM Channel before to call HAL_TIM_PWM_PulseFinishedCallback()</li>
  2215. <li>TIM_DMACaptureCplt() update to set the TIM Channel before to call HAL_TIM_IC_CaptureCallback()</li>
  2216. <li>HAL_TIM_IC_ConfigChannel() update to fix Timer CCMR1 register corruption when setting ICFilter parameter</li>
  2217. <li>HAL_TIM_DMABurst_WriteStop()/HAL_TIM_DMABurst_ReadStop() update to abort the DMA transfer for the specific TIM channel</li>
  2218. <li>Add new function for TIM Slave configuration in IT mode: HAL_TIM_SlaveConfigSynchronization_IT()</li>
  2219. <li>HAL_TIMEx_ConfigBreakDeadTime() add an assert check on Break &amp; DeadTime parameters values</li>
  2220. <li>HAL_TIMEx_OCN_Start_IT() add the enable of Break Interrupt for all output modes</li>
  2221. <li>Add new macros to ENABLE/DISABLE URS bit in TIM CR1 register:
  2222. <ul>
  2223. <li>__HAL_TIM_URS_ENABLE()</li>
  2224. <li>__HAL_TIM_URS_DISABLE()</li>
  2225. </ul></li>
  2226. <li>Add new macro for TIM Edge modification: __HAL_TIM_SET_CAPTUREPOLARITY()</li>
  2227. </ul></li>
  2228. <li><strong>HAL UART</strong> update
  2229. <ul>
  2230. <li>Add new macros to control CTS and RTS</li>
  2231. <li>Add specific macros to manage the flags cleared only by a software sequence ◾__HAL_UART_CLEAR_PEFLAG()
  2232. <ul>
  2233. <li>__HAL_UART_CLEAR_FEFLAG()</li>
  2234. <li>__HAL_UART_CLEAR_NEFLAG()</li>
  2235. <li>__HAL_UART_CLEAR_OREFLAG()</li>
  2236. <li>__HAL_UART_CLEAR_IDLEFLAG()</li>
  2237. </ul></li>
  2238. <li>Remove the check on RXNE set after reading the Data in the DR register</li>
  2239. <li>Add IS_UART_LIN_WORD_LENGTH() and IS_UART_LIN_OVERSAMPLING() macros: to check respectively WordLength and OverSampling parameters in LIN mode</li>
  2240. <li>DMA transmit process; the code has been updated to avoid waiting on TC flag under DMA ISR, UART TC interrupt is used instead. Below the update to be done on user application:
  2241. <ul>
  2242. <li>Configure and enable the USART IRQ in HAL_UART_MspInit() function</li>
  2243. <li>In stm32f2xx_it.c file, USARTx_IRQHandler() function: add a call to HAL_UART_IRQHandler() function</li>
  2244. </ul></li>
  2245. <li>IT transmit process; the code has been updated to avoid waiting on TC flag under UART ISR, UART TC interrupt is used instead. No impact on user application</li>
  2246. <li>Rename macros:
  2247. <ul>
  2248. <li>__HAL_UART_ONEBIT_ENABLE() by __HAL_UART_ONE_BIT_SAMPLE_ENABLE()</li>
  2249. <li>__HAL_UART_ONEBIT_DISABLE() by __HAL_UART_ONE_BIT_SAMPLE_DISABLE()</li>
  2250. </ul></li>
  2251. <li>Rename literals:
  2252. <ul>
  2253. <li>UART_WAKEUPMETHODE_IDLELINE by UART_WAKEUPMETHOD_IDLELINE</li>
  2254. <li>UART_WAKEUPMETHODE_ADDRESSMARK by UART_WAKEUPMETHOD_ADDRESSMARK</li>
  2255. </ul></li>
  2256. <li>Add use of tmpreg variable in __HAL_UART_CLEAR_PEFLAG() macro for compliance with C++</li>
  2257. <li>HAL_UART_Transmit_DMA() update to follow the right procedure “Transmission using DMA” in the reference manual
  2258. <ul>
  2259. <li>Add clear the TC flag in the SR register before enabling the DMA transmit request</li>
  2260. </ul></li>
  2261. </ul></li>
  2262. <li><strong>HAL USART</strong> update
  2263. <ul>
  2264. <li>Add specific macros to manage the flags cleared only by a software sequence ◾__HAL_USART_CLEAR_PEFLAG()
  2265. <ul>
  2266. <li>__HAL_USART_CLEAR_FEFLAG()</li>
  2267. <li>__HAL_USART_CLEAR_NEFLAG()</li>
  2268. <li>__HAL_USART_CLEAR_OREFLAG()</li>
  2269. <li>__HAL_USART_CLEAR_IDLEFLAG()</li>
  2270. </ul></li>
  2271. <li>Update HAL_USART_Transmit_IT() to enable USART_IT_TXE instead of USART_IT_TC</li>
  2272. <li>DMA transmit process; the code has been updated to avoid waiting on TC flag under DMA ISR, USART TC interrupt is used instead. Below the update to be done on user application:
  2273. <ul>
  2274. <li>Configure and enable the USART IRQ in HAL_USART_MspInit() function</li>
  2275. <li>In stm32f2xx_it.c file, USARTx_IRQHandler() function: add a call to HAL_USART_IRQHandler() function</li>
  2276. </ul></li>
  2277. <li>IT transmit process; the code has been updated to avoid waiting on TC flag under USART ISR, USART TC interrupt is used instead. No impact on user application</li>
  2278. <li>HAL_USART_Init() update to enable the USART oversampling by 8 by default in order to reach max USART frequencies</li>
  2279. <li>USART_DMAReceiveCplt() update to set the new USART state after checking on the old state</li>
  2280. <li>HAL_USART_Transmit_DMA()/HAL_USART_TransmitReceive_DMA() update to follow the right procedure “Transmission using DMA” in the reference manual
  2281. <ul>
  2282. <li>Add clear the TC flag in the SR register before enabling the DMA transmit request</li>
  2283. </ul></li>
  2284. <li>Rename macros:
  2285. <ul>
  2286. <li>__USART_ENABLE() by __HAL_USART_ENABLE()</li>
  2287. <li>__USART_DISABLE() by __HAL_USART_DISABLE()</li>
  2288. <li>__USART_ENABLE_IT() by __HAL_USART_ENABLE_IT()</li>
  2289. <li>__USART_DISABLE_IT() by __HAL_USART_DISABLE_IT()</li>
  2290. </ul></li>
  2291. <li>Rename literals: remove “D” from “DISABLED” and “ENABLED”
  2292. <ul>
  2293. <li>USART_CLOCK_DISABLED by USART_CLOCK_DISABLE</li>
  2294. <li>USART_CLOCK_ENABLED by USART_CLOCK_ENABLE</li>
  2295. <li>USARTNACK_ENABLED by USART_NACK_ENABLE</li>
  2296. <li>USARTNACK_DISABLED by USART_NACK_DISABLE</li>
  2297. </ul></li>
  2298. <li>Add new user macros to manage the sample method feature
  2299. <ul>
  2300. <li>__HAL_USART_ONE_BIT_SAMPLE_ENABLE()</li>
  2301. <li>__HAL_USART_ONE_BIT_SAMPLE_DISABLE()</li>
  2302. </ul></li>
  2303. <li>Add use of tmpreg variable in __HAL_USART_CLEAR_PEFLAG() macro for compliance with C++</li>
  2304. <li>HAL_USART_Init() fix USART baud rate configuration issue: USART baud rate is twice Higher than expected</li>
  2305. </ul></li>
  2306. <li><strong>HAL WWDG</strong> update
  2307. <ul>
  2308. <li>Update macro parameters to use underscore: <strong>XXX</strong></li>
  2309. <li>Use of CMSIS constants instead of magic values</li>
  2310. <li>Use MODIFY_REG macro in HAL_WWDG_Init()</li>
  2311. <li>Add IS_WWDG_ALL_INSTANCE in HAL_WWDG_Init() and HAL_WWDG_DeInit()</li>
  2312. <li>Add new parameter in __HAL_WWDG_ENABLE_IT() macro</li>
  2313. <li>Add new macros to manage WWDG IT &amp; correction:
  2314. <ul>
  2315. <li>__HAL_WWDG_DISABLE()</li>
  2316. <li>__HAL_WWDG_DISABLE_IT()</li>
  2317. <li>__HAL_WWDG_GET_IT()</li>
  2318. <li>__HAL_WWDG_GET_IT_SOURCE()</li>
  2319. </ul></li>
  2320. </ul></li>
  2321. <li><strong>HAL IWDG</strong> update
  2322. <ul>
  2323. <li>Use WRITE_REG instead of SET_BIT for all IWDG macros</li>
  2324. <li>__HAL_IWDG_CLEAR_FLAG removed: no IWDG flag cleared by access to SR register</li>
  2325. <li>Use MODIFY_REG macro in HAL_IWDG_Init()</li>
  2326. <li>Add IS_IWDG_ALL_INSTANCE in HAL_IWDG_Init()</li>
  2327. <li>Rename the defined IWDG keys:
  2328. <ul>
  2329. <li>KR_KEY_RELOAD by IWDG_KEY_RELOAD</li>
  2330. <li>KR_KEY_ENABLE by IWDG_KEY_ENABLE</li>
  2331. <li>KR_KEY_EWA by IWDG_KEY_WRITE_ACCESS_ENABLE</li>
  2332. <li>KR_KEY_DWA by IWDG_KEY_WRITE_ACCESS_DISABLE</li>
  2333. </ul></li>
  2334. <li>Add new macro: __HAL_IWDG_RESET_HANDLE_STATE()</li>
  2335. <li>Update IWDG_ENABLE_WRITE_ACCESS() and IWDG_DISABLE_WRITE_ACCESS() as private macro</li>
  2336. </ul></li>
  2337. <li><strong>HAL LL FSMC</strong> update
  2338. <ul>
  2339. <li>Add WriteFifo and PageSize fields in the FSMC_NORSRAM_InitTypeDef structure</li>
  2340. <li>Update FSMC_NORSRAM_Init(), FSMC_NORSRAM_DeInit() and FSMC_NORSRAM_Extended_Timing_Init() functions</li>
  2341. </ul></li>
  2342. <li><strong>HAL LL USB</strong> update
  2343. <ul>
  2344. <li>Update USB_HostInit() and USB_DevInit() functions to support the VBUS Sensing B activation</li>
  2345. <li>USB_FlushTxFifo API: update to flush all Tx FIFO</li>
  2346. <li>Update to use local variable in USB Host channel re-activation</li>
  2347. </ul></li>
  2348. </ul>
  2349. </div>
  2350. </div>
  2351. <div class="collapse">
  2352. <input type="checkbox" id="collapse-section2" aria-hidden="true"> <label for="collapse-section2" aria-hidden="true"><strong>V1.0.1 / 25-March-2014</strong></label>
  2353. <div>
  2354. <h2 id="main-changes-12">Main Changes</h2>
  2355. <ul>
  2356. <li>Patch release : moved macros related to RNG from hal_rcc_ex.h to hal_rcc.h as RNG is present in all versions of the STM32F2</li>
  2357. </ul>
  2358. </div>
  2359. </div>
  2360. <div class="collapse">
  2361. <input type="checkbox" id="collapse-section1" aria-hidden="true"> <label for="collapse-section1" aria-hidden="true"><strong>V1.0.0 / 07-March-2014</strong></label>
  2362. <div>
  2363. <h2 id="main-changes-13">Main Changes</h2>
  2364. <ul>
  2365. <li>First official release</li>
  2366. </ul>
  2367. </div>
  2368. </div>
  2369. </div>
  2370. </div>
  2371. <footer class="sticky">
  2372. For complete documentation on STM32 Microcontrollers </mark> , visit: <span style="font-color: blue;"><a href="http://www.st.com/stm32">www.st.com/stm32</a></span> <em>This release note uses up to date web standards and, for this reason, should not be opened with Internet Explorer but preferably with popular browsers such as Google Chrome, Mozilla Firefox, Opera or Microsoft Edge.</em>
  2373. </footer>
  2374. </body>
  2375. </html>