diff --git a/hardwaresetup.cpp b/hardwaresetup.cpp index 7390c1c..81280c9 100644 --- a/hardwaresetup.cpp +++ b/hardwaresetup.cpp @@ -30,14 +30,18 @@ HardwareSetup::~HardwareSetup(){ void HardwareSetup::run(){ int index; while(!this->stop){ - index +=1; + usleep(500); if(getDea()){ + index +=1; if(!deaBefore){ + index = 0; deaBefore = true; emit Dea(); } + //Debug + //std::cout << index << std::endl; } else{ deaBefore = false;