Flash Memory

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

Flash Memory

2,325件の閲覧回数
alexismercier
Contributor III


hello everybody,

 

does anyone know how to save the results of my measure in the flash memory oh the MC9s08JM32?

ラベル(1)
タグ(2)
16 返答(返信)

1,880件の閲覧回数
alexismercier
Contributor III

Hello Jun Zhang ,

thank oyu for your answer , I'll try this and I'll tell you if I meet sany problem

0 件の賞賛
返信

1,880件の閲覧回数
ZhangJennie
NXP TechSupport
NXP TechSupport

you are welcome!

0 件の賞賛
返信

1,880件の閲覧回数
alexismercier
Contributor III

hello,

I used the routine tha t you give me in my code but when I want to check if it work i can't see nothing

here's my code:

uint valCO2;

uint valO2;

uint valCO2FinTest;

uint valO2FinTest;

int part_entCO2 ;

int part_decCO2;

int part_entO2;

int part_decO2;

char parteO2;

char partdO2;

char parteCO2;

char partdCO2;

int verif;

      valO2=44;

      valO2FinTest=valO2;

        part_entO2 = valO2FinTest/100;

        parteO2=(char)  part_entO2;

       

    part_decO2=valO2FinTest-part_entO2*100;

    partdO2=(char)  part_decO2;

    FlashInit();

    Flash_Erase (0xFF80);

    Flash_Burst(0xFF80, sizeof(partdO2) , partdO2);

    if (Flash_Burst(0xFF80, sizeof(partdO2) , partdO2)){

   verif=verif+1;

    }

0 件の賞賛
返信

1,880件の閲覧回数
ZhangJennie
NXP TechSupport
NXP TechSupport

did you perform CopytoRAM routine in your code. CopyToRAM is very necessary when we program flash as EEPROM.

for more information about CopyToTAM, please check TN228

0 件の賞賛
返信

1,880件の閲覧回数
alexismercier
Contributor III

hello Jun Zhang,

thank you for your help, I didn't used CopytoRAM  i'll try this today.

This is the first time I use Flash  memory as EEPROM so i'm little bit lost.

I'll check TN228 as you suggest.

regards

0 件の賞賛
返信

1,880件の閲覧回数
ZhangJennie
NXP TechSupport
NXP TechSupport

you are welcome!

0 件の賞賛
返信

1,880件の閲覧回数
alexismercier
Contributor III

do I have to use CopytoRam at the beginig of my code or just before FlashInit fcn?

thanks for your answer

0 件の賞賛
返信

1,880件の閲覧回数
ZhangJennie
NXP TechSupport
NXP TechSupport

before FlashInit

0 件の賞賛
返信

1,880件の閲覧回数
alexismercier
Contributor III

okay thank you for your great help Jun Zhang

0 件の賞賛
返信

1,880件の閲覧回数
ZhangJennie
NXP TechSupport
NXP TechSupport

you are welcome!

0 件の賞賛
返信

1,880件の閲覧回数
alexismercier
Contributor III

hello,

when the debugger compile the code , it stay running without finishing programand I can't see nothing in the memory window, but if I close the debugger and open it again using HOTSYNC I can see my data in the rom at the good adress.

Is this normal ?

thanks for answers .

Alexis.

0 件の賞賛
返信

1,880件の閲覧回数
alexismercier
Contributor III

another problem,

when I use the debugger my code stay running on LDHX #0x0178 in  INIT_SP_FROM_STARTUP_DESC();

in Start08.c Source.

do you know the reason of this problem ?

thanks

0 件の賞賛
返信

1,880件の閲覧回数
alexismercier
Contributor III

Hello,

How can I check that the measure result has been saved in the Flash Memory?

Thanks for your answer

Regards.

Alexis

0 件の賞賛
返信

1,880件の閲覧回数
ZhangJennie
NXP TechSupport
NXP TechSupport

Before launch debugger,  click on HotSync in connection manager. The Hotsync button in the Connection Assistant allows the user to connect to an already running target without erase the flash.

then in debugger, check the memory window to see if the according memory was written.

Hope this helps!

0 件の賞賛
返信

1,880件の閲覧回数
ZhangJennie
NXP TechSupport
NXP TechSupport

if you want save the measure result to flash, please refer attached sample code

0 件の賞賛
返信

1,880件の閲覧回数
alexismercier
Contributor III

thank you Jun Zhang


0 件の賞賛
返信