Sangam, could you try this patch: https://github.com/apache/nuttx/pull/12484 ?
On Tue, Jun 11, 2024 at 12:20 PM Xiang Xiao <xiaoxiang781...@gmail.com> wrote: > Could you share the call stack when the assert happens? > > On Mon, Jun 10, 2024 at 4:02 PM Sangam Thapa <sangam.thapa...@outlook.com> > wrote: > >> >> ------------------------------ >> *From:* Sangam Thapa <sangam.thapa...@outlook.com> >> *Sent:* Monday, June 10, 2024 1:44 PM >> *To:* dev-thread.12...@nuttx.apache.org < >> dev-thread.12...@nuttx.apache.org> >> *Subject:* Problem initializing hardware timer in stm32 board >> >> I'm writing to seek assistance with a hardfault error I'm encountering >> while working on hardware timers for the STM32F427AI board. There seems to >> be a limited amount of resources available specifically for hardware >> timers, although I found some information related to PWM. >> *The Problem:* >> I'm using the stm32_timer_initialize function (example: >> stm32_timer_initialize("/dev/timer7", >> 7)) to initialize the timer driver. However, when I run the provided >> basic timer application, a hardfault occurs at line 256 of the timer.h file. >> This >> line seems to be the root cause of the error. >> *What I've Tried:* >> >> - I've verified that the timer driver is initialized correctly with >> the appropriate device name and timer number for the board. >> - I've reviewed the timer configuration to ensure it aligns with my >> application's requirements (clock source, prescaler, count mode). >> - I've searched online forums and communities for similar issues but >> haven't found any relevant solutions. >> >> *Request for Assistance:* >> If anyone has encountered and resolved similar hardfault errors related >> to hardware timers on the STM32F427AI, your insights would be greatly >> appreciated. Any suggestions or resources regarding hardware timer >> configuration for this board would be extremely helpful. >> *Additional Information (Optional):* >> >> - If possible, I can share more details about the specific timer >> configuration and the code snippet around line 256 of timer.h. >> >> >> Thank you for your time and support. >> >>