The Low-Power Timer in the KM34

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

The Low-Power Timer in the KM34

667件の閲覧回数
小勇邹
Contributor II

Hi,

I want to use the Low-Power Timer as a period timer in my application.After setting the value of the register LPTMR_CMR, is there any formula to caculate the period time??How to caculate  it??

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

532件の閲覧回数
mjbcswitzerland
Specialist V

Hi

The value of the delay (in seconds) is
#define LPTMR_S_DELAY(s_delay) (s_delay * LPTMR_CLOCK) - 1)
whereby the value of LPTMR_CLOCK depends on where you configure it to be taken from; it can be 1000 (LPO), 32768Hz, 4Meg or 32kHz MCGIRCLK, external clock value or external clock value divided by a prescaler.

Regards

Mark
Kinetis for professionals: http://www.utasker.com/kinetis.html

0 件の賞賛

532件の閲覧回数
小勇邹
Contributor II

Hi,

Thank you.

What is the minimum value of the period time? Is it possible to set the period as 1us?

0 件の賞賛

532件の閲覧回数
mjbcswitzerland
Specialist V

The minimum delay depends on your clock.
If you use the LPO (1kHz) the minimum delay is 1ms (with value of 0)
If you use the 4MHz IRC you can set 250ns steps - 1us would be a value of 3 in this case.

Regards

Mark

0 件の賞賛