input gpio regular constructor

This commit is contained in:
Jakob Meier 2021-05-17 14:02:27 +02:00
parent 6341da2212
commit 7724fdc389

View File

@ -66,13 +66,21 @@ public:
class GpiodRegular: public GpioBase { class GpiodRegular: public GpioBase {
public: public:
GpiodRegular(): GpioBase(gpio::GpioTypes::GPIOD_REGULAR, std::string(), GpiodRegular() :
gpio::Direction::IN, 0) {}; GpioBase(gpio::GpioTypes::GPIOD_REGULAR, std::string(), gpio::Direction::IN, 0) {
}
;
GpiodRegular(std::string chipname_, int lineNum_, std::string consumer_, GpiodRegular(std::string chipname_, int lineNum_, std::string consumer_,
gpio::Direction direction_, int initValue_) : gpio::Direction direction_, int initValue_) :
GpioBase(gpio::GpioTypes::GPIOD_REGULAR, consumer_, direction_, initValue_), GpioBase(gpio::GpioTypes::GPIOD_REGULAR, consumer_, direction_, initValue_), chipname(
chipname(chipname_), lineNum(lineNum_) {} chipname_), lineNum(lineNum_) {
}
GpiodRegular(std::string chipname_, int lineNum_, std::string consumer_) :
GpioBase(gpio::GpioTypes::GPIOD_REGULAR, consumer_, gpio::Direction::IN, 0), chipname(
chipname_), lineNum(lineNum_) {
}
std::string chipname; std::string chipname;
int lineNum = 0; int lineNum = 0;
struct gpiod_line* lineHandle = nullptr; struct gpiod_line* lineHandle = nullptr;