fiber
Loading...
Searching...
No Matches
fiber::cInPin Concept Reference

Concept for pin that can be immediatelly read from. More...

#include <cPin.hpp>

Concept definition

template<class Pin>
concept fiber::cInPin = requires( Pin pin){
{ pin.is_high() } -> std::same_as<bool>;
{ pin.is_low() } -> std::same_as<bool>;
{ pin.read() } -> std::same_as<bool>;
}
Concept for pin that can be immediatelly read from.
Definition cPin.hpp:86

Detailed Description

Concept for pin that can be immediatelly read from.

Pin without any practical delay, like pins of the micro controller


[[nodiscard]] bool read() ;

Returns: the logic value applied to the pin.


[[nodiscard]] bool is_high() ;

Returns: true is the pin is set to logic high.


[[nodiscard]] bool is_low() ;

Returns: true is the pin is set to logic low.