Skip to main content
rbs3rd
Associate II
May 19, 2014
Question

Hard fault when drawing bit map using STemWin on STM32F4

  • May 19, 2014
  • 14 replies
  • 3059 views
Posted on May 19, 2014 at 19:07

When I try to display a bit map on my LCD, the STM32F4 jumps to the hard fault  handler. Because the library is in a binary format, I can't really see whats causing the fault. If I comment out the line, the hard fault doesn't happen. I am using other STemWin functions, GUI_SetColor, GUI_FillRect, GUI_SetFont, GUI_DispStringAt, and the LCD behaves exactly as I expect it to. I know that writing to a protected bank of SDRAM will cause an AHB error, and hard fault, so I've verified that the write protect bits are cleared. I'm looking for a recommendation on how to assess the root cause of the hard fault. 

#stemwin-stm32f429
This topic has been closed for replies.

14 replies

francescatodiego
Associate III
May 20, 2014
Posted on May 20, 2014 at 18:52

Second, do you know where IAR specifies the stack size. 

From IAR ide:

Project->options

select Linker in category list

Tab Config press Edit...button

select Stack/Heap Sizes tab

rbs3rd
rbs3rdAuthor
Associate II
May 20, 2014
Posted on May 20, 2014 at 20:55

Thanks!

rbs3rd
rbs3rdAuthor
Associate II
July 30, 2014
Posted on July 30, 2014 at 16:32

The second revision of my HW did have the byte enables assigned correctly, and the hard fault was an issue no more!

Tesla DeLorean
Guru
July 30, 2014
Posted on July 30, 2014 at 16:54

The second revision of my HW did have the byte enables assigned correctly, and the hard fault was an issue no more!

Awesome, thanks for the follow up.
Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..