ape
29th January 2008, 12:16
Hi,
i am trying to create a Windows-App, based on QT & QextSerialPort which should finaly be used to control a digital power supply.
Basicly the Qt-Core (UI, core-functions etc..) does work and now i need to integrate QextSerialPort into my project.
I would like to use QextSerialEnumerator (part of the latest QextSerialPort) to check the Windows host system for existing serial ports in the first step. The enumerator example does that in a very basic method. Based on that source i want to do my first step and add this function to my application.
quote out of the enumerator example:
QList<QextPortInfo> ports = QextSerialEnumerator::getPorts();
printf("List of ports:\n");
for (int i = 0; i < ports.size(); i++)
{
printf("port name: %s\n", ports.at(i).portName.toLocal8Bit().constData());
printf("friendly name: %s\n", ports.at(i).friendName.toLocal8Bit().constData());
printf("physical name: %s\n", ports.at(i).physName.toLocal8Bit().constData());
printf("enumerator name: %s\n", ports.at(i).enumName.toLocal8Bit().constData());
printf("===================================\n\n");
}
I have compiled the enumerator example which works as standalone app.
Well now...howto include it
To be honest...i am wondering what is the best way to integrate 3rd-party source to my environment.
Is it possible to create a custom folder which contains all QextSerialPort related files and just include them to my project (.pro file i guess) or should i start somehow different ?
Hints are highly appreciated.
best regards
ape
i am trying to create a Windows-App, based on QT & QextSerialPort which should finaly be used to control a digital power supply.
Basicly the Qt-Core (UI, core-functions etc..) does work and now i need to integrate QextSerialPort into my project.
I would like to use QextSerialEnumerator (part of the latest QextSerialPort) to check the Windows host system for existing serial ports in the first step. The enumerator example does that in a very basic method. Based on that source i want to do my first step and add this function to my application.
quote out of the enumerator example:
QList<QextPortInfo> ports = QextSerialEnumerator::getPorts();
printf("List of ports:\n");
for (int i = 0; i < ports.size(); i++)
{
printf("port name: %s\n", ports.at(i).portName.toLocal8Bit().constData());
printf("friendly name: %s\n", ports.at(i).friendName.toLocal8Bit().constData());
printf("physical name: %s\n", ports.at(i).physName.toLocal8Bit().constData());
printf("enumerator name: %s\n", ports.at(i).enumName.toLocal8Bit().constData());
printf("===================================\n\n");
}
I have compiled the enumerator example which works as standalone app.
Well now...howto include it
To be honest...i am wondering what is the best way to integrate 3rd-party source to my environment.
Is it possible to create a custom folder which contains all QextSerialPort related files and just include them to my project (.pro file i guess) or should i start somehow different ?
Hints are highly appreciated.
best regards
ape