QTimer *timer1 = new QTimer(this);
QTimer *timer2 = new QTimer(this);
//QTimer *timer3 = new QTimer(this);
startTimer(5000);
connect( timer1, SIGNAL(timeout()), this, SLOT(upAction()) );
timer1->start(5000);
//timer1->stop();
//timer1->setInterval(5000);
connect( timer2, SIGNAL(timeout()), this, SLOT(stopAction()) );
timer2->start(10000);
我想执行upAction()) 5s然后执行stopAction()) 5s。依次循环,但是打开串口之后,过5s会开始执行upAction()) ,但是不会停下来,这是为什么?怎么修改程序