]>
git.zerfleddert.de Git - fnordlicht-mini/blob - firmware/doc/pwm_table.py
3 # compute pwm reference table
8 interval_cycles
= 64000
10 if __name__
== "__main__":
13 for i
in range(1,levels
):
14 cycles
= (i
/float(levels
-1))**2*float(clock
)/float(basefreq
)
15 delta
= round(cycles
-last
)
16 print "%6d: %10d %6d %6d" % (i
, round(cycles
), delta
, round(cycles
) % interval_cycles
)