void ER15HW::run() { while (true) { mutex.lock(); if (toShutDownThread) break; mutex.unlock(); QThread::msleep(5); } }