hai,
i work with atmel 89c52 microcontroller.I want to get a 950 microseconds delay in between low and high pulses.Is anybody in here knowing how to calculate the 950 microsecond delay in C lalnguage??.Any sort of help is appreciated.
Its better to use timer to produce delay... Run timer for 50 micosec and keep one variable then increment that variable in ISR 19 times, Then set one flag....
You cannot get accurate delay while using C language, but u can reduce error percentage by using timer.
Or if you can somehow get assembly code crosscompiling your C program, you can calculate the error percentage and try to rectify it.