Skip to content

Allow for encoders that are not on an interrupt pin. #153

@davetcc

Description

@davetcc

Make it possible to initialise switches encoder support so that it polls, IE on a non-interrupt pin. Interrupt pins can be scarce on some boards, and even on boards with many, they may already be in use for other purposes. Although all interrupts can be multiplexed onto a single pin, there may be times where it is either desirable not use interrupts or otherwise impossible. A new signature for initialisation will be added (leaving the existing modes as before):

switches.init(device, interruptMode, defaultIsPullUp);

I don't think the silent pull up parameter did much before, I have made it mandatory in the new init method (not touched originals), so anyone looking for the first time would clearly understand what had been configured.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions