Javelin Stamp and a Magnetic Sensor
Frankdeslimste
Posts: 2
I want to connect a magnectic sensor to my Solderless breadboard, could someone give me the schematics (So I don't mess is up )
Here's the link to the sensor I mean: http://www.phidgets.com/products.php?product_id=1108·
Here's the link to the sensor I mean: http://www.phidgets.com/products.php?product_id=1108·
Comments
you can use the ADC class
ADC mySensor = new ADC(inPin,outPin);
The ADC returns values 0-255 representing 0-5V.
Just adapt the formula given in the sensor's manual.
See the javelin manual how to setup the ADC pins.
regards peter
You need to provide more details.
Which sensor?
Have you tried the ADC class proposed by Peter below?
JM
This is the sensor in question, it's a three pin hall-effect sensor. I used the ADC configuration on my javelin and the values returned were independent of any magnetic field I tried putting near the sensor. Then I realized that the sensor I have has a digital output, so I figured I should be able to just connect the sensor to the breadboard to get it to work, but I tried that and it just continuously returned the same value (320 i think).
I have just recently purchased the javelin so I'm still very new to it, as well as the specifics of bread boarding and circuitry so sorry if this is a stupid problem.... (I program in Java and I've taken college physics dealing with electricity; that's the main source of my knowledge).
I looked at the documentation, but there is not much to see in it. There is no protocol definition, etc. Do you have any other doc which define the signals, the way to talk to the component, and so on?
JM
Are there any tests I can run using the javelin to get any helpful information?
Or are there any configurations which I can try? Shouldn't it be fairly simple since the output from the sensor is digital?
http://www.sciencebuddies.org/science-fair-projects/project_ideas/Elec_p030.shtml
if so how would the multimeter translate into pin configurations?
I think it will work.
If you output can vary between 0 and 5, simply connect it to a javelin PIN.
When the output will be lower than 2.5V you will read a 0 on the Javelin side.
When the output will be higher than 2.5V you will read 1 on the Jvalin side.
I'm not 100% sure it's 2.5V the switch value, but you can find that in the Javelin documentation.
If you want more than an 0 / 1 value, then this is more complicated.
JM