Skip to content

AlexanderTonn/Arduino_EdgeDetection

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Arduino_EdgeDetection

Arduino Library for detecting rising of falling edges of signals

Usage

#include "edgeDetection.hpp"

EdgeDetection<bool> _trig

void setup(){
    Serial.begin(9600);
}

void loop(){
    bool exampleSignal = true;

    // This will return true only once in the first loop (because exampleSignal is never changing)
    auto booleanSignal = _trig.edgeDetection(timer, EdgeDetection<bool>::type::RISING_EDGE, true)
    if(booleanSignal){
        Serial.println("Rising edge detected");
    }
}


About

Arduino Library for detecting rising of falling edges of signals

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages