How do I get rid of the "copydown" warnings?

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

How do I get rid of the "copydown" warnings?

ソリューションへジャンプ
966件の閲覧回数
MikeM
Contributor III

I've search everywhere for an answer to this and nothing solves my problem. I am using CodeWarrior Development Studio 10.4 to develop code for the MC9S08DZ16CLC 32 pin device. The code is all in "C". I am getting 5 warning message that read similar to this:

 

"No copydown created for initialized object [some variable]. Initialization data lost."

 

One of the variables flagged was "progVersion" defined globally as:

const char *progVersion = "V1.3";

It went away when I changed it to:

const char progVersion[] = { 'V', '1', '.', '3', 0 };

which I don't quite understand.

 

All the other variables flagged are all defined "static" within a function. However, not all of them get flagged with a warning. Here is a code snippet showing an example:

 

static void stepperPositionDriver(void)

{

    enum {

        eNORMAL = 0,

        eABRUPT_CHANGE,

        eRAMP_DOWN

    };

    static int stepperDriveState = eNORMAL;

    static int previousTarget = -1;

    static bool accelerating = TRUE;

    int distCur, distNew;

 

Both "previousTarget" and "accelerating" are being flagged but not "stepperDriveState". Why would some be flagged but not others throughout the program? I am having the prm file automatically generated. I tried turning that off and putting in a "COPY" command in the prm file but that did nothing.

Can someone please help?

ラベル(1)
0 件の賞賛
1 解決策
523件の閲覧回数
MikeM
Contributor III

Thank you very very much! I would have never found that otherwise. Problem solved!

元の投稿で解決策を見る

0 件の賞賛
3 返答(返信)
523件の閲覧回数
MikeM
Contributor III

Am I the only one who's ever had this problem?

0 件の賞賛
524件の閲覧回数
JimDon
Senior Contributor III

Search on "copydown".

Read this, not sure if it solves your problem, but it is more information:

https://community.freescale.com/message/66863#66863

0 件の賞賛
524件の閲覧回数
MikeM
Contributor III

Thank you very very much! I would have never found that otherwise. Problem solved!

0 件の賞賛