Skip to content

Bad use of INPUT_PULLUP in digitalWrite #19

@amaury-herrera

Description

@amaury-herrera

In the FlowSensor.h file, line 35 appears this line:
digitalWrite(this->_pin, INPUT_PULLUP); // Optional Internal Pull-Up
INPUT_PULLUP is intended to be used with pinMode function. Instead, LOW or HIGH must be used.
Perhaps you want to use INPUT_PULLUP in line 34 as second argument for pinMode.

Maybe it doesn't cause any trouble, but the intention is not clear.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingwontfixThis will not be worked on

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions