Description: * Function: Serial to open, close, data transmission and automatic reception (1)] using [event-driven approach, that is, when the buffer receives the data, receive data] [automatically perform effectively conserve system resources and improve the implementation of efficiency. Principle: Create an event thread that monitors serial event and error messages. When there is an event or an error occurs, it is the main thread] [the initiative to send a Windows message. The main thread to handle events or errors have occurred in the message corresponding function. (2) the use of " asynchronous" read serial, time-consuming to read data in a separate thread. (3) programming steps: define global variables, create serial port, open the event thread, send data, custom messages, close the serial port and close the thread. Meanwhile, additionally configure the serial port function, check available ports
To Search:
File list (Check if you may need any files):
SerialPort.cpp
SerialPort.h
SerialPort使用详解.txt