Shop OBEX P1 Docs P2 Docs Learn Events
Sensing direction and angle with no encoder — Parallax Forums

Sensing direction and angle with no encoder

Alex.StanfieldAlex.Stanfield Posts: 198
edited 2011-02-17 10:36 in Accessories
I have a stepper and no encoder to drive a 10 teeth gear (36°/tooth). Since the gear (and motor) can be moved by external forces under certain conditions I would like to sense this condition.
I don't have encoders for neither the stepper nor the gear and no space to place them

I was planning to use 2 Melexis cam sensors (MLX 90217) in a 1/2 tooth offset (i.e One cam sensor points at the peak of the tooth and the other points at the valley)
I'm assuming I could get get a fairly good resolution (18° is ok for me) and direction sensing with this setup.

Has anyone done this?

Any other ideas I could use?

Thanks in advance
Alex

Comments

  • dandreaedandreae Posts: 1,375
    edited 2011-02-17 08:11
    You can use a micrcontroller to keep track of the position. You can create a variable such as "Count" to keep track of the direction and position.

    Dave
  • ercoerco Posts: 20,256
    edited 2011-02-17 10:36
    It should work; you're essentially using your gear as your encoder disk and mounting your cam sensors in a quadrature encoder sensor setup. Much depends on your cam sensor's abilities. Not so sure about your peak & valley sensor placement. IMHO it's more likely to work if they are both mounted mid-tooth (at the 50% tooth, 50% gap at the detection radius) and 90 degrees out of phase. I got some decent read speeds (394 pulses/sec) using homemade optical encoder sensors in this thread: have a peek: http://forums.parallax.com/showthread.php?121179-Reading-Quadrature-Encoders&highlight=optical%20encoder

    Lots of forum input there as well as clever code examples.
Sign In or Register to comment.