try this
timer->start(1000);
connect(timer, SIGNAL(timeOut()),this, SLOT(timerCall()));
::timerCall() //slot
{
if( port->DataAvalable){
port->read();
// can call any private function
}
}
timer->start(1000);
connect(timer, SIGNAL(timeOut()),this, SLOT(timerCall()));
::timerCall() //slot
{
if( port->DataAvalable){
port->read();
// can call any private function
}
}
To copy to clipboard, switch view to plain text mode
so every time the timer calls this slot every 1 sec ... if data is available it will do the operation or there emit your own private signal
Bookmarks