freeRTOS causes Hardfault when using sscanf
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2021-01-03 03:35 PM
Hi All,
freeRTOS causes Hardfault when using sscanf. When I don't use freeRTOS this works fine, so the issue is freeRTOS related.
I also previously had printf causing Hardfault but I found a library named newlib which allowed printf to no longer generate the hardfault but sscanf is still a problem.
Any idea on how to resolve this. I am using STM32F103 (Bluepill)
Regards
onio
Solved! Go to Solution.
- Labels:
-
FreeRTOS
-
STM32CubeIDE
-
STM32F1 Series
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2021-01-03 04:25 PM
Do you have a large enough stack to accommodate sscanf() ?
Look at what specifically is faulting,ie instructions and processor registers.
Up vote any posts that you find helpful, it shows what's working..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2021-01-03 04:25 PM
Do you have a large enough stack to accommodate sscanf() ?
Look at what specifically is faulting,ie instructions and processor registers.
Up vote any posts that you find helpful, it shows what's working..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2021-01-04 04:55 AM
Hi Tesla,
Thanks for your reply. I increased the stack size from 128 to 1024 and that seems to have solved the issue with sscanf causing hardfault. Once again thanks.
Regards
onio