Modulo Timer (S08MTIMV1) does not work in MC9S08SG4

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

Modulo Timer (S08MTIMV1) does not work in MC9S08SG4

1,363件の閲覧回数
tejaskamod
Contributor I

I am having issues with modulo timer in my SG4. The counter does not count. The issue is with RTC module.

 

MTIMCLK_CLKS = 0;

 

  MTIMCLK_PS = 0;

  MTIMSC_TOIE = 0;

  MTIMMOD = 0xFF;

  MTIMSC_TRST = 1;

MTIMSC_TSTP = 0;

ラベル(1)
0 件の賞賛
返信
2 返答(返信)

1,165件の閲覧回数
Rick_Li
NXP Employee
NXP Employee

Hi Tejas Kamod,

I tried your MTIM configuration on my side and the counter works, it runs as expect.

According your configuration, the CLOCK source is BUS clock.

And the RTC can not be used as MTIM clock source.So, I don't exactly know what "The issue is with RTC module" means.

0 件の賞賛
返信

1,165件の閲覧回数
tejaskamod
Contributor I

Hello,

Thanks for the reply,

I can see the counter is ticking in full chip simulation mode, but when I try to debug the code with USB multilink is always remains ZERO.

All the MTIM register are showing value of 0x00.

I tried to use RTC and can see same issue, all the RTC register values remains ZERO.

All other peripherals including TPM are working perfect on target.

0 件の賞賛
返信