I have a set of christmas rope lights which have LED's in them. It is powered from the mains but would I be able to power it from my USB port? I WOULD take the LED's out and put a few of them on a normal USB cable but I want the little box on the end of the lights which controls the flashing patterns.
Basically would I be able to power a set of christmas lights from USB? Am I right in thinking USB is DC and mains power is AC, does this matter?
The USB ports in a PC can typically provide up to about 500mA total at 5V DC. This would be OK to power a few LEDs, but you would need a series resistor in line with each. Assuming an LED that draws around 20mA, the value of each series resistor would need to be around 150 Ohms. I would doubt that the "little box that controls the flashing patterns" operates from 5V (check the mains power supply output rating), in which case I think you are stuck with SANTOS7's suggestion. Please forgive me if I am wrong, but I am guessing that you are not an electronic engineer, in which case I would not recommend trying to use the USB ports as a power source.
Agree with the others its really not a good idea, too many problems and theres a good chance of destroying your USB. click here they do Xmas trees powered by USB - little ones but only nearer Xmas. If you want something silly or whatever then how about this click here