I have the AC mains (240 V, 50 Hz) connected to a zero-crossing detector (ZCD) circuit. The output of the ZCD triggers INT1 of Atmega16 and sets the Timer 1. After the timer times till the required value, I need a continuous high pulse at Port D.5.
The value of the timing is user defined, based on a number of keys the user presses. Though I know basic C language, I have never used Atmega16 and the header files and their functions aren't known to me. If anyone could help in the modification of the program in this link, I would appreciate it.
http://extremeelectronics.co.in/avr-projects/avr-project-remote-controlled-fan-regulator/
Some parts of the code would not be required and a few additions needed, I guess.
"Almost" Good Answers: