Shop OBEX P1 Docs P2 Docs Learn Events
Pitfalls and crawling out... GetSec() behaves not as I expected, to slow and counting down - Page 3 — Parallax Forums

Pitfalls and crawling out... GetSec() behaves not as I expected, to slow and counting down

13»

Comments

  • JonnyMacJonnyMac Posts: 9,804

    I've attached my quadrature encode object that uses smart pins. Perhaps it will help you get started.

  • ErNaErNa Posts: 1,853
    edited 2026-04-15 19:31

    Thanks, Jon. Indeed, it was a great starting point. Btw: I like your versioning system. One remark: those rotary switches come in two variants: the solid versions intended for CNC machining and else actually show a quadrature signal. The cheap input switches often output a clock/direction signal. It can be decoded as a quadrature signal, but then four state changes stand for one increment.
    The smart pins are just great. They do the dirty work in real time and you fetch a result whenever needed. It's like watching a tanker passing by and just take it, if you are in the mood.

Sign In or Register to comment.