In this video you can see how system work:
You can use Atmega8A_Iluminat_inteligent_trepte.hex file with Khazama software.
I write my sketch using Arduino for
english version of niq_ro's articles from:
www.arduinotehniq.com (www.tehnic.go.ro) & nicuflorica.blogspot.ro + youtube channel