Forum : 8051
Original Post
Post Information | Post |
---|---|
June 19, 2007 - 4:44pm
|
Hello Guys, The thing is that in my "main.c" I have #include "autonomous.h" main() .. and inside my "autonomous.c" unsigned char AutonomousInitiate(void) So everything seems correct... :-( |
... and in autonomous.h, what do you have ? Did you check typos ? You can have a look at the map file (its extension is .m51) generated by the linker: it will show you the name of the symbols generated by each module (for example, MAIN is a module and AUTONOMOUS will be another one), and you could detect a conflict there.
You can also send me your whole project if you want me to have a look.
regards,
Lionel
Hello Lionel
In autonomous.h I have this:
..
unsigned char AutonomousInitiate(void);
..
I checked the map file, and I have something strange, objects seem to be duplicated and MAIN is not:
INPUT MODULES INCLUDED
G:\DEVELOPMENT\CODE\UPSD3422EV\MASTERMODULE_V1_03\AUTONOMOUS.OBJ(A&
UTONOMOUS)
G:\DEVELOPMENT\CODE\UPSD3422EV\MASTERMODULE_V1_03\AUTONOMOUS.OBJ(A&
UTONOMOUS)
G:\DEVELOPMENT\CODE\UPSD3422EV\MASTERMODULE_V1_03\MAIN.OBJ(MAIN)
G:\DEVELOPMENT\CODE\UPSD3422EV\MASTERMODULE_V1_03\UPSD3400.OBJ(UPS&
D3400)
G:\DEVELOPMENT\CODE\UPSD3422EV\MASTERMODULE_V1_03\UPSD3400.OBJ(UPS&
D3400)
maybe it is normal... ?
As you kindly suggested it, I d like to send you my project, but I cant attach files using email functionality of these pages!
So here is my email address deleted for security purposes, Send me an email I will reply you with files attached.
thank you for your time
fabrice
I wonder if you added your header files as well as application nodes... You should not do this. Header files are considered as dependencies of .c files, and if you add them as nodes, the compiler will try to compile them and create a module for them as well. It is not the purpose. You should only add as nodes, files that you want to see translated into object files (if you write C code only, this means only .c files).
regards,
Lionel
Thank You Lionel! :-)
That was it, indeed I added .h and .c both with "Add node Source/application" functionality.
Adding only *.c files worked.
Thank you
fabrice