![]() |
Re: Hall Effect Sensor.
Quote:
However, the time to pulse also varies with the speed (no direction) of the rotations. You sort of have to know the speed to do much with it. However, I see little wrong with assuming direction. A PID controller reacts in ~20-30 ms -- it's very unlikely a robot can push yours in the reverse direction at that exact velocity... |
Re: Hall Effect Sensor.
Jdong,
I imagine you are quite right about the complexity, and you bring up a good point about assumptions. I was merely throwing it out as a piece of information that could be used so people could mess with it. I have absolutely no idea about how programming is done, and am rather hopeless (even after 2 C classes!) but what if you were to make the hall-effect sensor read a gear with a large gap between the teeth? that would make the duty cycle difference easier to read. I have other ideas, but most of mine are not that great. Thanks again! Sparks |
Re: Hall Effect Sensor.
Sparks,
Sorry this is a little late. I have been looking at the sensor and page 9 is a discussion of the output vs. direction. If the gear is moving in one direction the output will rise from a low state to a high. If the gear is moving in the other direction, the output will move from a high to a low. This is data that I don't think could be useful other that scoping the output while rotating the shaft by hand. The suggestion I made earlier (thanks Greg for the corrected waveform) requires two sensors mounted so that the pulses overlap by 90 degrees (electrical degrees that is). You can see that rather easily in Greg's waveform that the top pulse leads the bottom by some amount. If the direction were reversed, the top pulse would lag the bottom pulse by the same amount. If you were to then compare the pulse trains by sampling when the top pulse goes from low to high, and determining the value of pulse train two, you could determine which direction you were turning. (If pulse two is already high when pulse one goes high you are turning in one direction. If pulse two is low when pulse one goes high you are turning in the other direction.) This is easy to do in software, (don't ask me how) and requires about four gates as I remember, in logic hardware to decode. The Hall effect is actually a pretty neat little package in that it uses two sensors at right angles to each other, to cancel out errors and temperature problems automatically. Please note the restrictions on gear tooth specifications when using and positioning the sensor. |
Connecting the Hall Effect Sensor.
I've been having abit of a problem connecting the hall effect sensors with the 4 pins. i looked at the file on http://www.allegromicro.com/datafile/0660.pdf and it said that one pin is for +v one is for GND and one is the output signal and the one left is also for GND . it seems a bit weird to me. perhaps i'm not understanding it correctly. why would you need two pins for GND. do you really have to connect both the 3rd and the 4th pin to the GND?
please help me figure this out. what is the correct way to connect it? |
Re: Connecting the Hall Effect Sensor.
Quote:
It may be an electrocstatic shield or it may be the shell of the magnetic structure. Four pins tied to a PCB are better than three. |
Re: Hall Effect Sensor.
doesnt the program only run every 26miliseconds? Thats about 38 times per second. So if you had 38 teeth moving past it per second wouldnt your program show taht the robot is simply sitting still? These things look way too complicated for me.
|
Re: Hall Effect Sensor.
Quote:
Interrupts allow your code to process events that may come in during the execution of another task, and "interrupt" the current processing to handle the interrupt (in a function known as the "ISR", or "interrupt service routine") There are a few magic registers in the controller that control how interrupts are handled (for a good reference, check out Kevin Watson's interrupt code). So, while the radio may be able to only transmit/recieve information every 26ms, the controller operates much faster, and with interrupts, can handle tasks even faster than the "fast loop" that executes code while waiting for a radio packet. Scott |
Re: Hall Effect Sensor.
[font=Comic Sans MS][font=Comic Sans MS]hm.. so afterall that has been said..
does anyone know where could we find the manual for the hall effect sensor??~ :) thank yoU~~ |
Re: Hall Effect Sensor.
=] May someone please tell me
where could we find the manual of the hall effect sensor?? =] thank you |
Re: Hall Effect Sensor.
Quote:
|
Re: Hall Effect Sensor.
Quote:
-Kevin |
Re: Hall Effect Sensor.
Kevin,
The data sheet is really vague on this question. I have not used these sensors but in reading the data sheet, it repeatedly talks about how the duty cycle is fixed at some value and is stable with respect to temperature, air gap, and speed. I found that there is some hidden text as respect to duty cycle in the sheet and the waveforms for duty cycle are missing. (search the pdf for "duty cycle" and at the bottom of p8 you will see highlighted blanks, I selected the text and pasted it in another document to read it.) Due to the variations in tooth shape, tooth depth, surrounding metal, etc., I believe the magnetic fields vary considerably. I am guessing that the manufacturer tried to compensate for these variables and probably aimed for 50% +/-5% by sensing zero cross. There is discussion that the sensor learns it's environment over the space of 64 cycles, adjusting gain and A/D parameters to make the output stable and accurate. If anyone has practical experience with this device and can produce a waveform or two, it would be a big help. I will try and dig one out and see if I can get some data, next week. FLL state tournament is this weekend, so it's going to be pretty busy between now and then. |
Re: Hall Effect Sensor.
What's everyone's best place and advice for mounting the sensor? The data sheet is lacking, but from what I would gather, it has to be mounted behind the teeth, so it can record their absence. Has anyone gotten it to work mounted above the gear pointing downwards (reading through the chain)?
|
Re: Hall Effect Sensor.
Quote:
|
Re: Hall Effect Sensor.
We are having problems getting this particular sensor to work. We are currently testing it with an o-scope, and it appears that all our wiring is done correctly, but we are getting no output at all.
Any suggestions? |
| All times are GMT -5. The time now is 21:02. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi