Page 3 of 4
Re: chprintf / DEBUG Macro
Posted: Thu Feb 05, 2015 9:12 am
by Giovanni
Hi,
When migrating to 3.0 make sure to take chconf.h, halconf.h and mcuconf.h from 3.0, the old files are not compatible.
ChibiOS/RT has a new "tickless mode that requires a specialized timer, STM32_ST_USE_TIMER specifies what timer to use when the tickless mode is enabled. This timer should be a 32 bits timer but also a 16 bits timer can work with some restrictions, the related settings are in chconf.h.
Giovanni
Re: chprintf / DEBUG Macro
Posted: Fri Feb 06, 2015 7:59 am
by Chudik
Hi Giovanni,
Actually, I don't know what happened yesterday, probably compiled another project in my workspace, today morning compilation gave me a lot of errors. Had to change some headers, later on I will show what I have changed. I think the changes need to be implemented in the system
Finally I made all C files compiled without errors, but the asm file is giving me a big trouble. It does not recognize header files from C and C preprocessor instructions either. And I don't know how to solve this problem

For example, in
chcoreasm_v7m.s It can't recognize
Code: Select all
#if CORTEX_USE_FPU /// <---- this
vpush {s16-s31}
#endif
while I checked and did everything to have it 0. So, currently I just commented vpush and vpull s16-s31 out.
it also can't recognize _dbg_check_unlock() and others calls even after I directly included "chdebug.h" to this asm file.
Rev. 2.6.6 did not have such files and these files served by C code.
So, if I could find what to do to fix this problem, that would be great. If not, I'm afraid, I will need to install Eclipse, because, I believe, in this environment it should work. At least, you tested it with this IDE.
I'm not a fan of Eclipse, so I would prefer to work with other IDE.
Re: chprintf / DEBUG Macro
Posted: Fri Feb 06, 2015 9:03 am
by Giovanni
CORTEX_USE_FPU is usually exported by the Makefile, you need your project to define it, see one F4 Makefile for an example.
Giovanni
Re: chprintf / DEBUG Macro
Posted: Fri Feb 06, 2015 9:25 am
by Chudik
I understand, but EM::Blocks does not use makefile

Re: chprintf / DEBUG Macro
Posted: Mon Feb 09, 2015 8:44 am
by Chudik
Tried to use Eclipse. I hate it!!!
Everything should be in C:\ChibiStudio. Compiled,,, but got 32kB of memory usage for the demo!!!

Tried to transfer the exact project to my working directory on the other disk in order to change something - could not do it. The transferring itself is a nightmare. Spent a couple hours with it. After the transferring the compiler says it can't understand NULL and library tasks...What...?!!!
Tomorrow will try to create a project based on demo in Emblocks.
Is there possible to return C file instead of chcoreasm_v7m.s? I understand it might work slower, but at least in ver. 2.6.6 it worked. And asm file actually gave the maximum problems with my previous try. May be after testing it will be possible to use the asm file again.
Re: chprintf / DEBUG Macro
Posted: Wed Feb 11, 2015 1:49 am
by Chudik
Transferred the project to Emblocks. Made it compiled without errors... but the compiled size is... ZERO!!!
What could happened between version 2.6.6 and 3.0 that with 2.6.6 everything worked like a charm, but needed task is not compatible with it, and with 3.0 it can't be compiled?...

Re: chprintf / DEBUG Macro
Posted: Wed Feb 11, 2015 9:11 am
by Giovanni
Are you using startup and linker files from ChibiOS?
Giovanni
Re: chprintf / DEBUG Macro
Posted: Wed Feb 11, 2015 9:30 am
by Chudik
Hi,
I think so. At least all used library files located in os directory.
Link files are *.ld, right? I'm using STM32L152xE.ld and rulesюдв
I also tried to use юдв files from emblocks project - the result was the same.
Re: chprintf / DEBUG Macro
Posted: Wed Feb 11, 2015 4:57 pm
by Chudik
Oops... юдв means .ld
Automatic keyboard languages switching at work 
Re: chprintf / DEBUG Macro
Posted: Wed Feb 11, 2015 6:28 pm
by Giovanni
The 3.0 .ld files include a common rules.ld file, make sure that rules.ld is accessible to the linker, it must be into a library path.
Giovanni