Build a Custom Timer Circuit for Efficient Light Control - Step by Step Guide"

  • Thread starter Thread starter Liad
  • Start date Start date
AI Thread Summary
The discussion focuses on building a custom timer circuit to control a light bulb with adjustable on and off periods of 5, 10, 15, or 20 minutes. Users will utilize two buttons to set the timing, with a counter displayed on four 7-segment displays indicating the remaining time. A microcontroller with sufficient I/O pins is recommended for this project, with suggestions for models like the ATMEL ATmega32 or Microchip 16F877A. Programming the microcontroller is essential, and various programming tools and resources are available to assist users. The conversation emphasizes the importance of selecting the right microcontroller based on pin count and required peripherals.
Liad
Messages
23
Reaction score
0
Hey!

I want to build a circuit to control a light bulb in such a way that Ill be able to choose the time that it'll be on [choosing from 5/10/15/20 min] and off [again, choosing from 5/10/15/20 min].

I would also like to have a counter showing how much time I have till it'll change from on to off or from off to on.

for example, I'll have 4 7-segments display and 2 buttons.
the first button will change the period of time the light will be on and every click will change the time and present it with the 7-segments.
the second button will change the period of time the light will be off and every click will change the time and present it with the other 7-segments.

Ill push the first button till ill see "5" and the other one till Ill see "10", then itll start work for 5 minutes, while showing me how much time left from that 5 min, and afterward will stop working for 10 min, showing the time left before operating again and so on.


Any help will be greatly appreciated.
 
Engineering news on Phys.org
Liad said:
Hey!

I want to build a circuit to control a light bulb in such a way that Ill be able to choose the time that it'll be on [choosing from 5/10/15/20 min] and off [again, choosing from 5/10/15/20 min].

I would also like to have a counter showing how much time I have till it'll change from on to off or from off to on.

for example, I'll have 4 7-segments display and 2 buttons.
the first button will change the period of time the light will be on and every click will change the time and present it with the 7-segments.
the second button will change the period of time the light will be off and every click will change the time and present it with the other 7-segments.

Ill push the first button till ill see "5" and the other one till Ill see "10", then itll start work for 5 minutes, while showing me how much time left from that 5 min, and afterward will stop working for 10 min, showing the time left before operating again and so on.


Any help will be greatly appreciated.

You can do this pretty easily with just a microcontroller (one with enough I/O pins for your 7 segment displays). Or you could go with a few 7-segment display decoder chips if you want a smaller microcontroller / pins for doing something else. You'll need to do a fair bit of programming however.
 
MATLABdude said:
You can do this pretty easily with just a microcontroller (one with enough I/O pins for your 7 segment displays). Or you could go with a few 7-segment display decoder chips if you want a smaller microcontroller / pins for doing something else. You'll need to do a fair bit of programming however.

Which microcontroller has enough pins for all of my demands?
Can you give me a specific model?
 
Liad said:
Which microcontroller has enough pins for all of my demands?
Can you give me a specific model?

Well, assuming you're not doing anything to reduce pin count, you should be doing the analysis on how many pins you'll need for your display:

-4 7-segments = 4*7
-3 push buttons = 3
-Other LEDs = 1-5

So, something like 30+ I/O lines.

Then you go to your favourite microcontroller manufacturer and START with your I/O pin count, choosing the one which has the peripherals and on-board memory / FLASH / EEPROM you need.

If you've never worked with microcontrollers before, most microcontroller manufacturers make a 40-pin part, e.g. ATMEL ATmega32, ATmega644, Microchip 16F877A or 18F425) Unfortunately, 40-pin is the max that most manufacturers make nowadays that still come in DIP (dual in-line pin) packages. Which one should you go for? In some ways, that's like asking fans which sports team is the best.

But you'll need some way of programming them. The AVRisp mkII is pretty good, and capable of programming most ATMELs (there's also a GCC-based C compiler for it). Programming PICs are a little more hit and miss, but various homebrew programmers (and semi-pro kit-based ones) exist that can program various PICs. There is a Microchip C compiler for the PIC18 (and PIC32), but they were designed from the get go to be assembler machines (as opposed to the ATMELs which were designed to be high-language machines).

You can rest easy that various forums exist on the web to help you along with whatever microcontroller you go with, and whatever language you decide to program it in. Unless you go with something really obscure.
 
Hi all I have some confusion about piezoelectrical sensors combination. If i have three acoustic piezoelectrical sensors (with same receive sensitivity in dB ref V/1uPa) placed at specific distance, these sensors receive acoustic signal from a sound source placed at far field distance (Plane Wave) and from broadside. I receive output of these sensors through individual preamplifiers, add them through hardware like summer circuit adder or in software after digitization and in this way got an...
While I was rolling out a shielded cable, a though came to my mind - what happens to the current flow in the cable if there came a short between the wire and the shield in both ends of the cable? For simplicity, lets assume a 1-wire copper wire wrapped in an aluminum shield. The wire and the shield has the same cross section area. There are insulating material between them, and in both ends there is a short between them. My first thought, the total resistance of the cable would be reduced...
I am not an electrical engineering student, but a lowly apprentice electrician. I learn both on the job and also take classes for my apprenticeship. I recently wired my first transformer and I understand that the neutral and ground are bonded together in the transformer or in the service. What I don't understand is, if the neutral is a current carrying conductor, which is then bonded to the ground conductor, why does current only flow back to its source and not on the ground path...
Back
Top