Society of Robots - Robot Forum

Electronics => Electronics => Topic started by: Admin on March 06, 2008, 08:16:22 AM

Title: got hall effect sensor recommendations?
Post by: Admin on March 06, 2008, 08:16:22 AM
I need to use a hall effect sensor to locate a magnet using a microcontroller. Basically, the sensor will be slowly waved in front of a magnet, and I want to detect the signal using ADC.

I haven't used a hall effect before, and was wondering if anyone experienced had any tips: things to watch out for, issues with signal frequency/amplitude, effective range, amplification tips and issues, etc.

I spent some time browsing through datasheets, but surprisingly there was no output data charts . . .
Title: Re: got hall effect sensor recommendations?
Post by: Kohanbash on March 06, 2008, 06:49:55 PM
Hi
I have used the UGN3020T Hall sensor. The range is only about 1/4inch, also you should put a 1K resistor between the +5v line and the output line to the micro.

Another approach is to use a magnetic reed switch, I got some generic ones from mcmaster last year that had a range of about 4inches.
Title: Re: got hall effect sensor recommendations?
Post by: Admin on March 06, 2008, 09:01:21 PM
Quote
also you should put a 1K resistor between the +5v line and the output line to the micro.
I noticed this resistor in a functional diagram of the hall effect sensor I [mostly randomly] chose to use. It didn't however say anything about it or suggest a value . . . how does the resistor affect the output?

It also suggested between a 10nF and 100nF cap between power and ground of the sensor to filter out noise.
Title: Re: got hall effect sensor recommendations?
Post by: Kohanbash on March 06, 2008, 09:35:40 PM
Quote
I noticed this resistor in a functional diagram of the hall effect sensor I [mostly randomly] chose to use. It didn't however say anything about it or suggest a value . . . how does the resistor affect the output?
So in this Hall (and apparently some others) the output is usually hi; and when exposed to a magnet the output goes low. Putting the the resistor between Vin and the output insures that the value going into the micro stays at logic 1. So in my case using +5v I used a 1K resistor so 5V/1Kohm=5mA.

Title: Re: got hall effect sensor recommendations?
Post by: Admin on March 06, 2008, 10:07:08 PM
So . . . its a voltage dividing resistor? Just like with a photoresistor and a resistor in series to get a signal?
Title: Re: got hall effect sensor recommendations?
Post by: Kohanbash on March 07, 2008, 04:57:45 PM
So I don't think that its really a voltage divider (in the normal sense) . I think its primary function is to force the output of the Hall (or input to the micro) to read correctly.
You can think of it as debouncing a switch
Title: Re: got hall effect sensor recommendations?
Post by: Soeren on March 09, 2008, 06:02:39 AM
Hi,


It's a pull up resistor.

Why not go with a linear Hall sensor? It will be far more precise (and there's no real reason for an A/D-C if you use a Hall Switch, just an I/O should be used for that).