Under the condition of limited serial resources, in order to efficiently control more lower-computers , the method of multiple serial poll based on event-driven mode was designed. In order to improve precision of control time, high-precision soft timer was designed, error was not more than 1 ms. The methods of multiple serial poll and soft timer were good base of water supply system that can achieve automatic control and transmission, reduced control cost, improved control precision.%在有限的串口资源条件下,为了高效地控制更多的下位机,设计了基于事件驱动方式的多串口轮询方法;为了提高控制时间的精确性,设计了高精度软件定时器,误差不大于1 ms.串口轮询方法和软件定时器为实现供水系统的自动控制和传输奠定了良好的基础,降低了控制成本,提高了控制精度.
展开▼