Migration from MCS9S08GT60 to MC9S08AC128

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Migration from MCS9S08GT60 to MC9S08AC128

1,588 Views
preetuabraham
Contributor III

We had a legacy project using MC9S08GT60 .Since we had occupied almost 58k bytes and only 6k bytes was left, it was decided to go with same HCS08 architecture with larger memory MC9S08AC128 to show it has more memory left.

For MC9S08GT60 ,we used small memory model and for MC9S08AC128 we use Banked memory model.

Please let me know if there is any migration procedure since we are not able to get it working as per our requirements

0 Kudos
Reply
6 Replies

1,365 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

Hello

MC9S08GT60 and  MC9S08AC128 are both hcs08 devices but there are still some difference. for example, the register name, the memory usage. Thus to port your project from MC9S08GT60 to MC9S08AC128 , I think the easiest way is:

- create a new MC9S08AC128  project with wizard, choose banked model.

- add the code to this MC9S08AC128  part by part. revise your code based on the build result.

Hope this helps.


Have a great day,
Jennie Zhang

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
Reply

1,366 Views
preetuabraham
Contributor III

Hi Zhang,

So whether the Timer Module has changed ,Since I find a section in MC9S08AC128 15.8 Section for v2 and v3 ,what does it mean .Whether this has any reference to the values getting set in register

0 Kudos
Reply

1,365 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

This is more a MCU question. I suggest you contact 8bit MCU space.

8-bit Microcontrollers 

Have a great day,
Jennie Zhang

0 Kudos
Reply

1,365 Views
preetuabraham
Contributor III

Hi Zhang,

  I had raised this query in 8-bit Micro Section and no one replied yet

--Preetu

0 Kudos
Reply

1,366 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

If no reply from community, for urgent case,  Another option is to contact MCU support by submit a ticket

https://community.nxp.com/docs/DOC-329745 

Jennie Zhang

0 Kudos
Reply

1,366 Views
preetuabraham
Contributor III

Hi Jennie,

Yes I did change the memory addresses of the registers. But for setting the ICG and TPM Timer registers with an external oscillator of 27MHz

For MC9S08GT60: FBE Bypassed external mode

/* Using an external 27Mhz crystal

_ICGC1.ICGC1Data = 0x54;

_ICGC2.ICGC2Data = 0x01;

 

/* Set the status and control register for the TPM. */

_TPM1SC.TPM1SCData = 0x4f;  /*prescaler is 128*/

_TPM1MODH.Data = 0xff;

_TPM1MODL.Data = 0xff;

We were getting a timer interrupt every 5 ms.

But with MC9S08AC128  with all the same register bit setting  ,we are not getting 5 ms interrupt instead 1.2s interrupt.

But when I changed the Modulus value to 0x106 ,it gets the interrupt at 5ms .I am not sure why there is a difference since the registers are all same and external frequency .Do you have any clue about it.

 

0 Kudos
Reply