simple optical switch

Not rated 25,507

Circuit Image

When the phototransistor is illuminated by infrared (IR) light, it begins to conduct, causing the voltage between a 1 MΩ resistor (chosen arbitrarily) and the phototransistor to decrease from VCC to lower values. When this voltage falls below VCC/3, the 555 timer is triggered, resulting in a high output (transitioning from 0 to VCC). The amount of light required to bring the collector voltage of the phototransistor down to VCC/3 is determined by the resistor value. The voltage drop (Vdrop) can be expressed as Vdrop = Icollector * R. Therefore, if Vdrop equals 2 * VCC/3, the resistance necessary to set the current threshold can be calculated using the formula R = 2 * VCC / (Icollector * 3). High-sensitivity phototransistors will require a smaller resistor, while weaker phototransistors will necessitate a higher resistor value. A trimmer can also be employed to finely adjust the threshold level. The timing of the phototransistor is not critical. The 555 timer possesses a high current capability, allowing it to drive various devices such as bipolar transistors, relays, combinations of bipolars and relays, MOSFETs, or provide a logic output. If the application requires triggering an event when the gate is blocked (for instance, in a burglar alarm or a multistage coilgun), the output must be inverted. This can be achieved using a small bipolar transistor configured in an inverting setup or by swapping the positions of the phototransistor and the resistor, so that the voltage drops below VCC/3 when blocked. The formula to determine the resistance required to turn off at Icollector is R = VCC / (Icollector * 3).

The circuit utilizes a phototransistor sensitive to infrared light, which acts as a light sensor. When IR light falls on the phototransistor, it allows current to flow through, creating a voltage drop across the connected resistor. This voltage drop is crucial for the operation of the 555 timer, which is configured in a monostable or astable mode depending on the application. The choice of the resistor value is critical as it sets the sensitivity of the light detection. The relationship between the voltage drop, collector current, and resistance is fundamental for calibrating the circuit to respond to varying light levels.

In applications requiring precise light detection, a variable resistor (trimmer) can be included in the circuit to allow for fine adjustments to the threshold voltage. This enables the circuit to be tuned for specific light levels, enhancing its performance in different lighting conditions.

The 555 timer's output can be used to drive various loads, which can include relays for switching larger currents or controlling other electronic components. The versatility of the 555 timer allows it to be used in many applications, from simple timers to more complex control systems.

For scenarios where an inverted output is needed, the incorporation of a bipolar transistor in an inverting configuration is a practical solution. This arrangement allows the circuit to respond appropriately when the phototransistor is not illuminated, effectively triggering an alarm or activating a device when the IR light is blocked.

Overall, this circuit design provides a robust solution for light detection and control, leveraging the characteristics of the phototransistor and the capabilities of the 555 timer. Proper selection of components and configuration will ensure reliable performance in various applications.When the phototransistor is stroken by IR light it conducts and the voltage between the 1Mohm resistor(arbitrary) and the phototrans drops from VCC to lower values. When the voltage drops lower than VCC/3 the 555 is triggered and goes high (from 0 TO VCC). The amount of light that strike the phototrans necessary to bring his collector to VCC/3 is determined by the resistor (Vdrop = Icollector * R, so, if Vdrop= 2*VCC/3, the resistance needed to set the threshold on current is R=2*VCC/(Icollector*3). High sensibility phototrans would need a smaller resistor, and weaker phototransistors higher value resistor, you can also use a trimmer to set the on threshold level with precision.

The time of phototransistor isn`t critical. The 555 has high current capability and can drive various devices, such as Bipolars, relays, bipolars+relays, mosfets, mosfets + totem pole, or give a logic output (see pic). In case you need to trigger something when the gate is blocked (for example a burglar alarm, or a multistage coilgun) you need to invert the output, which is accomplished using a small bipolar transistor wired in an inverting setup (see pic) or swapping the positions of phototransistor with the resistor, so the voltage will drop under VCC/3 when blocked: The formula to determine the resistance to turn off at Icollector is R=VCC/(Icollector*3).

🔗 External reference