??? 06/16/09 10:44 Read: times |
#166129 - Delay Loops in 'C'..!!! NO Responding to: ???'s previous message |
Dear Sandeep,
"lacks side-efect" in simple language means "not doing anything meaningful", I personally donot prefer such "blocking" functions for delay. It has few drawbacks. 1> It only consumes CPU's time & prevents it from doing other things. 2> Not only that they are inaccurate, but the inaccuracy also changes with... - a. Oscillator Used - b. Compiler - c. Memory allocation & memory module - d. Sometimes even MCU (6 clock derivative / 2 clock derivative) 3> Requires to change optimisation power of compiler, (the optimisation may be needed in other parts of code) 4> Also accurance of any enabled ISR can elongates it, adding to inaccuracy Regards, Mahesh |