Now I going to test the MCP23008 8 bit IO expander. Since I will be using it to drive a stepping motor, I worry that the stepping motor spikes might damage the circuit, I am doing the following two things.
1. I will not use the MCP23008 output directly. Instead, I will feed the output to a buffer HC573, with 3V3 supply.
2. The output of HC573 will then drive the optical coupler / isolater TLP521-4. The TLP521-4 has 3V3 at the emitter diode side, and 5V0 at the optical transistor side. So it shifts the level from 3V3 to 5V0. HC573 also drives the 8 indicating LEDs.
I used a digital mutltimeter to check out the voltage range of high low logic levels. I found that for the 3V3 HC573 outputs (driving in parallel the 8 TLP521 light emitting diodes, with 200R resistors, ad the 8 LEDs, with 560R resistors) are 0V, 2.7V, and for the TLP521 outputs (detector CE) are 0.1V, 4.9V.
I now understand why it is not necessary to saturate the TLP521 detector transistors, because the non saturated CE voltage is 0.1V for say 1mA to 5mA collector current, is already good enough to represent a logic low signal. If too saturated, the Vce becomes over 0.8V or 1V+ and is no better if used to represent the low signal.
For TLP521-4, recommended LED forward operational current = 16 == 15 mA. If I am using Vcc = 5V, then the series current limiting resistor value should be around
R = (5V - 1V) / 16mA = 4K /16 ohm = 250 ohm.
For Collector current Ic = 1mA, then
R = 5V / 1 mA = 5K / 1 = 5K ohm
Now I am not using 5V, but 3V3 output from HC573, so I am using a value smaller than 250R = 200R.
And for collector series resistor at the 5V side, I am using 4K7.
.END
No comments:
Post a Comment