cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F207 was HangUp, at the GPIO Initial.

SYun
Associate

Hi.

yesterday, my stm32 board run was good.

today, I add to code​(printf...). but my board is hangup.

I was check memory over. but, i use 25%.

project.map

    177 901 bytes of readonly code memory

    54 396 bytes of readonly data memory

    87 330 bytes of readwrite data memory

Errors: none

Warnings: none

Internal memory of STM32F207 is 0x08000000~0x080fffff.

I was only add the "printf" code. but, my board is hangup.

I was debugging. i was find the hangup position the GPIO Initial.

assert_param(IS_GPIO_OTYPE(GPIO_InitStruct->GPIO_OType));

I don't know. problem at the this position.

yesterday, GPIO initial code is good.

I don't know, that I add only some code. and I have this problem?

thank you

1 ACCEPTED SOLUTION

Accepted Solutions
SYun
Associate

​Thank you.

I was solved the problem.

I was change thes position of GPIO Initial().

and then, this problem is clean.

View solution in original post

2 REPLIES 2

Perhaps use a debugger and determine where it HangUp? ie press STOP and see.

Check for NUL pointers and incomplete structure initialization. Be aware of how local/auto variables allocate from dirty stack memory.

If it asserts because of particular fields, perhaps check those.

Make sure you have sufficient stack.

Be able to determine if it gets stuck in the HardFault_Handler() or Error_Handler()

Make sure you have libraries and suitable targeting of putchar() type routines for printf() to utilize, ie targeting an initialized USART or SWV debug channel.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
SYun
Associate

​Thank you.

I was solved the problem.

I was change thes position of GPIO Initial().

and then, this problem is clean.