cancel
Showing results for 
Search instead for 
Did you mean: 

Porting STMCube project example to run on Coocox ide

luutey
Associate
Posted on July 25, 2015 at 19:39

I am new to ARM and I really want to learn about it. I have the STM32F429ZI discovery board and  I have decided to use gcc with Coocox IDE.

I tried to port one of the sample project, STemWin_HelloWorld, that accompanies the STM32Cube software (version  STM32Cube_FW_F4_V1.6.0). I managed to get the project to compile, link then generate the executable file, but when I run it on the board it hits the famous ''Hard Fault'' exception. I debugged and found out that the problem occurs when the following method is called:

HAL_DMA_DeInit(&dmaHandle);

This method is located on line 384 of the stm32f429i_discovery_sdram.c file. I have no idea why this problem is happening. I have tested the same project with the same files on EWARM and it works perfectly but no luck to make it work on Coocox IDE. I suspect it might be a problem with the linker file but like I said am new to ARM and I don't know much about the architecture.

I don't know if anyone has tried it and had the same problem.

I will be glad if you could share some ideas and experience on this.

Cheers!!

#coide-stemwin_helloworld
1 REPLY 1
luutey
Associate
Posted on August 06, 2015 at 20:02

Problem Solved!

Apparently I forgot to add the interrupt handler file ''stm32f4xx_it.c'' and because default interrupt handlers are defined in the HAL_Driver files, although defined as weak so that user implementation can override them, the Compiler did not throw any warning or errors. What a nasty bug.

A good lesson learnt though.