The present invention relates to the field of
asynchronous serial communication technology, and specifically to an
asynchronous serial communication protocol automatic identification method,
system, device and medium, which can calculate the
baud rate of the protocol by using the
time difference of pulses of different widths; use the high-frequency logic circuit of programmable logic to quickly compare the data in the cache, and the identification speed is relatively fast, which is very beneficial for on-site equipment
layout and application scenarios where the protocol is unknown. The present invention can calculate the
baud rate by sampling 3-6 low pulse width counts, and calculate the minimum unit value by using the different length values of the 3-6 pulses themselves and the difference between them; use the
time difference of pulses of different widths to calculate the
baud rate of the protocol, and then cache the online data into a
programmable logic device according to the baud rate, and use the high-frequency logic circuit of programmable logic to quickly compare the data in the cache, thereby obtaining the
data format and finally completing the protocol identification.