Apologies for the generic subject and if the answer is obvious. This should be a simple circuit but I seem to have confused the heck out of myself with it.
I am using an Allegro A3144EUA hall effect sensor to detect a magnet. So far, this works well, but I have two questions:
-
When connecting the output pin to my Arduino, I believe I need a pull-up resistor (I am using 10k), right? This sensor is unipolar switching, meaning that it goes low when a magnet is close. My supply voltage is 5V regulated.
-
Do I need a diode between the pull-up resistor and the sensor to prevent current from flowing back into the output pin? When I measure the voltage of the output pin with no magnet near, it reads 3.2V (or there about), and when a magnet is near, I get 0V. If I add a pull-up resistor, aren't I essentially supplying voltage to the sensor's output? Does the value of the pull-up resistor factor in here somewhere? How do I know that the sensor will be able to "overwhelm" the pull-up resistor?