I am getting link errors and warnings when I make my project. I do not know how to fix them. This shows the errors. http://www.turbofast.com.au/tfbin/ErrorsCanLogger.png
The problem relates to a structure that is defined in the GlobalsShared.h file. I get no errors when I compile the project.
I have attached the project files.
Ray.
Original Attachment has been moved to: CAN_Logger.zip
Solved! Go to Solution.
XGATE compiler by default word aligns all struct members with sizeof() > 1. So you need to either insert "uint8_t dummy;" below or above unpaired acRequest , or in HC12 sources, which include GlobalsShared.h use pragma align like this
#pragma align on
#include "GlobalsShared.h"
#pragma align off
This will resolve different object size message. And to resolve "object defined twice", you need to insert extern keyword above your struct in *.h file.
Edward
XGATE compiler by default word aligns all struct members with sizeof() > 1. So you need to either insert "uint8_t dummy;" below or above unpaired acRequest , or in HC12 sources, which include GlobalsShared.h use pragma align like this
#pragma align on
#include "GlobalsShared.h"
#pragma align off
This will resolve different object size message. And to resolve "object defined twice", you need to insert extern keyword above your struct in *.h file.
Edward
Edward,
Thank you,
Ray.