andre abelian wrote: > This is for power inverter that from 0-360 must be 16.66 ms > 16,66/360=46.27us but we are getting 46.25us. Duh! This is wrong, and sounds silly anyway. The period of a 1 degree phase change of a 60Hz sine wave is 1 / (60Hz * 360deg/Hz) = 46.30uS/deg. Therefore 46.27uS is actually closer than 46.25uS, but neither is accurate to within the 4 implied digits. Furthermore, why does this inverter need to do whatever it does exactly every 1 degree? Degrees are a human convention, but there is otherwise nothing magic about 1/360 of cycle. ***************************************************************** Embed Inc, embedded system specialists in Littleton Massachusetts (978) 742-9014, http://www.embedinc.com -- http://www.piclist.com hint: The list server can filter out subtopics (like ads or off topics) for you. See http://www.piclist.com/#topics