<div>
tHello all.</div>
<div>
t </div>
<div>
tI have some misunderstanding with TTCs on zynq-7000. I used this guide to understand how TTCs are working, but seems like a quite subtlety which I don't understand.</div>
<div>
t </div>
<div>
tI have to use 2 TTCs with PWM (match value) and change RC in handlers to make CNC. After trying to make it like get new RC in handler and change RC I got unstable error for about 0.5s for 25s of changing RC and some impulses haven't generated but handler was called instantly after changing RC (I took into account that (RC - match value) should be greater then 0).</div>
<div>
t </div>
<div>
tI thought it can be because I have to:</div>
<div>
t1) reduce time we waste in handler (some code fragments like change RC made by asm);</div>
<div>
t2) consider some information we lose when we shift RC to prescaler;</div>
<div>
t3) consider counter of my timer because there are sometimes another handlers or something;</div>
<div>
t4) when we change RC we should reset counter (special bit in XTTCPS_CNT_CNTRL register);</div>
<div>
t5) see if RC is less then counter - make RC as match value (never happens).</div>
<div>
t </div>
<div>
tAfter this manipulations I saw that my timers with same amount RC (before counter compensation) ends in different time (I used different counters so timers have different number of RC).</div>
<div>
t </div>
<div>
tCan someone help me?</div>
<div>
t </div>
<div>
tP.S. I tried to use inline functions with asm() to change RC. Universal (by transmit using timer number) and 2 different functions with same (different only address to timer) asm code, and I got different results. I don't understand why.</div>
<div>
t </div>
<div>
tThanks!</div>