Working with Codewarrior 10.2, MC9S08AC16CFG.
I add the component EventCntr16, with mode Repetitive and Iterations before action 32768. My goal is to count pulses on a pin, and invoke EC161_OnEnd every time the count is reached. (I'm assuming that the counter is cleared automatically - or do I have to do this manually as part of EC161_OnEnd?)
When I go to build project, I get the following error:
Description | Resource | Path | Location | Type |
C5200 Limits.h file not found | EC161.c | /nebinclock/Generated_Code | line 48 | C/C++ Problem |
make: *** [Generated_Code/EC161_c.obj] Error 1 | nebinclock | C/C++ Problem |
What am I - or is PEx - doing wrong?
已解决! 转到解答。
Hello,
yes, this location is correct. Could you please try to change the include from #include <Limits.h> to #include <limits.h> and try to build the project again? I assume it should help because you are running under Linux.
best regards
Vojtech Filip
Processor Expert Support Team
Hello,
could you please post here some simple project in order to reproduce it on our side? Could you please also try to create the same in CW V10.3 (if possible)? Did you try clean the project? The issue might also by in upper/lower L letter Limits.h/limits.h.
best regards
Vojtech Filip
Processor Expert Support Team
I can confirm that the problem persists even if I create a new project and add only the EventCntr16, configured as I mentioned, and attempt to build. (This is also on a different computer.)
The 10.2 system is running on my regular machines - Linux laptop & desktop. I only have 10.3 beta on a Windows VM - where I am unable to reproduce the problem. (Although 10.3 won't allow me to choose the CFG package, only CFD, if that means anything.)
What files do you want me to post, or is there a way to export the configuration?
Hello,
Could you please also check that the Limits.h is on disk in correct form corresponding value in include #include <limits.h>?
Regarding Export: The whole project would be the best.
best regards
Vojtech Filip
Processor Expert Support Team
Not sure where I should look for limits.h, but it's not there in the project directory. Looking in the actual CW installation directory, this is the only one that looks relevant:
./CodeWarrior_MCU_10.2/MCU/lib/hc08c/include/limits.h (size 7909 bytes)
Please find attached zip file of my 'test' directory.
Thanks!
Hello,
yes, this location is correct. Could you please try to change the include from #include <Limits.h> to #include <limits.h> and try to build the project again? I assume it should help because you are running under Linux.
best regards
Vojtech Filip
Processor Expert Support Team
Hello,
as CodeWarrior V10.3 is not supported for Linux now I see two workarounds:
#1
Create new Limits.h as copy of the existing limits.h file in (./CodeWarrior_MCU_10.2/MCU/lib/hc08c/include/)
#2
or freeze the generated code of EventCntr component and change it manually as was mentioned in my previous post.
best regards
Vojtech Filip
Processor Expert Support Team
Many thanks - I think solution #1 is the way to work, as any future project will pick up the copy - assuming that freezing generated code will only work for current project.
I know that I can't go to 10.3 in Linux - sad though it is for me. When working on my desktop machine, I run 10.3 in a Windows virtual machine. My laptop, however, isn't powerful enough for this, so for the HCS08 projects that I need to run between the two machines, I'm stuck with 10.2
Thanks again for this solution!