Man-wai Chang said:
I would like to modify a dead mouse into a LED power. The chip would not
activate the LED input until the PC boots into Window$.
Could I short a few pins on the CP5609AMT to skip the detection of
Window$ and instantly turns on the LED input?
I can't find a datasheet for it. Cheap silicon chips don't come
with a lot of extra pins, allowing the function you describe. They
only have enough pins to perform the function they're designed for
(being a mouse).
You can disconnect the LED or laser from the circuit, and use it
separately.
*******
There are two kinds of optical devices, LEDs and lasers. LEDs can
run on a continuous source of current. Lasers may be able to run
from a continuous current, or some require pulsed power. A pulsed
laser would be destroyed by using a continuous current. But many
modern lasers take a continuous current.
Using a multimeter, you could make measurements on the circuit,
to determine the correct drive level. (But you've indicated in
previous postings, you're not interested in doing that.)
For a LED, the most practical basic circuit looks like this.
+ -
+VCC ---------- resistor -------- LED ----- Ground
The resistor limits the current flow. Without the resistor,
an infinite amount of current will attempt to flow. The resistor
limits the current to a safe value.
To work an example, say you have a red LED, which has a forward
voltage drop of 2.2V at 20 milliamps (I just made those figures up,
as I'm too lazy to download a datasheet). The 20mA figure, may be
the recommended or the maximum input current allowed. You happen
to have a +5V source of power (like the USB bus power source). For
the circuit to work, the voltage source (+5V) must be greater than
the LED forward voltage drop. Otherwise, the LED will not light up.
Since 5V is greater than 2.2V, the LED will light. The LED must be
installed correctly in the circuit as well, as it has a polarity,
and only lights up if install the correct way.
Now, we work out the resistor value.
+ -
+5V -------- resistor ------- LED --------- Ground
2.2V
20mA
You know the voltage across the resistor is 5-2.2V or 2.8 volts.
2.8V divided by 20mA or 0.020 amps is 140 ohms. Perhaps you would
go to the local Radio Shack store, and buy a 150 ohm resistor
(next highest value would be safe).
The resistor will get warm. To work out how warm, you work out
the power. V*I = 2.8 volts * 0.020 amps = 56 milliwatts. A
1/8th or a 1/4 watt resistor should be able to take the heat.
This is your final circuit. Because the resistor has a slightly
higher value, the actual current flow will be a bit less than 20mA.
+5V -------- resistor ------- LED --------- Ground
150 ohms 2.2V
1/4 watt 20mA
The forward voltage drop across a LED, is proportional to
Planck's constant. The voltage depends on the color of the
LED. A blue LED, for example, has a much higher voltage drop.
And so, for each color of LED used, you need to work out
a new resistor value. If we used the same 150 ohm resistor
with the blue LED, the light output would be weaker.
I presume the math for a continuous duty cycle laser would be
similar, but I've never worked with one. Some mice use lasers,
rather than LEDs.
Paul