Hall Effect Sensor Perhaps a question for Hippy

donrecardo

Senior Member
Hi
I said a question maybe for Hippy as after doing a search in this forum for hall effect it pulled up a post answered by Hippy that I think answered what I want but I just wanted to confirm it
I need to count rotations of a wheel . I have an Allegro A1104 hall effect switch that has the hall effect sensor, schmitt trigger and NMOS output transistor. My plan was to mount a magnet on the rear face of the wheel and place the sensor near its path hopefully to count the pulses as the magnet passes the sensor.
I dont think I have used an NMOS transistor before but looking at the diagram , had it been a normal NPN transistor I would have said it was wired as an open collector .

So am I right in thinking , all I need to do to interface it is connect its vcc and gnd pins to my 5v and 0v . and connect the output to an input on the picaxe , but tie that point also to the 5v rail through a pull up resistor of say 4k7 ?
I then assume that I will get a constant high on the input pin until the magnet passes the sensor when the input will blip low ?

Lastly , and not connected with Picaxe. The wheel I need to mount the magnet on is made of mild steel so is ferrous, Will the magnet just make the steel wheel appear to the hall sensor as one large magnet , or will it still have a higher magnetism as the magnet nears the sensor.? Put another way. will it still work even though the magnet is mounted on a ferrous material

Cheers
Don
 
Last edited:

jglenn

Senior Member
Just hook up the hall sensor and put a meter on the output, then move a magnet across, try both poles, only one should work.

I would guess the magnet on a steel wheel may cause problems. The flux circuit from the magnet is going to go thru the wheel, reducing the effective magnet strength, by confining the flux lines, at least on one side, thru the wheel.

It would probably help to mount the magnet on a plastic spacer, so it is away from the metal, if you have problems. Next time use aluminum or copper. Which incidently will short out magnetic fields due to eddy currents. They have brakes that work that way.
 

BCJKiwi

Senior Member
Just implemented some Allegro A1100 series hall effect sensors.

Yes, 5V on VCC supply, 0V Gnd, 10K pullup to 5V on Vout output. Output goes low (400 to 500 mV) when a S pole passes the sensor. download the Datasheet - check out the charts page 6, 7, 8 - most informative.

So there is a swing from 5V to 500mV and back with a passing S pole.
 

donrecardo

Senior Member
Thanks for the advice

Unfortunately it had to be steel for the wheels , its on a passenger carrying model locomotive and aluminium or copper wheels wouldnt last very long , though I could put a non magnetic spacer between the wheel and the magnet

I was planning on mounting the sensor to pass the magnet at a distance of about 6mm . and thought of using a neobdymium magnet as they seem to be high power for a small size
Have you any idea as to what sort of size the magnet needs to be . I have seen them as small as 1mm diameter by 1mm thick right up to great huge things that would hold up several Kgs .
I assumed that from the size of the sensor a 6mm diameter by 6mm thick would look about right but really I dont have a clue and I am just guessing.
What size did you use , and at what distance from the sensor

Regards
Don
 

jglenn

Senior Member
I have used ceramic magnets, nothing fancy, 1/4" diameter by about 3/16" thick.

The gap is all important, check the results. Supermagnets are ok as long as cheap. But they like to stick to any metal around, so sometimes too strong is bad. I used epoxy to mount, sort of embed the magnet if possible.

On a side note, they make analog hall sensors that are a trip. Better than opto devices because you don't need the LED drive current. The hall effect is cool.
 

goom

Senior Member
I think that you will actually get a stronger magnetic field by attaching it to a steel backing plate (the wheel in this case). Lee-Valley actually sells steel cups for their neobdymium magnets which supposedly increases their strength (as well as providing a convenient screw mount).
Even the 1/4" x 1/8" size is pretty strong. Why not just try one. At least they are very easy to mount on the wheel directly. They will not stick as well if you use a non-magnetic spacer.
 

jglenn

Senior Member
That is just a "pole piece", by itself will concentrate the flux. But sticking the magnet on a piece of metal will reduce the distance it's strength goes. Try it out.
 

goom

Senior Member
I took your advice and tried it out. I could not detect any difference in attrative force with the magnet attached to a cast iron tablesaw table, or the MDF extension table. I used a flexible steel ruler, and measured the distance from ruler tip to magnet which would just cause it to bend and make contact with the magnet.
Interesting!
 

goom

Senior Member
Here's a quote from Lee-Valley:
"When a magnet is placed in a ferromagnetic cup (Figure 3), the cup further magnifies the effect by eliminating the air gap (air is a poor conductor of magnetic fields) and brings both poles of the magnet to grip on the same surface. This is similar in principle to a horseshoe magnet. A rare-earth magnet in a steel cup provides four times the strength of a bare magnet. A cup provides a disc magnet the optimal magnetic flux focus into the smallest gap area."
http://www.leevalley.com/hardware/page.aspx?c=2&cat=3,42363&p=40077
Looks like a cup is definitely the way to go since it appears to concentrate the field, presumable just what is best for a Hall effect sensor.
 
I used a Hall effect sensor for the same purpose (meassure RPM) but it was in a model airplane engine and, at 10,000 RPM balancing the backplate of the spinner was a pain in the neck. So I switched to an infrared emitter/sensor combination from Fairchild.
="http://www.fairchildsemi.com/ds/QR/QRB1134.pdf"
You can get them from JAMECO for about $2.00US. And I'm sure that they are available at any distributor that carries Fairchild products. The attached schematic worked fine for me.
 

Attachments

Last edited:

BCJKiwi

Senior Member
@goom;
What is being described can also be purchased 'ready made' as a "pot magnet".
However they will not be suitable for a hall sensor as the hall sensor is pole sensitive and the pot magnet presents both poles at the face.

@donrecardo;
How big are the wheels - Solid or spoked?

If a large enough solid area exists, a hole could be drilled in the wheel near the rim parallel to the axle. Press in an aluminium or copper sleeve with the magnet inside the sleeve. you will find metal around the sides of the magnet will have much less effect on the magnetic flux presented at the face than metal at either face.

The magnets I have are neodymium 4mm dia and 5mm long. They switch the Allegro A1102EUA when the centreline of the magnet is about 4mm to the side of the centre of the Hall effect sensor - i.e. the sensor is low for about 8mm of travel of the magnet past the face of the sensor.

The 1104 has different magnetic specs from the 1102 so your experience will be different but the distance from magnet face to sensor face will be the most critical aspect.
 

jglenn

Senior Member
Goom:

I believe your experiment, but would say that cast iron does not have that good of magnetic properties, iron or steel conducts the flux better, and should "short out" the flux lines more. Plus you need a real field sensor, I have a little gauge I used to use in the eddy current field. Mechanical, but you can get electronic ones, like halls, too!
 

donrecardo

Senior Member
Thanks to every one for their help.
The hall sensors are due to arrive tomorrow and I ordered neodymium magnets in two sizes
6mm X 4mm and 10mm X5 mm so if the little buggers dont get ya the big ones should .

I will let you know how it all goes when they arrive

I had already tried slotted opto detectors which had built in logic and they worked well on the bench but because on my train the wheel sets were fitted with suspension it would be a devil of a game mounting the slotted sensor yet still allowing for the suspension travel

@ BCJKiwi the wheels are solid , approx 110mm diameter and about 10mm thick or if you prefer about 4 &1/4" by 3/8" in English money

I will try mounting a magnet onto a steel wheel and if it fails will try the idea of drilling the wheel to take the magnet in a copper or aluminium sleeve as sugested

Regards
Don
 

jglenn

Senior Member
If your train has a PM motor, you can use it as a tach, but you need pwm. During the off times a filtered back emf signal is proportional to speed. But it sounds like you are on your way with the halls.
 

SD2100

New Member
I've been using hall sensors with the magnets glued directly to steel flanges on a gearbox output shafts for about 3 years with no problems. The magnets are very small ones salvaged from 3.5" disc drives, I drilled a small dimple in the flange with a 3mm drill then glued the magnet in with Araldite. The sensors I'm using are UGN3503 set at about 2mm from the magnets, the flange diameter is about 100mm and varies from 0 to 2800 rpm, I have each sensor connected to an 08m.
 

donrecardo

Senior Member
Thanks to everyone for their help

The magnets arrived this morning and they are triggering the hall effect sensor fine

Don
 
Top