Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Programming (http://www.chiefdelphi.com/forums/forumdisplay.php?f=51)
-   -   Non Contact Magnetic Encoder with PWM Output (http://www.chiefdelphi.com/forums/showthread.php?t=39904)

Tom Bottiglieri 05-10-2005 23:35

Non Contact Magnetic Encoder with PWM Output
 
http://www.austriamicrosystems.com/0...try/AS5040.htm

I stumbled across this today...

Apparently, this company austriamicrosystems makes an IC which can measure the rotation of a magnet (resolution of 1024 parts per revolution). It has an onboard processor and A/D converter, and does all the stuff we would to do process encoder data in our robot code right on board the chip. It can output rotation data in quadrature, SSI, or PWM.

I cant seem to find how much this costs, but they will send free trials to corporations.

This is the first I've seen of this type of sensor. Does anyone know a little more, or think this may be something worth looking into? As far as I can see (without money on the mind), something like this could simplify our bot's code by leaps and bounds and give a much easier means to closed loop control, with less chance of error or breakage.

Gdeaver 07-10-2005 17:46

Re: Non Contact Magnetic Encoder with PWM Output
 
From what I read, the chip puts out pulses in mode 2 on one pin and direction state on another. It still requires counting pulses and interrupts. However the interrupt routine would not have to include the state machine that quadrature requires. Simpler and faster handler

seanwitte 08-10-2005 16:38

Re: Non Contact Magnetic Encoder with PWM Output
 
Quote:

Originally Posted by Gdeaver
From what I read, the chip puts out pulses in mode 2 on one pin and direction state on another. It still requires counting pulses and interrupts. However the interrupt routine would not have to include the state machine that quadrature requires. Simpler and faster handler

Quadrature doesn't require a state machine to decode the input. Use one channel on an interrupt and the other on a regular digital input. In the ISR, the value of the channel on the digital input provides the direction.

ISR code (assume channel A is on the interrupt pin, fire on rising edge, and channel B is on input 0). distance is a signed int.

distance += (dig_in0 == 0) ? 1 : -1;

Alan Anderson 09-10-2005 01:19

Re: Non Contact Magnetic Encoder with PWM Output
 
Quote:

Originally Posted by seanwitte
Quadrature doesn't require a state machine to decode the input. Use one channel on an interrupt and the other on a regular digital input. In the ISR, the value of the channel on the digital input provides the direction.

That can fail if the encoder wobbles back and forth in one place. Unless you keep track of the previous actions, you'll keep counting pulses in one direction and ignoring them in the other. It's not usually a problem with the kind of mechanical systems used in FIRST robots, but it did affect our "ground travel" sensors last season until we put in the necessary state machine.

Something like the encoder mentioned here would have made it easier to use more sensors without worrying too hard about interrupts.


All times are GMT -5. The time now is 13:53.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi