Finished yesterday with software PWM driver to slowly turn lights on and off. Time compare changed in watchdog inteerupt. Now if current time is betweend on and off then on state forced. It's usfull for example if I have to reset avr or after powerdown or after burning time correction into eeprom etc. PWM is working on Timer0 interrupt.
Can not test this code in emulator because it have many bugs with timers and watchdog. But my test led works fine. So I hope it'll work with transistor and power mosfet.