ERIKA Enterprise for STM32F4

Forum related to ERIKA Enterprise and RT-Druid version 2

Moderator: paolo.gai

ffddybz
Newbie
Posts: 13
Joined: Wed Dec 03, 2014 9:55 am

Re: ERIKA Enterprise for STM32F4

Post by ffddybz » Mon Jan 26, 2015 2:16 pm

When I am familiar with the usage of Linux, It is really strange to use cygwin to build the cross-compiler toolchains. But finally I found the way to building the arm-gcc by clicking next again and again for the 'exe' package and then set the environment variable.And now compiler issue have been solved.

paolo.gai
Administrator
Posts: 875
Joined: Thu Dec 07, 2006 12:11 pm

Re: ERIKA Enterprise for STM32F4

Post by paolo.gai » Mon Jan 26, 2015 6:00 pm

Well we used Cygwin just because we needed a decent "make" implementation on windows.

The compilers then come in various ways from variopus sources... some have a cygwin support (also Nios II for example)...

PJ

ffddybz
Newbie
Posts: 13
Joined: Wed Dec 03, 2014 9:55 am

Re: ERIKA Enterprise for STM32F4

Post by ffddybz » Tue Jan 27, 2015 4:41 am

It is still difficult for me to run a simple demo for STM32F4 Discovery, When I am using the default configuration downloaded from erika\examples\cortex_mx\STM32F4xx\porting_examples_GNU\monostack\EEtest0, It seems that the toolchains correctly create the STM32 library,you can look here:
test00.png
test00.png (141.92 KiB) Viewed 119328 times
But it still compiler error,the output are listed below:
test01.png
test01.png (72.08 KiB) Viewed 119328 times
I try to figure out the reason of this problem, So I read the Makefile in the directory of Debug, there existed only one command to find the header file:
include $(EEBASE)/pkg/cfg/rules.mk
the rules.mk gotten from RT-Druid(which download recently). So it may be the problem of configuration or the problem of RT-Druid?

paolo.gai
Administrator
Posts: 875
Joined: Thu Dec 07, 2006 12:11 pm

Re: ERIKA Enterprise for STM32F4

Post by paolo.gai » Tue Jan 27, 2015 8:49 am

EEtest0 is a test from the porting examples. they have been done at the beginning of the porting and I guess they are not tested in the regression tests because they lack a template.xml.

Try creating a new project and use one of the many templates available. Those compile without problems.

Also you can try the Virtual Machine on http://www.erika-enterprise.com . It has everything pre-installed and there is a PDF guide on how to compile and flash an application of a STM32F4Discovery.

PJ

ffddybz
Newbie
Posts: 13
Joined: Wed Dec 03, 2014 9:55 am

Re: ERIKA Enterprise for STM32F4

Post by ffddybz » Tue Jan 27, 2015 9:15 am

Sorry, It seems that the same problem again. I create the default project from Eclipse, and use the "arm-none-eabi-gcc.exe (GNU Tools for ARM Embedded Processors) 4.9.3 20141119 (release) [ARM/embedded-4_9-branch revision 218278]" to build it, but get the result as below:
test03.png
test03.png (186.87 KiB) Viewed 119326 times
It seems that I should set the static linking manually???
Last edited by ffddybz on Tue Jan 27, 2015 9:22 am, edited 1 time in total.

paolo.gai
Administrator
Posts: 875
Joined: Thu Dec 07, 2006 12:11 pm

Re: ERIKA Enterprise for STM32F4

Post by paolo.gai » Tue Jan 27, 2015 9:20 am

The CDT configuration that we ship sometimes fails to recognize the include files or the compiler, so it gives errors in the "Problems" view.

Did the application compile correctly in the Console window?

Also, you need to create a NEW PROJECT of kind RT-DRUID. the wizard will give you a list of available templates. choose one of them and see if you are able to compile it.

if in doubt, please download the virtual machine and follow the PDF instructions.

PJ

ffddybz
Newbie
Posts: 13
Joined: Wed Dec 03, 2014 9:55 am

Re: ERIKA Enterprise for STM32F4

Post by ffddybz » Tue Jan 27, 2015 9:41 am

paolo.gai wrote:The CDT configuration that we ship sometimes fails to recognize the include files or the compiler, so it gives errors in the "Problems" view.

Did the application compile correctly in the Console window?

Also, you need to create a NEW PROJECT of kind RT-DRUID. the wizard will give you a list of available templates. choose one of them and see if you are able to compile it.

if in doubt, please download the virtual machine and follow the PDF instructions.

PJ
Whatever to create a new project of kind RT-DRUID or build it in the cygwin terminal, the output are all the same:
cygwin.png
cygwin.png (24.88 KiB) Viewed 119324 times
but in the main.c it will get several errors.(It maybe a bug in RT-Druid)

paolo.gai
Administrator
Posts: 875
Joined: Thu Dec 07, 2006 12:11 pm

Re: ERIKA Enterprise for STM32F4

Post by paolo.gai » Tue Jan 27, 2015 9:48 am

everything is correct. the main.c has been compiled correctly.

The CDT configuration is not correct, and it is a known issue, that we solved for some compilers but not for EVERY compiler.

That is, the Problems view will still give you problems, but the main.c compiles correctly.

PJ

ffddybz
Newbie
Posts: 13
Joined: Wed Dec 03, 2014 9:55 am

Re: ERIKA Enterprise for STM32F4

Post by ffddybz » Tue Jan 27, 2015 9:59 am

Thank you for your patient reply. It gives me confusion for almost all day.

vietnguyen
Newbie
Posts: 2
Joined: Sun Jan 25, 2015 4:12 pm

Re: ERIKA Enterprise for STM32F4

Post by vietnguyen » Tue Feb 10, 2015 5:23 pm

Hi everybody,

I am trying to create a stand-alone libee.a and compile it with another IDE: Coocox. Following is the tools that I use:

******* Tools *********
- ERIKA Enterprise and RT-Druid 2.4.0
- Using code: STM32F4DISCOVERY DEMO GPIO
- ARM compiler: GCC ARM Embedded (4.8_2014q3)
- IDE that using the libee.a: Coocox


******* Behaviours *********
- I compiled and tested the example code, it runs well on my Discovery board.

- To build the library, I follow the instruction here http://erika.tuxfamily.org/wiki/index.p ... id_Eclipse except adding the misc strings.

-Problem: When I used the libee.a in Coocox, it compiled successfully ( a lot of "defined but not used" warnings), but no LED on discovery board flashes.

-Now, I tried to add misc string as shown in above tutorial to solve above problem but it did not work:
Image

-This is my compiling string now:
Compiler control string: -mcpu=cortex-m4; -mthumb; -Wall; -ffunction-sections; -g; -O0; -flto; -fno-builtin; -fno-exceptions;-fno-rtti;-DSTM32F407VG; -DSTM32F4XX; -DUSE_STDPERIPH_DRIVER; -D__ASSEMBLY__; -DSUPPORT_CPLUSPLUS; -I.; -Ierika/os_library/com.eu.evidence.ee_2.4.0.20141105_0021/ee_files/pkg;

Linker control string -mcpu=cortex-m4; -mthumb; -g; -flto; -Map=STM32F4_DISCOVERY.map; -O0; --gc-sections; --entry=main; -lstdc++; --entry=EE_cortex_mx_default_reset_ISR; --first=EE_cortex_mx_vtable; -L..\..\armcompiler\4.8_2014q3\arm-none-eabi\lib\; -lm; -Lerika\os_core\; -lee; -Lerika\os_core\; -lstm32f4discovery; -Lerika\os_core\; -lstm32f4xxspd; -L${linkdir}; -T${linkdir}/arm-gcc-link.ld;

I guess that something is missing in compiling string. I also tried to get the arm gnu compiling string of RT-Druid for comparison but do not know where to get it.

Please kindly help me to find the errors. :'( :'(

janakiram
Newbie
Posts: 5
Joined: Wed Jul 13, 2016 1:28 pm

Re: ERIKA Enterprise for STM32F4

Post by janakiram » Thu Jul 21, 2016 1:06 pm

Hi everyone,
How to flash this generated binaries(c_mX.bin c_mX.elf libee.a) after successful compilation to STM32F4 Discovery board without VM in ubuntu host,Thanks in advance :)

paolo.gai
Administrator
Posts: 875
Joined: Thu Dec 07, 2006 12:11 pm

Re: ERIKA Enterprise for STM32F4

Post by paolo.gai » Fri Jul 22, 2016 8:13 am

Just repeat the same setup shown in the Virtual machine at http://www.erika-enterprise.com

PJ

janakiram
Newbie
Posts: 5
Joined: Wed Jul 13, 2016 1:28 pm

Re: ERIKA Enterprise for STM32F4

Post by janakiram » Thu Aug 18, 2016 6:55 am

Thanks PJ! its working fine,

I would like to debug the application in eclipse on ubuntu host machine, can you please help me?

lqe2hc
Newbie
Posts: 1
Joined: Mon Apr 12, 2021 5:37 pm

Re: ERIKA Enterprise for STM32F4

Post by lqe2hc » Sat Oct 09, 2021 5:31 pm

janakiram wrote:
Thu Jul 21, 2016 1:06 pm
Hi everyone,
How to flash this generated binaries(c_mX.bin c_mX.elf libee.a) after successful compilation to STM32F4 Discovery board without VM in ubuntu host,Thanks in advance :)
You just open terminal in the folder which contain your binary, and use stmflash cmd for flashing

Post Reply