Sur cette page

Qt Serial Port C++ Classes

Liste des classes C++ permettant d'accéder à un port série. Plus...

Classes

QSerialPort

Fournit des fonctions pour accéder aux ports série

QSerialPortInfo

Fournit des informations sur les ports série existants

Description détaillée

Pour utiliser QSerialPort dans votre application, ajoutez l'instruction include suivante :

#include <QSerialPort>

Pour QSerialPortInfo, utilisez l'instruction include suivante :

#include <QSerialPortInfo>

Pour utiliser le module avec cmake, utilisez la commande find_package() pour localiser les composants nécessaires du module dans le paquetage Qt6:

find_package(Qt6 REQUIRED COMPONENTS SerialPort)
target_link_libraries(mytarget PRIVATE Qt6::SerialPort)

Pour utiliser le module pour la construction avec qmake, ajoutez le module en tant que valeur de la variable QT dans le fichier .pro du projet :

QT += serialport

© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.