What does NEWVAL mean in TIM?

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
seanwu
Level 2
Level 2
Distributor - Weikeng(GC)
10 replies posted 10 sign-ins 5 replies posted

Dear sir,

There is a NEWVAL interrupt siganl in TIM. But I don't know what the new value mean.

Could you please help to explain it?

THanks.

BR,

Sean Wu

0 Likes
1 Solution
Jeremy_Z
Moderator
Moderator
Moderator
1000 replies posted 250 sign-ins 100 likes received

Hi @seanwu 
The NEWVAL IRQ interrupt is triggered at the end of a complete measurement cycle which includes the period and duty cycle, so it's unavailable to customize its working mechanism.
BR,
Jeremy

View solution in original post

0 Likes
8 Replies
Di_W
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 250 solutions authored

Please refer to 28.13.4 TIM Channel Architecture in user manual.

When new data is written into GPR0 and GPR1 the NEWVAL bit is set in TIM[i]_CH[x]_IRQ_NOTIFY register and
depending on corresponding enable bit value the NEWVALx_IRQ interrupt is raised.

0 Likes
seanwu
Level 2
Level 2
Distributor - Weikeng(GC)
10 replies posted 10 sign-ins 5 replies posted

Dear sir,

What is the new data type? A low to high or high to low change? Or a duty cycle?

Thanks.

BR,

Sean

0 Likes
Di_W
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 250 solutions authored

NEWVAL: The NEWVAL IRQ interrupt is triggered at the end of a measurement cycle, signaling that the registers GPR0 and GPR1 are updated.

0 Likes
seanwu
Level 2
Level 2
Distributor - Weikeng(GC)
10 replies posted 10 sign-ins 5 replies posted

Dear sir,

What does "at the end of a measurement cycle" mean?

Thanks.

BR,

Sean

0 Likes
seanwu
Level 2
Level 2
Distributor - Weikeng(GC)
10 replies posted 10 sign-ins 5 replies posted

Dear sir,

Is like the below picture?  measurement cycle is from "a" to "b"?

The interrupt is triggered at "b". If I want to trigger interrupt at "a" point, how to do that or unable to do?

Thanks. BR,

Sean

 

seanwu_0-1673245888309.png

 

0 Likes
Di_W
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 250 solutions authored

From my understanding, I think it's triggered at the end of measurement cycle. not enable to change.

0 Likes
seanwu
Level 2
Level 2
Distributor - Weikeng(GC)
10 replies posted 10 sign-ins 5 replies posted

Dear sir,

Sorry, I don' understand what you mean

0 Likes
Jeremy_Z
Moderator
Moderator
Moderator
1000 replies posted 250 sign-ins 100 likes received

Hi @seanwu 
The NEWVAL IRQ interrupt is triggered at the end of a complete measurement cycle which includes the period and duty cycle, so it's unavailable to customize its working mechanism.
BR,
Jeremy

0 Likes