• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

Homemade Circuit Projects

Get free circuit help 24/7

  • 1000+ Circuits
  • Privacy Policy
  • About Us
  • Contact
  • Disclaimer
  • Videos – Circuit Test Results
You are here: Home / Sensors and Detectors / 4 Automatic Day Night Switch Circuits Explained

4 Automatic Day Night Switch Circuits Explained

Last Updated on April 29, 2020 by Swagatam 38 Comments

The 4 simple light activated day night switch circuits explained here can all be used for controlling a load, normally a 220V lamp, in response to the varying levels of the surrounding ambient light.

The circuit can be used as a commercial automatic street light control system, as a domestic porch light or corridor light controller or simply can be used by any school kid for displaying the feature in his school fair exhibition.The following content describes four simple ways of making a light activated switch using different methods.

1) Light Activated Day Night Switch using Transistors

The first diagram shows how the circuit can be configured using transistors, the second and the third circuits demonstare the principle by using CMOS ICs while the last circuit explaines the same concept being implemented using the ubiquitous IC 555.

Let’s evaluate the circuits one by one with the following points:

The first figure shows the use of a couple of transistors in association with a few other components lke resistors for the construction of proposed design.

automatic day night street lamp circuit using only transistors

The transistors are rigged as inverters, meaning when T1 switches, T2 is switched OFF and vice versa.

The transistors T1 is wired as a comparator and consists of an LDR across its base and the positive supply via a preset.

The LDR is used for sensing the ambient light conditions and is used for triggering T1 when the light level crosses a particular set threshold. This threshold is set by the preset P1.

The use of two transistors particularly helps to reduce the hysteresis of the circuit which would have otherwise affected the circuit if only a single transistor would have been incorporated.

When T1 conducts, T2 is switched OFF ans so is the relay and the connected load or the light.

The opposite happens when the light over the LDR falls or when darkness sets in.

Parts List:

  • R1, R2, R3 = 4k7 1/4 watt
  • VR1 = 10k preset
  • LDR = any small LDR with around 10k to 50k resistance in day light (under shade)
  • C1 = 470uF/25V
  • C2 = 10uF/25V
  • All diodes = 1N4007
  • T1, T2 = BC547
  • Relay = 12V, 400 ohms, 5 amp
  • Transformer = 0-12V/500mA or 1 amp

2) Light Activated Day Dark Switch using CMOS NAND gates and NOT Gates

The second and the third figure incorporates CMOS ICs for executing the above functions and the concept remains rather similar. The first circuit out of the two utilizes the IC 4093 which is quad two-input NAND gate IC.

Each of the gates are formed into inverters by shorting its both the inputs together, so that the input logic level of the gates now get effectively reversed at thie outputs.

Though a single NAND gate would be enough for implementing the actions, three gates have been engaged as buffers for getting better results and in a view of utilizing all of them as in any case three of them would be left idle.

The gate which is responsible for the sensing can be seen accompanied with the light sensing device LDR wired across its input and the positive via a variable resistor.

This variable resistor is used for setting the triggering point of the gate when the light falling over the LDR reaches the desired specified intensity.

As this happens, the gate input goes high, the output consequently becomes low making the outputs of the buffer gates high. The result is the triggering of the transistor and the relay assembly. The connected load over the relay now flips into the intended actions.

The above actions are exactly replicated using the IC 4049 which is also wired with similar configuration and is quite explanatory.

Parts List

  • R1 = Any LDR with resistance of around 10k to 50k in day light (under shade)
  • P1 = 1M preset
  • C1 = 0.1uF ceramic disc
  • R2 = 10k 1/4 watt
  • T1 = BC547
  • D1 = 1N4007
  • Relay = 12V, 400 ohm 5 amp
  • ICs = IC 4093 as in the first example or IC 4049 as in the second example

3) Light Activated Relay Switch using IC 555

The last figure illustrates how the IC 555 may be configured for executing the above responses.

Video Clip demonstrating the practical operation of the above IC555 based day night automatic lamp circuit

https://www.youtube.com/watch?v=nmhOs6OeNR4&feature=youtu.be

Parts List

  • R1 = 100k
  • R3 = 2m2
  • C1 = 0.1uF
  • Rl1 = 12V, SPDT,
  • D1 = 1N4007,
  • N1----N6 = IC 4049
  • N1----N4 = IC 4093 IC1 = 555

4) Automatic Night Operated LED Lamp Circuit

This fourth circuit is not only simple but very interesting and very easy to build. You might have seen the new flashlights manufactured with new high bright high efficiency LEDs.

The idea is to achieve something similar but with an added feature.

Functioning Details

To make our circuit operative after dark, a phototransistor is employed, so that when the daylight is void, the LED gets switched ON.

To make the circuit extermely compact one button battery type is preferred here, quite akin to those used in calculators, watches, etc.

Understanding the diagram:

As long as ambient light illuminates the phototransistor, the voltage at its emitter lead is sufficiently high for the base of PNP transistor Q1 to keep it shut off.

However when darkness sets in, the phototransistor starts losing conduction and the voltage at its emitter diminishes causing the phototransistor to slowly switch OFF.

This prompts Q1 to begin getting the biasing via its base/ground resistor R and it starts to illuminate brightly as darkness gets deeper.

In order to control the level of the ambient light for which the LED may be desired to be switched ON, he resistor R values may be varied until the desired level is satisfied. Putting a potentiometer may not be recommneded, just to ensure a compact and sleek dimension of the unit.

The circuit may consume approximately 13 mA when the LED is illuminated and just a few hundred uA when its switched OFF.

Circuit Operation

Bill of material for the discussed automatic night operated LED lamp.

- 1 PNP BC557A
- One compatible phototransistor
- 1 super bright white LED
- 1 battery 3V coin
- One 1K resistor




Previous: Hi-Fi 100 Watt Amplifier Circuit Using 2N3055 Transistors – Mini Crescendo
Next: Variable Voltage, Current Power Supply Circuit Using Transistor 2N3055

About Swagatam

I am an electronic engineer (dipIETE ), hobbyist, inventor, schematic/PCB designer, manufacturer. I am also the founder of the website: https://www.homemade-circuits.com/, where I love sharing my innovative circuit ideas and tutorials.
If you have any circuit related query, you may interact through comments, I'll be most happy to help!

You'll also like:

  • 1.  Linear Hall-Effect Sensor – Working and Application Circuit
  • 2.  How to Make a Simple Metal Detector Using IC CS209A
  • 3.  3 Easy Capacitive Proximity Sensor Circuits Explored
  • 4.  4 Simple Proximity Sensor Circuits – Using IC LM358, IC LM567, IC 555
  • 5.  How to Make a Ghost Detector Circuit
  • 6.  AC Phase, Neutral, Earth Fault Indicator Circuit

Please Subscribe (Only if you are Genuinely Interested in our Newsletters)


 

Reader Interactions

Comments

    Your Comments are too Valuable! But please see that they are related to the above article, and are not off-topic! Cancel reply

    Your email address will not be published. Required fields are marked *

  1. Search Related Posts for Commenting

  2. Dr. LUKE THOMAS says

    Dear Mr. Swagatam,

    I am a retired senior citizen, an ex – Government employee. Though a Registerd Medical Practitioner, at present I am spending my time to design an equipment to do ‘ Non invasive knee repairs. ‘ It is almost in the final stages. My equipment is intended to produce synovial fluid. One of the reasons for knee pain in elderly people is insufficient synovial fluid.

    When I was searching for a simple oscillator circuit, I came across your website. I have gone through some of your circuits and explanations.

    You are doing a great work in teaching practical electronics, simple and beautiful. Hats off. Please keep it up.

    With love and regards

    Dr. Luke Thomas

    Reply
  3. Paul says

    Hello Swagatam,
    In the above circuit 4) Automatic Night Operated LED Lamp Circuit, please could you explain to me why the Q1 emitter is connected to positive and the collector to the load and ground. All of the PNP circuits I have built so far have the collector to +V and the emitter and load to ground.
    Thanks in advance.

    Reply
    • Swagatam says

      Hello Paul, the emitter of PNP is always with reference to the positive line, and its collector is always towards the negative or the ground line, and for NPN the emitter is always with reference to the ground or 0V line.
      PNP collector can never be associated with the positive line, that can never work.

      Reply
      • Paul says

        Hello Swagatam and thanks for the quick reply.
        I’m still confused as what you say is how I understood PNP transistors to work but digging deeper into this, I’ve found several articles which suggest that the arrangement where the collector is connected to V+ and the emitter to load and ground does work although with a greatly reduced gain factor, and I have constructed your circuit with the c and e connected in both directions with success. Odd!

        Reply
        • Swagatam says

          Hello Paul,
          there’s no way you can make a PNP conduct by connecting its emitter with the negative line, and collector load with the positive line. It is like trying to use a diode by applying positive to its cathode and the load to its anode and negative line.

          Reply
          • Paul says

            Hello Swagatam
            Rest assured I can prove this – I will send you a video if you wish. Please consider my earlier comment about loss of gain – this is documented here: https://electronics.stackexchange.com/questions/29756/bjt-in-reverse-active-mode-of-operation
            I appreciate this document is for a NPN but the same applies for a PNP.
            Thanks

            Reply
            • Swagatam says

              Hello Paul, No matter what anybody says, it’s no point discussing something which unnatural, abnormal and nontechnical. In electronics I will believe and follow only those concepts which makes sense and is recommended by the researcher and the manufacturer.

  4. Sarwana says

    Hello Mr. Swag , I use the 555 circuit and work fine can it be supplied with a transformerless power supply ? in this post https://www.homemade-circuits.com/cheap-yet-useful-transformerless-power/
    Sorry my english is not good

    Reply
    • Swagatam says

      Hell Sarwana, yes that may be possible. You can try the first transformerless power supply design, but make sure to change the 50 ohm resistor to 5 ohms resistor, and use a 5 watt zener instead of 1 watt.

      Reply
  5. Umar says

    I want to use it for providing light for 12-16 hrs per day requirement.
    Hen actually needs 12-16 hrs of light for cycle that need for egg laying. During winters daylight is shorter and as sun set it will automatically switch on the light and switch it on till 12-16 hrs of total light (including natural sun light + artificial light) have been completed.

    Reply
  6. Ariv says

    In project number 1 (with transformer), why using R3? What if only using R2 (R3 removed)?

    Reply
    • Swagatam says

      You can remove R3, it will still work

      Reply
  7. Seun says

    Hello sir Swag, can this light sensor circuit respond to my neighbour’s light bulb source.

    Reply
    • Swagatam says

      Hello Seun, yes definitely, if the light source is bright enough, to prevent this you should put the LDR inside a pipe like enclosure so that it sees only the ambient light and no other artificial light

      Reply
  8. Rabah BOURETT says

    Thank you Mr SWAGATAM for your fast replay and for the added listing of parts. So
    while I was thinking about the execution of the project N°2, I have got the Idea to ask you what can we add to the diagram to get the special lights remote controled instead of its dependance to the day light, I mean to switch between ON and OFF at any time with a remote controle device, any one, of course something simple.
    Salutations.

    Reply
    • Swagatam says

      Hello Rabah, Remote control is possible by integrating any preferred remote control circuit output with the relay driver stage.

      You can find many remote circuits here:
      https://www.homemade-circuits.com/?s=remote+control+simple

      Reply
  9. Rav Denver says

    Good day sir swag? I’m here again and I need your help in regarding to 220v automatic street light by using of BT136/ BT138. Sir base on the project that I see in YOUTUBE. What do you think about the BT 136/ 138, this can work for 220v to ON n OFF the led bulb? Thank you

    Reply
    • Swagatam says

      Hi Rav, yes it should work but you must connect a triac correctly as indicated in the following example:

      triac based day night switch trigger circuit

      Reply
      • Rav Denver says

        Hello sir swag, actually the circuit that I see is only 3 pcs parts or 4. A bt 136, resistor, and ldr which is connected to direct 220v. The ldr connected to T1 and Gate. While the bulb connected to T1 and T2. It is possible to switch on the bt136 in dark place/night? Thank you

        Reply
        • Swagatam says

          Hi Rav, you can try the following configuration, it should work.

          triac, diac LDR automatic night lamp circuit

          It was designed by Mr. D MohanKumar

          Reply
          • Rav Denver says

            Thank you very much sir swag for your always free of time to answer my query. After I test this circuit you give, I’ll give you the feedback for the result of my test. Thank you again sir.

            Reply
            • Swagatam says

              No Problem Rav, wish you all the best!

  10. papaciela says

    Hi Swag,

    A bad manip…. Here again my question:

    Can I change R3 by a variable resistor or potentiometer if I want to use different light ambient intensity to adjust the threshold that will activate the relay. What would be the range value of this component to obtain this.

    Thank’s and regards

    Reply
    • Swag says

      Hi Papa Ciela, thanks for posting your question again! If you are referring to the IC 555 circuit, you can replace R1 with a 1M pot for getting the required adjustments.

      R3 and C1 are placed for implementing a slight delay in the operation, so that the relay does not vibrate during twilight transitions.

      Reply
      • papaciela says

        Hi Swag,
        You answer at the light speed !!!

        Thank you so much !!

        Reply
        • Swag says

          You are welcome Claude!

          Reply
  11. Faith Jumbo says

    lease the pin 7 and 5 connected with a resistor are not taken to ground and the pin 1 again can i use preset in place of one connected to pin 2 thanks

    Reply
    • Swagatam says

      pin7 and 5 should be exactly as shown, they shouldn't be grounded.

      Pin#1 line is the negative supply line.

      1M preset can be used with pin#2

      Reply
  12. fasat2112 says

    Hello,

    Can you tell for the first diagram what are R1, R2, R3 and VR1 values?

    Thank you

    BR

    Reply
    • Swagatam says

      you can refer to this article for more info:

      https://homemade-circuits.com/2011/12/super-simple-light-activated-switch.html

      Reply
  13. tristan pagdanganan says

    can you help me how to make LDR opposite ? in a way that when the loght come through the LDR the electricity cant flow or turn off and when the LDR sense dark the electricity can flow or turn on…?

    Reply
    • Swagatam says

      in the above shown diagrams, you just need to change the position of the lDR from the upper arm of the preset to the lower arm of the preset or vice versa for getting the desired results

      Reply
  14. Sasa Hadia says

    Hello swagatam
    I know what is LDR function but I don't know how to buy it and what is its name in the market.
    Can you please sho me its name in the market.
    Thank you

    Reply
    • Swagatam says

      Hello Sasa,

      It's called LDR everywhere, even the shopkeeper will know this and identify this component as LDR only, so you can tell him this name.

      Reply
  15. Keenmer Jon Serrano says

    @Swagatam Majumdar what is the value of resistor and the variable (potentiometer) in figure no.1 please help my for my project to be submit in monday please

    Reply
    • Swagatam says

      Please check the following link for the details:

      https://homemade-circuits.com/2011/12/super-simple-light-activated-switch.html

      Reply
  16. Mukesh says

    hi can you elaborate please cant understand your reply..for LDR

    Reply
    • Swagatam says

      make the last 555 circuit given in the above article, interchange R1 and the LDR positions, remove the relay and use the positive supply coming out from its pin3 to power the flasher circuit meaning the flasher circuit's positive line will get powered from the above circuits pin3 and NOT from any external 12V source. This configuration will shut off the LEDs during day and vice versa.

      Reply


  17. COMMENT BOX IS MOVED AT THE TOP


Primary Sidebar

Electronic Projects Categories

  • 3-Phase Power (15)
  • 324 IC Circuits (19)
  • 4017 IC Circuits (51)
  • 4060 IC Circuits (25)
  • 555 IC Circuits (92)
  • 741 IC Circuits (18)
  • Amplifiers (49)
  • Arduino Engineering Projects (82)
  • Audio Projects (83)
  • Battery Chargers (75)
  • Car and Motorcycle (87)
  • Datasheets (44)
  • Decorative Lighting (Diwali, Christmas) (31)
  • DIY LED Projects (81)
  • Electronic Components (96)
  • Electronic Devices and Circuit Theory (34)
  • Electronics Tutorial (99)
  • Fish Aquarium (5)
  • Free Energy (34)
  • Games (2)
  • GSM Projects (9)
  • Health Related (17)
  • Heater Controllers (23)
  • Home Electrical Circuits (98)
  • Incubator Related (6)
  • Industrial Electronics (25)
  • Infrared (IR) (39)
  • Inverter Circuits (94)
  • Laser Projects (10)
  • LM317/LM338 (21)
  • LM3915 IC (24)
  • Meters and Testers (52)
  • Mini Projects (152)
  • Motor Controller (64)
  • MPPT (7)
  • Oscillator Circuits (12)
  • PIR (Passive Infrared) (8)
  • Power Electronics (32)
  • Power Supply Circuits (65)
  • Radio Circuits (9)
  • Remote Control (46)
  • Security and Alarm (55)
  • Sensors and Detectors (115)
  • SG3525 IC (4)
  • Simple Circuits (72)
  • SMPS (30)
  • Solar Controllers (60)
  • Timer and Delay Relay (51)
  • TL494 IC (5)
  • Transformerless Power Supply (8)
  • Transmitter Circuits (37)
  • Ultrasonic Projects (12)
  • Water Level Controller (45)

Follow Homemade Circuits

Facebook
Twitter
YouTube
Instagram
My Facebook-Page
Quora

Feeds

Post RSS
Comment RSS

Circuit Calculators

  • AWG to Millimeter Converter
  • Battery Back up Time Calculator
  • Capacitance Reactance Calculator
  • IC 555 Astable Calculator
  • IC 555 Monostable Calculator
  • Inductance Calculator
  • LC Resonance Calculator
  • LM317, LM338, LM396 Calculator
  • Ohm’s Law Calculator
  • Phase Angle Phase Shift Calculator
  • Power Factor (PF) Calculator
  • Reactance Calculator
  • Small Signal Transistor(BJT) and Diode Quick Datasheet
  • Transistor Astable Calculator
  • Transistor base Resistor Calculator
  • Voltage Divider Calculator
  • Wire Current Calculator
  • Zener Diode Calculator

© 2021 · Swagatam Innovations

We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.Ok