pamoja for TypeScript - v0.2.0
    Preparing search index...

    Class Quadrature

    Counts a quadrature encoder's steps from its A and B channels.

    Index
    • Creates a decoder seeded with the channel levels it reads now, both low unless given, so the first reading does not count a step that did not happen.

      Parameters

      • Optionala: boolean | null
      • Optionalb: boolean | null

      Returns Quadrature

    • Sets the count back to 0, keeping the channel state last read.

      Returns void

    • Feeds the channel levels read now, and returns 1 or -1 for a step in either direction, or 0 for no change or a jump past a step.

      Parameters

      • a: boolean
      • b: boolean

      Returns number