add sample code to control the led