Weird input situation in a PIC circuit

Click For Summary
SUMMARY

The discussion focuses on troubleshooting a PIC circuit where output pins activate unexpectedly when a magnetic reed switch is open. The issue was identified as a floating input pin due to a broken link in the circuit. The solution involved repairing the connection and ensuring proper use of a pull-up/down resistor, with a recommended value between 10-100K ohms. The user successfully resolved the problem by restoring the link between the switch and the resistor, confirming the importance of maintaining circuit integrity to avoid floating inputs.

PREREQUISITES
  • Understanding of PIC microcontroller functionality
  • Knowledge of circuit design principles, specifically input pin configurations
  • Familiarity with pull-up and pull-down resistor applications
  • Basic troubleshooting skills for electronic circuits
NEXT STEPS
  • Research the effects of floating inputs in digital circuits
  • Learn about proper resistor values for pull-up and pull-down configurations
  • Explore advanced debugging techniques for PIC microcontrollers
  • Study circuit integrity and its impact on microcontroller performance
USEFUL FOR

Electronics enthusiasts, hobbyists working with PIC microcontrollers, and anyone involved in circuit design and troubleshooting.

Zalajbeg
Messages
77
Reaction score
3
Hey everyone,

I have built a circuit which includes a PIC. The logic is that if a specific pin gets a logic 1, the output pins will be activated and LED lights will flash. I am controlling the input pin with a magnetic reed switch.

It was working great few days ago. However today the output pins are activated even if the reed switch is open. The weird thing is that when I want to check the voltage in the input pin (I am linking one prob to the pin and the other one to the ground) the output pins stop.

What can be the issue? I don't know why linking a theoretically infinitive resistance parallel to the circuit cause this stop. Could you please help me?

Additional information: I plugged out the switch but it still activates the output pins. I broke the link and it still activates when I touch pin.
 
Last edited:
Engineering news on Phys.org
You probably need a pull-up/down resistor on your switch input pin. 10-100K oughta do the trick.

If you already have that in place, then we need a lot more information about your circuit and software.
 
schip666! said:
You probably need a pull-up/down resistor on your switch input pin. 10-100K oughta do the trick.

If you already have that in place, then we need a lot more information about your circuit and software.

First of all I thank you very much for your reply. There had already been a resistor (4.7k) however I find out that the link was broken. When I fixed the link between the switch and the resistor it worked great. When I was a newbie to the topic someone mentioned about the floating situation and I experienced it with this broken link.
 

Similar threads

  • · Replies 14 ·
Replies
14
Views
2K
  • · Replies 3 ·
Replies
3
Views
2K
Replies
37
Views
7K
  • · Replies 9 ·
Replies
9
Views
2K
Replies
12
Views
3K
Replies
10
Views
2K
  • · Replies 11 ·
Replies
11
Views
2K
Replies
7
Views
3K
Replies
26
Views
2K
Replies
2
Views
2K