L'appel à connect plante le programme
Bonjour,
J'ai mon connect qui fait planté le programme Qt et je ne vois vraiment pas pourquoi car cela fonctionnait auparavant :
Code:
1 2 3 4 5 6 7 8 9 10 11
|
void SerialPort::startSerial()
{
timerRecupTrame = new QTimer();
timerRecupTrame->start();
timerRecupTrame->setInterval(500);
qDebug() << "Connect ...";
//QObject::connect(timerRecupTrame,SIGNAL(timeout()),this ,SLOT(serialReceived()));
qDebug() << "Connect OK";
} |
ma classe :
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
|
class SerialPort : public QMainWindow
{
Q_OBJECT
public:
explicit SerialPort(QWidget *parent = 0);
public slots:
bool initSerial(QString portCOM);
bool closeSerial();
void startSerial();
private slots:
void serialReceived();
void sendChar(char caract);
private:
QTimer *timerRecupTrame;
}; |