i want to ON-OFF two lights(white and red), one from main power source(white light) and one from ups(battery). When main power is present, white light should be ON and red should be off. And when main power fails, red should be ON and White should be OFF. I have Arduino, usb cable, external power supplier(adapter of 12V).
Can any one please suggest me how do i proceed for this ??