LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Hall effect gaussmeter

Solved!
Go to solution
Hey everybody! :smileyvery-happy:
 
I'm a total LabView newbie, so maybe my question is probably answered in about a dozen places.  All help is appreciated, and please feel free to point me to other threads/tutorials/examples.
 
What i'm trying to do is simulate a gaussmeter via labview.I have a hall effect sensor from honeywell,model  ss496a1 and a daq(NI USB-6008).How exactly can i build my gaussmeter?I know i have to supply my sensor with a Vc and then measure Voutunder the presence of a magnetic field,but i cant because obviously i'm doing something wrong!Can anyone tell me the exact steps i have to go through?
 
Many thanks in advance!
0 Kudos
Message 1 of 35
(4,802 Views)

First, you should try to be as specific as possible about your problem.  What have you tried?  Exactly what does not work?  What error messages do your get?  Does it work but produce incorrect results?  How do you know they are incorrect?

 

The sensor draws about 8.7 mA when supplied with 5 V.  Its output is 2.500 V (bias) with 2.5 mV/G (signal) superimposed.

 

The USB-6008 has a 12-bit converter and several ranges.  The +/-4 V range is probably the one you would use since the signal voltage can exceed 2.5 V.  On that range 12-bit resolution means that the least significant bit (LSB) is equal to 1.95 mV.  So your resolution is on the order of 1 gauss.  Of course if you have noise, drift in the supply, or other problems you may not get performance that good.

 

It looks like your equipment should allow you to make some filed measurements, so let us know where you are having problems.

 

Lynn 

Message 2 of 35
(4,781 Views)

First of all,i want you to know that i am a total newbie to both labview and hall effect measurements.

So at first,i dont even know if my block diagram at labview is right.I attach my first thought of what it could look like.

My second problem after the block diagram,is how exactly can i connect my equipment..Is it ok if i simply connect a 5V battery to the sensor,then the sensor to the daq?

I tried those described above,but it doesnt seem to react to any present magnetic field.I know i must have done some serious mistakes,so please dont be too strict about what i've tried to do..I would appreciate all help that can be given!

0 Kudos
Message 3 of 35
(4,768 Views)

1. I cannot tell how you have the DAQ Assistant configured because it is not available on my platform.

 

2.  You can power the sensor from a battery.  5 V is not a standard battery voltage.  Are you regulating the voltage from a higher voltage battery?  Make sure the you connect the negative terminal of the battery to the ground connection of the DAQ device.

 

Since you are a beginner, I would suggest that you separate the tasks so that errors in one do not confound the other.  First connect the sensor to the battery and measure the output with a voltmeter.  Do you get an output which is about half of the battery voltage?  Does it change with magnetic field?   When you get "yes" answers to both of these questions, then work on the program.  Do you see anything on the graph when you run the program?  Does it match the voltage you connected to the input of the USB-6008?  (Try connecting a 1.5 V battery = AA cell to the input.)  If you do not get anything, try running one of the Analog Input example VIs which ship with LV.

 

Lynn 

0 Kudos
Message 4 of 35
(4,758 Views)

Add a small Wait function (50ms) in your loop so your program does not hog up 100% CPU time. Also, take out the Write to Measurement File until you know you have your hardware setup correctly.

 

The USB-6008 has a +5V output, up to 200mA, plenty for your sensor. Maybe put a current limiting resistor in line with your sensor to prevent drawing too much current in case of a short/faulty sensor?

 

Other than that, it seems you are on the right track. I didn't check the specs on your sensor, are you sure that you are using a strong enough magnet to measure?

 

Robot Happy 

Message Edited by Greg at NI on 10-08-2009 02:24 PM
National Instruments
LabVIEW
Certified Developer
0 Kudos
Message 5 of 35
(4,757 Views)

 As far as your question are concerned johnsold,i connected the sensor to the battery and measured the output with a voltmeter and yes,i did get a measurement about half of the voltage.and also yes,it changed with tha presence of a magnet.My biggest problem though,is with the program itself.

I connected the daq.then i connect the sensor with the battery.then i insert the sensor(the ground and output pins) to the daq.shouldn't my graph change with the presence of the magnet again like before?!well it doesn't!That's why i think there's a problem with my program..

 

0 Kudos
Message 6 of 35
(4,738 Views)
I've managed to make the correct program finally and make it work!What i'm trying to do now is to set a scale for my numeric indicator.I've added 4 buttons and a numeric indicator that indicates my signal.How exactly can i connect them so that my indication will be scaled differently when pressing different buttons?Here's what i'm tyrying to do(probably with the wrong connection between buttons and indicator....)
0 Kudos
Message 7 of 35
(4,706 Views)

Great!

 

I suggest that a radio button and property nodes for Scale: Maximum and Scale: Minimum may be the way to get what you want. Also, using the event structure will allow you to only change the scale when one of the buttons is pushed.

 

Lynn 

0 Kudos
Message 8 of 35
(4,694 Views)

Ok,thanks a lot,that seems to work fine for me,although i dont really know what the radio buttons do exactly!

But do you know if there's a way to connect the 4 seperate buttons i've placed so that when i press each of them,will give me the proper indication?I try to make it look like the outter view of a real gussmeter you see...Do i have to put 4 different indicators in this case?And if so,how can i direct the buttons to the proper indicator so that only one can be pressed at any time?!Sorry for all these questions,i'm just trying to understand myself,but it seems to be hard for a labview newbie.Or maybe it's just me..

0 Kudos
Message 9 of 35
(4,675 Views)
Solution
Accepted by topic author levangram

You can use the separate buttons.  To be sure that only one button is pressed at a time, you would need to use local variables or property nodes to reset the others.

 

I customized the radio button to look more like your panel.  The radio button has the "one button at a time" functionality built in so you do not need to program it yourself.  You could make the frame invisible using the coloring tools.

 

Lynn 

Download All
0 Kudos
Message 10 of 35
(4,665 Views)