Teademia 543afc9ff9 Implement of Rasp GPIO Input read
Import libwringpi and read handbutton input
2023-11-21 21:22:47 +08:00

19 lines
557 B
C++

#include "gpioinit.h"
/******************************************************************************
* Copyright 2020-xxxx xxx Co., Ltd.
* All right reserved. See COPYRIGHT for detailed Information.
*
* @file gpioinit.cpp
* @brief This is used to set the mode(INPUT,OUTPUT) of GPIO
* @author teademia@gmail.com
* @date 2023/11/21
* @history
*****************************************************************************/
gpioInit::gpioInit(QObject *parent)
: QObject{parent}
{
wiringPiSetup();
pinMode(3,INPUT);
}