i trying open huwawei usb dongle using "qextserialport".
my port details follows
port name: product id: physical name: \device\000000ca vendor id: friend name: sb port name: product id:? physical name: \device\usbpdo-10 vendor id: ? friend name: th port name: com3 product id: physical name: \device\bthmodem0 vendor id: friend name: standard serial on bluetooth link (com3) port name: com4 product id: physical name: \device\bthmodem2 vendor id: friend name: standard serial on bluetooth link (com4) port name: com5 product id: physical name: \device\bthmodem1 vendor id: friend name: standard modem on bluetooth link port name: com6 product id:? physical name: \device\000000e2 vendor id: ? friend name: huawei mobile connect - 3g application interface (com6) port name: com7 product id:? physical name: \device\000000e0 vendor id: ? friend name: huawei mobile connect - 3g modem port name: com8 product id:? physical name: \device\000000e3 vendor id: ? friend name: huawei mobile connect - 3g pc ui interface (com8)
i trying open usb dongle, can send sms. following code opening
#include "myclass.h" #include <qstring.h> #include <qdebug.h> int main() { qextserialport *port = new qextserialport("com7"); port->open(qiodevice::readwrite); cout << port->isopen(); system("pause"); return 0; }
when run code,
qwineventnotifier: can used threads started qthread 1
this shows port id open, message? means can't proceed other code? want know before code else. please help!
most likely, need create qapplication
, without many things events , signals/slots won't work:
int main() { qapplication app; qextserialport *port = new qextserialport("com7"); port->open(qiodevice::readwrite); cout << port->isopen(); system("pause"); return app.exec(); }
Comments
Post a Comment