Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Microcontroller based electric bell ringing.

Status
Not open for further replies.

tapu

Full Member level 4
Joined
Sep 15, 2014
Messages
232
Helped
1
Reputation
2
Reaction score
1
Trophy points
18
Location
india
Activity points
1,749
Dear All,
I am switching 230v ac electric bell on particular alarm time by alarm clock circuit.But sometimes bell continously ringing does not stop.Here is a relay circuit.please reply.
(here i am using delay function to switch on & off bell)
rly.JPG
 

milan.rajik

Banned
Joined
Apr 1, 2013
Messages
2,528
Helped
540
Reputation
1,078
Reaction score
523
Trophy points
1,393
Activity points
0
Zip and post your complete code. Mention which MCU you are using.
 

xenos

Full Member level 4
Joined
May 9, 2015
Messages
212
Helped
82
Reputation
164
Reaction score
81
Trophy points
28
Location
127.0.0.1
Activity points
1,182
When the bell rings continously, the relay is engaged?
If yes, then the alarm clock is the problem.
Otherwise, the snubber is the problem.

What is the power requirement of the bell?
What do you use as an alarm clock?
Replace PNP transistor with NPN.
 

milan.rajik

Banned
Joined
Apr 1, 2013
Messages
2,528
Helped
540
Reputation
1,078
Reaction score
523
Trophy points
1,393
Activity points
0
Maybe MCU is hanging and WDT is not implemented in code.
 

tapu

Full Member level 4
Joined
Sep 15, 2014
Messages
232
Helped
1
Reputation
2
Reaction score
1
Trophy points
18
Location
india
Activity points
1,749
Dear sir,this code and project working in Proteus without any error.above problem observed sometimes in actual board.but can become trouble in future .here I am using 230v ac electric bell as alarm bell according to application.
(What is wdt).
 

engineerpervez1

Member level 5
Joined
Dec 26, 2010
Messages
84
Helped
15
Reputation
30
Reaction score
14
Trophy points
1,288
Location
Lahore Pakistan
Activity points
1,839
You have find if it is software problem or hardware problem.
when bell continuously ring you can measure the relay driver base emitter voltage, or you can add one led with a series current limiting resistor in parallel to relay to check.
Proteus simulation is not 100 % grantee the circuit real operation.
 

tapu

Full Member level 4
Joined
Sep 15, 2014
Messages
232
Helped
1
Reputation
2
Reaction score
1
Trophy points
18
Location
india
Activity points
1,749
Dear sir . one thing I noted during continuous ringing rtc(time) runs normally.that means controller does not hang.
 

xenos

Full Member level 4
Joined
May 9, 2015
Messages
212
Helped
82
Reputation
164
Reaction score
81
Trophy points
28
Location
127.0.0.1
Activity points
1,182
Is your mC decoupled? Have you got stable power supply that will not produce brown out when relay engages?
Post at least a photo of your pcb.
 

andre_teprom

Super Moderator
Staff member
Joined
Nov 7, 2006
Messages
9,237
Helped
1,151
Reputation
2,321
Reaction score
1,127
Trophy points
1,403
Location
Brazil
Activity points
53,768
You could increase the resistance value of base resistor.
 

tapu

Full Member level 4
Joined
Sep 15, 2014
Messages
232
Helped
1
Reputation
2
Reaction score
1
Trophy points
18
Location
india
Activity points
1,749
How much value of base voltage should be the ire to switch off bell in BC 557(PNP)transistor?
 

milan.rajik

Banned
Joined
Apr 1, 2013
Messages
2,528
Helped
540
Reputation
1,078
Reaction score
523
Trophy points
1,393
Activity points
0
If VBE is less than 0.6 or 0.7 V then transistor enters cut-off region.
 

tapu

Full Member level 4
Joined
Sep 15, 2014
Messages
232
Helped
1
Reputation
2
Reaction score
1
Trophy points
18
Location
india
Activity points
1,749
I use 104pf as decoupling capacitor.and transformer ,bridge rectifier in power supply.
 

tapu

Full Member level 4
Joined
Sep 15, 2014
Messages
232
Helped
1
Reputation
2
Reaction score
1
Trophy points
18
Location
india
Activity points
1,749
mcu stops when bell rings.

I have designed alarm clock to ring 230v ac electric bell.in program I used delay function to energies relay.many times MCU stops when alarm bell ring.can it be solved by using intrupt in program?
 

srizbf

Advanced Member level 5
Joined
Apr 3, 2010
Messages
1,995
Helped
417
Reputation
840
Reaction score
328
Trophy points
1,363
Activity points
10,985
Re: mcu stops when bell rings.

cannot solve this problem using interrupt.
already a forum thread and replies were given ,IMHO, for such question.
 

peter002

Member level 3
Joined
Mar 18, 2013
Messages
56
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Location
Hindusthaan
Activity points
1,765
Re: mcu stops when bell rings.

i hope u hav connected protection on the reay to prevent the cpu from any loss, or u shud use the triac for switching.. reverse emf in relay can cause the cpu to be damaged or even force it to get hang sm times..
 

shaiko

Advanced Member level 5
Joined
Aug 20, 2011
Messages
2,644
Helped
303
Reputation
608
Reaction score
297
Trophy points
1,363
Activity points
18,300
Re: mcu stops when bell rings.

It sounds like improper design of the electronic circuit.
Post the circuit's schematic.
 

bigdogguru

Administrator
Joined
Mar 12, 2010
Messages
9,831
Helped
2,348
Reputation
4,690
Reaction score
2,274
Trophy points
1,413
Location
Southwest, USA
Activity points
62,510
Re: mcu stops when bell rings.

I have designed alarm clock to ring 230v ac electric bell.in program I used delay function to energies relay.many times MCU stops when alarm bell ring.can it be solved by using intrupt in program?

It is difficult to offer any meaningful advice without examining a detailed schematic of your design, including all power supply sections.

Also your description is rather vague, particular the phrase:

...many times the MCU stops when the alarm bell rings.

By "stops" are you implying the microcontroller resets itself, or simply pauses execution until the software delay routine is completed?

Utilizing a timer in conjunction with an interrupt and Interrupt Service Routine is often preferable to utilizing a software delay routine.

Software delay routines, by their inherent nature, prevent the microcontroller from executing other tasks until the software delay routine is completed.

However, if the microcontroller is, at times, resetting itself when a relatively high voltage actuator is energized, it suggests there is a hardware design issue, particular either back EMF or EMI related.

Posting a detailed schematic of your design would certainly help clarify potential issues, as a flyback diode, aka freewheeling, suppressor, clamp diode, across the inductive load is considered essential in designs with inductive loads and a complete snubber circuit maybe required in cases involving EMI. A careful review of your designs power supply section should also be performed.


BigDog
 

MUKESH.K.S

Full Member level 1
Joined
Jan 31, 2014
Messages
98
Helped
14
Reputation
28
Reaction score
13
Trophy points
8
Location
KERALA
Activity points
607
When the i/p is low the base current will flow through the transistor.But when the i/p is high the base current will not stop because the controller i/p voltage at pin is less than 12v ,it should be 5v or 3.3v depend on your controller. Try to use npn transistor instead of pnp.
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top