added more funtions to pin interface

interrupts
polymurph 4 years ago
parent 68a25b0b64
commit 4cb7ec1772

@ -4,10 +4,20 @@
template <typename Derived>
struct Pin
{
bool read()
{
return static_cast<Derived*>(this)->readImpl();
}
void write(bool logic)
{
static_cast<Derived*>(this)->writeImpl(logic);
}
void toggle()
{
static_cast<Derived*>(this)-toggleImpl();
}
};
#endif // __PIN_HPP__

Loading…
Cancel
Save