| On the basis of the systematic requirement analysis of the wet gas two phase flow metering system, a design plan based on DSP is proposed, which is composed of hardware design and software design to measure two-phase flow. Optimization of the two-phase flow metering unit design is completed as well as instrument molding. The design can achieve goals of measurement, storage and transportation of two-phase wet natural gas flow.In the hardware design, according to the modular design principle, the unit design is divided into four parts: DSP core board, input board, communication board and display board. TMS320VC5509 A is selected as the core processor. Meanwhile, the external circuits are composed of ADS8344 ADC, microSD card, TMP20 local temperature sensor, Wi-Fi wireless communication module and RS-485 receiving and transmitting devices.The software design introduces DSP/BIOS real-time embedded operating system, finished the configuration of the system and application programming. Transplanted the FAT file system and RS9110-N-11-22 industrial-level Wi-Fi wireless module driver program. In the end, the work to optimize the embedded programs in code-level and operating system are involved.After the integration of the software and hardware modules, the metering unit can implement fast data acquisition of 4mA~20mA standard current signal in 8 roads, fast data processing, long-time and safe storage of massive data, real-time local display of the flow data, RS-485 wire communication and Wi-Fi wireless communication. |