Raspberry Pi connected to a voltage controlled triac driven through an opto-coupler , Using PHP , Jquery UI , we used a slider to control the brightness of an AC Lamp. Can also be used to control a fan speed. Used Webiopi & Wiring Pi together to achieve this.. Can be used for any gpio pins.. without any flicker problems..