Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Microcontroller reset

Status
Not open for further replies.

leonel

New Member
Hi...
I'm facing a big problem with reset condition on PIC16F57, this is, when i turn on a motor by a relay sometimes my microcontroller makes a reset. I faced the same problem in PIC16F872 and i solved with a 4,7uF capacitor in MCLR pin, but in PIC16F57 doens't work.
Does anybody had this kind of problem?
What i have to do?
 
Hi,
I think what you meant to do was install a 4.7k RESISTOR on MCLR to pull it high. Also make sure you have a bypass capacitor close to the pic across Vdd and Vss.
You might also want to put a capacitor and or a diode across any inductive loads that the pic might see.
 
leonel said:
Hi...
I'm facing a big problem with reset condition on PIC16F57, this is, when i turn on a motor by a relay sometimes my microcontroller makes a reset. I faced the same problem in PIC16F872 and i solved with a 4,7uF capacitor in MCLR pin, but in PIC16F57 doens't work.
Does anybody had this kind of problem?
What i have to do?

Is the power supply to the microcontroller well regulated? If not, the supply may droop when the relay/motor kicks in (even just briefly), causing the microcontroller to reset.
 
Three likely causes, which have NOTHING to do with the MCLR pin:
1. You forgot to put a flyback diode on the relay coil. When switched off, the stored flux in the coil will make current flow into the PIC pin and cause reset or latch-up. Put a flyback diode on the coil.
2. The EMI from the motor is spiking the PIC's Vdd pin. Make sure you have a ceramic cap (0.1uF is good) between Vdd and Vss. There are many other measures that can be taken to isolate motor spikes from the supply but this is the first thing to try.
3. The motor draws enough current to lower the battery voltage to a level where the PIC won't function. If it's only a matter of startup current AND there's no way the load will increase suddenly and stall the motor, then you may be able to fix it with capacitance, otherwise only a better battery will fix it.
 
Well, i think i sovve my problem.
I have a 78L05 well regulated output with a 10nF ceramic capacitor between +5V and GND, also i also have flyback diodes across inductive loads.
What i did was to increase a little bit my MCLR pin with a diode. (likely the cause was the MCLR pin voltage decrease a little bit). I saw in datasheet and Voltage on MCLR with respect to VSS can go to +13.5V
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top