基于嵌入式ARM平台的远程IO数据采集系统的研究和开发(精选5篇)
篇1:基于嵌入式ARM平台的远程IO数据采集系统的研究和开发
Research and Development of the Remote I/O Data Acquisition System Based on Embedded ARM Platform
INTRODUCTION
With the wide use of the networked, intelligent and digital distributed control system, the data acquisition system based on the single-chip is not only limited in processing capacity, but also the problem of poor real-time and reliability.In recent years, with the rapid development of the field of industrial process control and the fast popularization of embedded ARM processor, it has been a trend that ARM processor can substitute the single-chip to realize data acquisition and control.Embedded ARM system can adapt to the strict requirements of the data acquisition system, such as the function, reliability, cost, size, power consumption, and so on.In this paper, a new kind of remote I/O data acquisition system based on ARM embedded platform has been researched and developed, which can measure all kinds of electrical and thermal parameters such as voltage, current, thermocouple, RTD, and so on.The measured data can be displayed on LCD of the system, and at the same time can be transmitted through RS485 or Ethernet network to remote DAS or DCS monitoring system by using Modbus/RTU or Modbus/TCP protocol.The system has the dual redundant network and long-distance communication function, which can ensure the disturb rejection capability and reliability of the communication network.The new
generation remote data acquisition and moni-toring system based on the high-performance embedded ARM microprocessor has important application significance.STRUCTRUE DESIGN OF THE WHOLE SYSTEM
The whole structure chart of the remote data acquisition and monitoring system based on embedded ARM platform is shown in Figure 1.In the scheme of the system, the remote I/O data acquisition modules are developed by embedded ARM processor, which can be widely used to diversified industries such as electric power, petroleum, chemical, metallurgy, steel, transportation and so on.This system is mainly used for the concentrative acquisition and digital conversion of a variety of electrical and thermal signals such as voltage, current, thermal resistance, thermo-couple in the production process.Then the converted data can be displayed on the LCD directly, and also can be sent to the embedded controller through RS485 or Ethernet network communication interface by using Modbus/RTU or Modbus/TCP protocol.The data in the embedded controller platform is transmitted to the work-stations of remote monitoring center by Ethernet after further analyzed and pro-cessed.At the same time, these data can be stored in the real time database of the database server in remote monitoring center.The system has the dual redun-dant network and long-distance communication
function, which can ensure the disturb rejection capability and reliability of the communication network.The hardware platform of the Remote I/O data acquisition system based on emb-edded ARM uses 32-bit ARM embedded microprocessor, and the software plat-form uses the real-time multi-task operating system uC/OS-II, which is open-source and can be grafted, cut out and solidified.The real time operating system(RTOS makes the design and expansion of the application becomes very easy, and without more changes when add new functions.Through the division of the appli-cation into several independent tasks, RTOS makes the design process of the application greatly simple.Figure 1 Structure of the whole system THE HARDWARE DESIGN OF THE SYSTEM
The remote I/O data acquisition system based on embedded ARM platform has high universality, each acquisition device equipped with 24-way acquisition I/O channels and isolated from each other.Each I/O channel can select a variety of voltage and current signals, as well as temperature signals such as thermal resis-tance, thermocouple and so on.The voltage signals in the range of 0-75 mV ,1-5V ,0-5V, and so on, the current signals in the range of 0-10mA and 4-20 mA, the thermal resistance measurement components including Cu50, Cu100, Pt50, Pt100, and the thermocouple measurement components including K, E, S, T, and so on.Figure2.Structure of the remote I/O data acquisition system based on ARM processor The structural design of the embedded remote I/O data acquisition system is shown in Figure 2.The system equipped with some peripherals such as power, keyboard, reset, LCD display, ADC, RS485, Ethernet, JTAG, I2C, E2PROM, and so on.The A/D interface circuit is independent with the embedded system, which is independent with the embedded system, which is system has setting buttons and 128*64 LCD, which makes the debugging and modification of the parameters easy.The collected data can be sent to the remote embedded controller or DAS, DCS system by using
Modbus/RTU or Modbus/TCP protocol through RS485 or Eth-ernet communication interface also, and then be used
for monitoring and control after farther disposal.The system of RS485 has a dual redundant network and long-distance communication function.As the embedded Ethernet interface makes the remote data exchange of the applications become very easy, the system can choose RS485 or Ethernet interface through jumper to communicate with host computer.Ethernet interface use independent ZNE-100TL intelligent embedded Ethernet to serial port conversion module in order to facilitate the system maintenance and upgrade.The ZNE-100TL module has an adaptive 10/100M Ethernet interface, which has a lot of working modes such as TCP Server, TCP Client, UDP, Real COM, and so on, and it can support four connections at most.Figure3.Diagram of the signal pretreatment circuit
Figure 3 shows the signal pretreatment circuit diagram.The signals of thermo-couple such as K,E,S,T etc and 0-500mV voltage signal can connect to the positive end INPx and the negative end INNx of the simulate multiplexers(MUX directly.The 4-20mA current signal and 1-5V voltage signal must be transformed by resis-tance before connecting to the positive end INPx and the negative end INNx of the MUX of certain channel.The RTD thermal resistance signals such as Cu50, Cu100, Pt50 and Pt100 should connect one 1mA constant current before connecting to the positive end INPx and the negative end INNx of the MUX of certain channel.Figure4.Diagram of ADC signal circuit Figure 4 shows the ADC signal circuit, which using the 16-bit ADC chip AD7715.The connection of the chip and the system is simple and only need
five lines which are CS(chip select, SCLK(system clock, DIN(data input, DOUT(data output and DRDY(data ready.As the ARM microprocessor has the characteristics of high speed, low power, low voltage and so on, which make its capacity of low-noise, the ripple of power, the transient response performance, the stability of clock source, the reliability of power control and many other aspects should be have higher request.The system reset circuit use special microprocessor power monitoring chip of MAX708S, in order to improve the reliability of the system.The system reset circuit is shown in Figure 5.Figure5.Diagram of system reset circuit
SOFTWARE DESIGN AND REALIZATION OF THE SYSTEM
The system software of the remote I/O data acquisition system based on embedded ARM platform use the real-time operating system(RTOS uC/OS-II, which is open-source and can be grafted,cut out and solidified.The key part of RTOS is the real-time multi-task core, whose basic functions including task management, resource management, system management, timer management, memory management, information management, queue management and so on.These functions are used though API service functions of the core.The system software platform use uC/OS-II real-time operating system core simplified the design of application system and made the whole structure of the system simple and the complex application hierarchical.The design of the whole system includes the tasks of the operating system and a series of user applications.The main function of the system is mainly to realize the initialization of the system hardware and the operating system.The initialization of hardware includes interr-upt、keyboard、LCD and so on.The initialization of operating system includes the control blocks and events control blocks, and before the start of multi-task schedu-ling, one task must be started at least.A start task has been created in this system, which is mainly responsible for the initialization and startup of clock, the start-up of interruption, the initialization of communication task module, as
well as the division of tasks and so on.The tasks must be divided in order to complete various functions of the real-time multi-task system.Figure6.Functional tasks of the system software Figure6 shows the functional tasks of the system software.According to importance of the tasks and the demands of real-time, the system applications are divided into six tasks with different priority, which including the tasks of A/D data acquisition, system monitoring, receive queue, data send, keyboard input, LCD display.The A/D data acquisition task demands the highest real-time requirements and the LCD display task is the lowest.Because each task has a different priority, the higher-priority task can access the ready one by calling the system hang up function or delay function.Figure7.Chart of AD7715 data transfer flow Figure 7 shows the data conversion flow of AD7715.The application A/D conversion is an important part of the data acquisition system.In the uC/OS-II real-time operating system core, the realization process of A/D driver depends mainly on the conversion time of A/D converter, the analog frequency of the conversion value, the number of input channels, the conversion frequency and so on.The typical A/D
conversion circuit is made up of analog multiplexer(MUX, amplifier and analog to digital converter(ADC.Figure8.Diagram of the application transfer driver Figure8 shows the application procedure transfer driver.The driver chooses the analog channel to read by MUX, then delay a few microseconds in order to make the signal pass through the MUX, and stabilize it.Then the ADC was triggered to start the conversion and the driver in the circle waiting for the ADC until its completion of the conversion.When waiting is in progress, the driver is detecting the ADC state signal.If the waiting time is longer than the set time, the cycle should be end.During waiting time of the cycle, if the conversion completed signal by ADC has been detected, the driver should read the results of the conversion and then return the result to the application.Figure9.Diagram of serial receive Figure9 shows the serial receive diagram with the buffer and signal quantity.Due to the existence of serial peripheral equipment does not match the speed of CPU, a buffer zone is needed, and when the data is sending to the serial, it need to be written to the buffer, and then be sent out through serial one by one.When the data is received from the serial port, it will not be processed until several bytes have been received, so the advance data can be stored in buffer.In practice, two buffer zones, the receiving buffer and the sending buffer, are needed to be opened from the memory.Here the buffer zone is defined as loop queue data structure.As the signal of uC/OS-II provides the overtime waiting mechanism, the serial also have the overtime reading and writing ability.If the initialization of the received data signal is 0, it expresses the loop buffer is empty.After the interrupt received, ISR read the received bytes from the UART receiving buffer, and put into receiving buffer region, at last wake the user task to execute read operation with the help of received signal.During the entire
process, the variable value of the current bytes in recording buffer can be inquired, which is able to shows whether the receive buffer is full.The size of the buffer zone should be set reasonable to reduce the possibility of data loss, and to avoid the waste of storage space.CONCLUSIONS
With the rapid development of the field of industrial process control and the wide range of applications of network, intelligence, digital distributed control System, it is necessary to make a higher demand of the data accuracy and reliability of the control system.Data acquisition system based on single-chip has been gradually eliminated because the problem of the poor real-time and reliability.With the fast popularization of embedded ARM processor, there has been a trend that ARM processor can alternate to single-chip to realize data acquisition and control.The embedded ARM system can adapt to the strict requirements of the data acquisition system, such as the function, reliability, cost, size, power consum-ption, and so on.In this paper, A kind of ARM-based embedded remote I/O data acquisition system has been researched and developed, whose hardware platform use 32-bit embedded ARM processor, and software platform use open-source RTOS uC/OS-II core.The system can be widely applied to electric power, petroleum, chemical, metallurgy, steel, transportation and so on.And it is mainly used in the collection and monitoring of all
kinds of electrical and thermal signals such as voltage, current, thermal resistance, thermocouple data of the production process.Then these data can be sent to the remote DAS, DCS monitoring system through RS485 or Ethernet interface.The system has the dual redundant network and long-distance communication function, which can ensure the disturb rejection capability and reliability of the communication network.基于嵌入式ARM平台的远程I / O数据采集系统的研究和开发
导言
随着网络化,智能化,数字化分布式控制系统的广泛使用,基于单芯片的数据采集系统不仅在处理能力上受限制,并且在实时性和可靠性方面也出现了问题。近几年来,随着工业过程控制领域的迅速发展和嵌入式ARM处理器的迅速普及,ARM处理器代替单芯片实现数据的采集和控制成为了趋势。嵌入式ARM系统能适应数据采集系统的严格要求,如功能性,可靠性,成本,体积,功耗等等。
在本文中提出一种新型的基于ARM嵌入式平台的远程I / O数据采集系统已被研制开发,它可以衡量各种电气和热参数,如电压,电流,热电偶,热电阻等等。那个测量数据可以显示在液晶显示器的系统中,同时可通过使用Modbus / RTU或的Modbus / TCP协议从RS485或以太网网络传送到DAS或DCS远程监控
系统。该系统具有双冗余网络和长途电通信功能,它可以确保通信网络的干扰抑制能力和可靠性。基于高性能嵌入式ARM微处理器的新一代远程数据采集和监控系统具有重要的应用意义。
整个系统的结构设计
基于嵌入式ARM的平台的远程数据采集和监控系统的整个结构图在以下的图1中展示。在这系统的计划中,通过使用广泛用于多种行业如电气电力,石油,化工,冶金,钢铁,运输等的嵌入式ARM处理器来开发远程I / O数据采集模块。该系统主要用于的集中采购和将各种电和热信号如电压,热电阻,热电偶在生产过程中进行数字转换。转换的数据可直接在液晶显示器上显示,也可以通过使用的Modbus / RTU或的Modbus / TCP协议的RS485总线或以太网网络通信接口被发送到嵌入式控制器。嵌入控制器平台的数据通过进一步以太网的分析和处理被传送至远程监控中心的工作站。与此同时,这些数据可以存储在远程监控中心数据库服务器的实时数据库中。该系统具有双冗余网络和远程通讯功能,它可以确保通信网络的干扰抑制能力和可靠性。
基于嵌入式ARM远程I / O数据采集系统的硬件平台使用32位ARM嵌入式微处理器和软件平台使用的是开源的并且可移植,削减和巩固的实时多任务操作系统的第二代UC / OS核心。实时操作系统(RTOS)使设计和应用的扩大变得非常容
易,增加新的功能时也没多大变化。通过几个独立的任务的应用,实时操作系统使得应用的设计过程极为简单。
系统的硬件设计
基于嵌入式ARM平台的远程I / O数据采集系统具有很高的普遍性,每个购置设备配备24收购方式的I / O渠道且彼此孤立。每个I / O通道可以选择不同的电压和电流信号,以及温度信号如热电阻,热电偶等。在05V的,010毫安和4100TL智能嵌入式以太网串口转换模块。该ZNE500mV的电压信号可以直接接到模拟多路复用器(复用器)的INPx正极和INNx负极。45V的电压信号必须用阻抗转换。热电阻的电阻信号如Cu50,Cu100,Pt50和Pt100应在接到某些频道的复用器INPx正极和INNx负极前连接一1毫安的恒流源。
图4显示了使用16位ADC芯片AD7715的ADC信号电路。芯片与系统的连接非常简单,只需要CS(芯片选择),SLCK(系统时钟),DIN(数据输入),DOUT(数据输出)和DRDY(数据准备)5根线。
由于ARM微处理器具有高速,低功耗,低电压等优点,这使它在低噪音,纹波权力,瞬态响应性能,时钟来源的稳定,功率控制和许多其他方面需要有更高的要求。为了改善系统的可靠性该系统复位电路中使用特殊的微处理器电源监测芯片MAX708S。图5展示了该系统复位电路。
系统软件的设计与实现
基于嵌入式ARM平台的远程I / O数据采集系统的软件使用的是开源的并且可移植,削减和巩固的实时多任务操作系统的第二代UC / OS核心。RTOS的关键部分是实时多任务的核心,其基本功能包括任务管理,资源管理,系统管理,计时器管理,内存管理,信息管理,队列管理等。通过API服务职能核心使用这些功能。
该系统软件平台使用的是单一化的uC/ OS第二代实时简化操作系统核心,使整个结构系统简单和应用层次复杂。整个系统的设计包括操作系统的任务和一系列的用户应用程序。系统的主要职能是实现系统硬件和操作系统的初始化。硬件初始化包括中断,键盘,液晶显示器等。操作系统初始化包括控制模块和事件控制,在多任务调度前,至少有一个任务开始。一个开端任务已建立在这一系统,这系统主要负责初始化和启动的时钟,开办中断,通信任务模块的初始化,以及任务分工等。为了完成实时多任务系统的多种职能那个任务必须被划分。
图6显示系统软件的功能任务。根据任务的重要性和实时要求,系统的应用曾划分为六个不同优先级的任务,其中包括A / D数据采集任务,系统监控,接受队列,数据传送,键盘输入,液晶显示屏显示。A / D数据采集任务要求最高的实时要求和液晶显示器显示任务是最低的。因为每个任务都有不同的优先事项,通过使用系统挂断功能或延迟功能更高的优先任务可以开始已经准备好的任务。
图7显示的是AD7715的数据转换流。A / D转换器的应用是数据采集系统的一个重要组成部分。在uS/ OS的第二代实时操作系统的核心中,A / D驱动程序的实现过程主要取决于A / D转换器的转换时间,有转换价值的模拟频率,输入通
道的数量,转换频率等等。典型的A / D转换电路由模拟复用器(复用器),放大器和模拟到数字转换器(ADC)组成。
图8显示了申请程序转移的驱动程序。驱动程序可以在模拟通道读取由复用器,那么几微秒的延迟,以便使信号通过多路开关,并使其稳定。然后,当转换开始时,ADC被触发,并且驱动程序在一个周期内等待ADC的触发,直到完成转换。当等待的进展,该驱动程序检测ADC的状态信号。如果等待时间比规定的时间越长,周期应该结束。在等待的周期时间,如果转换完成ADC的信号被检测到,驱动程序应改为转换的结果,然后将结果返回给应用程序。
图9显示了缓冲区和信号量的序列接收图。由于外围串行设备的存在CPU的运行速度匹配,一个缓冲区是必要的,当数据发送到序列,它必须被写入缓冲区,然后通过串行逐一地被发送出去。当从串行端口收到数据,这些数据将不会被处理直到收到一些字节,因此先前的数据可以存储在缓冲区中。在实践中,两个缓冲区,一个接收缓冲区和一个发送缓冲区,它们是需要从内存开放出来。在这里缓冲区像循环队列数据结构一样被定义。
由于uC/OS-II提供额外时间等待机制的信号,串口也具有额外的阅读和写作能力。如果收到的数据信号初值为0,它表示循环缓冲区是空的。在中断收到后,ISR从UART接受缓冲区中读到收到的数据,并投入接收缓冲区域,最后通过收到的数据开始用户执行读操作的的任务。在整个过程中,变量价值目前字节在存储缓冲区中的字节的变量值是可以被询问的,这能够表明接收缓冲区是否已满。为了降低数据丢失的可能性和避免浪费存储空间应合理地设置缓冲区的大小。
结论
随着工业过程控制领域的快速发展和网络,智能,数字化分布式控制系统广泛应用,有必要发展对数据准确性和控制可靠性要求更高的系统。由于较差的实时性和可靠性基于单片机数据采集系统已逐步被淘汰。随着嵌入式ARM处理器的迅速普及,ARM处理器替代单芯片实现数据采集与控制成为了一种新的趋势。嵌入式ARM系统能够适应数据采集系统的严格要求,如功能,可靠性,成本,大小,耗电量等等。
在本文中一种基于ARM的嵌入式远程I / O数据采集系统已被研究和开发,其硬件平台采用32位嵌入式ARM处理器和软件平台的使用开源的RTOS uS/ OS-Ⅱ核心。该系统可广泛应用于电力,石油,化工,冶金,钢铁,交通运输等方面。这是主要用于收集和监测各种电气和热信号,如电压,电流,热电阻,生产过程中的热电偶数据。然后通过RS485或以太网接口将这些数据发送到远程的DAS,DCS控制系统的监测系统。该系统具有双冗余网络和长途通信功能,它可以确保干扰抑制和通信网络的可靠性。
篇2:基于嵌入式ARM平台的远程IO数据采集系统的研究和开发
Research and Development of the Remote I/O Data Acquisition System Based on Embedded ARM Platform
INTRODUCTION
With the wide use of the networked, intelligent and digital distributed control system, the data acquisition system based on the single-chip is not only limited in processing capacity, but also the problem of poor real-time and reliability.In recent years, with the rapid development of the field of industrial process control and the fast popularization of embedded ARM processor, it has been a trend that ARM processor can substitute the single-chip to realize data acquisition and control.Embedded ARM system can adapt to the strict requirements of the data acquisition system, such as the function, reliability, cost, size, power consumption, and so on.In this paper, a new kind of remote I/O data acquisition system based on ARM embedded platform has been researched and developed, which can measure all kinds of electrical and thermal parameters such as voltage, current, thermocouple, RTD, and so on.The measured data can be displayed on LCD of the system, and at the same time can be transmitted through RS485 or Ethernet network to remote DAS or DCS monitoring system by using Modbus/RTU or Modbus/TCP protocol.The system has the dual redundant network and long-distance communication function, which can ensure the disturb rejection capability and reliability of the communication network.The new generation remote data acquisition and moni-toring system based on the high-performance embedded ARM microprocessor has important application significance.STRUCTRUE DESIGN OF THE WHOLE SYSTEM
The whole structure chart of the remote data acquisition and monitoring system based on embedded ARM platform is shown in Figure 1.In the scheme of the system, the remote I/O data acquisition modules are developed by embedded ARM processor, which can be widely used to diversified industries such as electric power, petroleum, chemical, metallurgy, steel, transportation and so on.This system is mainly used for the concentrative acquisition and digital conversion of a variety of
苏州大学本科生毕业设计(论文)
electrical and thermal signals such as voltage, current, thermal resistance, thermo-couple in the production process.Then the converted data can be displayed on the LCD directly, and also can be sent to the embedded controller through RS485 or Ethernet network communication interface by using Modbus/RTU or Modbus/TCP protocol.The data in the embedded controller platform is transmitted to the work-stations of remote monitoring center by Ethernet after further analyzed and pro-cessed.At the same time, these data can be stored in the real time database of the database server in remote monitoring center.The system has the dual redun-dant network and long-distance communication function, which can ensure the disturb rejection capability and reliability of the communication network.The hardware platform of the Remote I/O data acquisition system based on emb-edded ARM uses 32-bit ARM embedded microprocessor, and the software plat-form uses the real-time multi-task operating system uC/OS-II, which is open-source and can be grafted, cut out and solidified.The real time operating system(RTOS)makes the design and expansion of the application becomes very easy, and without more changes when add new functions.Through the division of the appli-cation into several independent tasks, RTOS makes the design process of the application greatly simple.Figure 1 Structure of the whole system
苏州大学本科生毕业设计(论文)
THE HARDWARE DESIGN OF THE SYSTEM
The remote I/O data acquisition system based on embedded ARM platform has high universality, each acquisition device equipped with 24-way acquisition I/O channels and isolated from each other.Each I/O channel can select a variety of voltage and current signals, as well as temperature signals such as thermal resis-tance, thermocouple and so on.The voltage signals in the range of 0-75 mV ,1-5V ,0-5V, and so on, the current signals in the range of 0-10mA and 4-20 mA, the thermal resistance measurement components including Cu50, Cu100, Pt50, Pt100, and the thermocouple measurement components including K, E, S, T, and so on.Figure2.Structure of the remote I/O data acquisition system based on ARM processor
The structural design of the embedded remote I/O data acquisition system is shown in Figure 2.The system equipped with some peripherals such as power, keyboard, reset, LCD display, ADC, RS485, Ethernet, JTAG, I2C, E2PROM, and so on.The A/D interface circuit is independent with the embedded system, which is independent with the embedded system, which is system has setting buttons and 128*64 LCD, which makes the debugging and modification of the parameters easy.The collected data can be sent to the remote embedded controller or DAS, DCS system by using Modbus/RTU or Modbus/TCP protocol through RS485 or Eth-ernet communication interface also, and then be used for monitoring and control
苏州大学本科生毕业设计(论文)
after farther disposal.The system of RS485 has a dual redundant network and long-distance communication function.As the embedded Ethernet interface makes the remote data exchange of the applications become very easy, the system can choose RS485 or Ethernet interface through jumper to communicate with host computer.Ethernet interface use independent ZNE-100TL intelligent embedded Ethernet to serial port
conversion module in order to facilitate the system maintenance and upgrade.The ZNE-100TL module has an adaptive 10/100M Ethernet interface, which has a lot of working modes such as TCP Server, TCP Client, UDP, Real COM, and so on, and it can support four connections at most.Figure3.Diagram of the signal pretreatment circuit
Figure 3 shows the signal pretreatment circuit diagram.The signals of thermo-couple such as K,E,S,T etc and 0-500mV voltage signal can connect to the positive end INPx and the negative end INNx of the simulate multiplexers(MUX)directly.The 4-20mA current signal and 1-5V voltage signal must be transformed by resis-tance before connecting to the positive end INPx and the negative end INNx of the MUX of certain channel.The RTD thermal resistance signals such as Cu50, Cu100, Pt50 and Pt100 should connect one 1mA constant current before connecting to the positive end INPx and the negative end INNx of the MUX of certain channel.苏州大学本科生毕业设计(论文)
Figure4.Diagram of ADC signal circuit
Figure 4 shows the ADC signal circuit, which using the 16-bit ADC chip AD7715.The connection of the chip and the system is simple and only need five lines which are CS(chip select), SCLK(system clock), DIN(data input), DOUT(data output)and DRDY(data ready).As the ARM microprocessor has the characteristics of high speed, low power, low voltage and so on, which make its capacity of low-noise, the ripple of power, the transient response performance, the stability of clock source, the reliability of power control and many other aspects should be have higher request.The system reset circuit use special microprocessor power monitoring chip of MAX708S, in order to improve the reliability of the system.The system reset circuit is shown in Figure 5.苏州大学本科生毕业设计(论文)
Figure5.Diagram of system reset circuit
SOFTWARE DESIGN AND REALIZATION OF THE SYSTEM The system software of the remote I/O data acquisition system based on embedded ARM platform use the real-time operating system(RTOS)uC/OS-II, which is open-source and can be grafted, cut out and solidified.The key part of RTOS is the real-time multi-task core, whose basic functions including task management, resource management, system management, timer management, memory management, information management, queue management and so on.These functions are used though API service functions of the core.The system software platform use uC/OS-II real-time operating system core simplified the design of application system and made the whole structure of the system simple and the complex application hierarchical.The design of the whole system includes the tasks of the operating system and a series of user applications.The main function of the system is mainly to realize the initialization of the system hardware and the operating system.The initialization of hardware includes interr-upt、keyboard、LCD and so on.The initialization of operating system includes the control blocks and events control blocks, and before the start of multi-task schedu-ling, one task must be started at least.A start task has been created in this system, which is mainly responsible for the initialization and startup of clock, the start-up of interruption, the initialization of communication task module, as well as the division of tasks and so on.The tasks must be divided in order to complete various functions of the real-time multi-task system.苏州大学本科生毕业设计(论文)
Figure6.Functional tasks of the system software
Figure6 shows the functional tasks of the system software.According to importance of the tasks and the demands of real-time, the system applications are divided into six tasks with different priority, which including the tasks of A/D data acquisition, system monitoring, receive queue, data send, keyboard input, LCD display.The A/D data acquisition task demands the highest real-time requirements and the LCD display task is the lowest.Because each task has a different priority, the higher-priority task can access the ready one by calling the system hang up function or delay function.苏州大学本科生毕业设计(论文)
Figure7.Chart of AD7715 data transfer flow
Figure 7 shows the data conversion flow of AD7715.The application A/D
conversion is an important part of the data acquisition system.In the uC/OS-II real-time operating system core, the realization process of A/D driver depends mainly on the conversion time of A/D converter, the analog frequency of the conversion value, the number of input channels, the conversion frequency and so on.The typical A/D conversion circuit is made up of analog multiplexer(MUX), amplifier and analog to digital converter(ADC).苏州大学本科生毕业设计(论文)
Figure8.Diagram of the application transfer driver
Figure8 shows the application procedure transfer driver.The driver chooses the analog channel to read by MUX, then delay a few microseconds in order to make the signal pass through the MUX, and stabilize it.Then the ADC was triggered to start the conversion and the driver in the circle waiting for the ADC until its completion of the conversion.When waiting is in progress, the driver is detecting the ADC state signal.If the waiting time is longer than the set time, the cycle should be end.During waiting time of the cycle, if the conversion completed signal by ADC has been detected, the driver should read the results of the conversion and then return the result to the application.苏州大学本科生毕业设计(论文)
Figure9.Diagram of serial receive
Figure9 shows the serial receive diagram with the buffer and signal quantity.Due to the existence of serial peripheral equipment does not match the speed of CPU, a buffer zone is needed, and when the data is sending to the serial, it need to be written to the buffer, and then be sent out through serial one by one.When the data is received from the serial port, it will not be processed until several bytes have been received, so the advance data can be stored in buffer.In practice,two buffer zones, the receiving buffer and the sending buffer, are needed to be opened from the memory.Here the buffer zone is defined as loop queue data structure.As the signal of uC/OS-II provides the overtime waiting mechanism, the serial also have the overtime reading and writing ability.If the initialization of the received data signal is 0, it expresses the loop buffer is empty.After the interrupt received, ISR read the received bytes from the UART receiving buffer, and put into receiving buffer region, at last wake the user task to execute read operation with the help of received signal.During the entire process, the variable value of the current bytes in recording buffer can be inquired, which is able to shows whether the receive buffer is full.The size of the buffer zone should be set reasonable to reduce the possibility of data loss, and to avoid the waste of storage space.CONCLUSIONS
With the rapid development of the field of industrial process control and the
苏州大学本科生毕业设计(论文)
wide range of applications of network, intelligence, digital distributed control System, it is necessary to make a higher demand of the data accuracy and reliability of the control system.Data acquisition system based on single-chip has been gradually eliminated because the problem of the poor real-time and reliability.With the fast popularization of embedded ARM processor, there has been a trend that ARM processor can alternate to single-chip to realize data acquisition and control.The embedded ARM system can adapt to the strict requirements of the data acquisition system, such as the function, reliability, cost, size, power consum-ption, and so on.In this paper, A kind of ARM-based embedded remote I/O data acquisition system has been researched and developed, whose hardware platform use 32-bit embedded ARM processor, and software platform use open-source RTOS uC/OS-II core.The system can be widely applied to electric power, petroleum, chemical, metallurgy, steel, transportation and so on.And it is mainly used in the collection and monitoring of all kinds of electrical and thermal signals such as voltage, current, thermal resistance, thermocouple data of the production process.Then these data can be sent to the remote DAS, DCS monitoring system through RS485 or Ethernet interface.The system has the dual redundant network and long-distance communication function, which can ensure the disturb rejection capability and reliability of the communication network.苏州大学本科生毕业设计(论文)
基于嵌入式ARM平台的远程I / O数据采集系统的研究和开发
导言
随着网络化,智能化,数字化分布式控制系统的广泛使用,基于单芯片的数据采集系统不仅在处理能力上受限制,并且在实时性和可靠性方面也出现了问题。近几年来,随着工业过程控制领域的迅速发展和嵌入式ARM处理器的迅速普及,ARM处理器代替单芯片实现数据的采集和控制成为了趋势。嵌入式ARM系统能适应数据采集系统的严格要求,如功能性,可靠性,成本,体积,功耗等等。
在本文中提出一种新型的基于ARM嵌入式平台的远程I / O数据采集系统已被研制开发,它可以衡量各种电气和热参数,如电压,电流,热电偶,热电阻等等。那个测量数据可以显示在液晶显示器的系统中,同时可通过使用Modbus / RTU或的Modbus / TCP协议从RS485或以太网网络传送到DAS或DCS远程监控系统。该系统具有双冗余网络和长途电通信功能,它可以确保通信网络的干扰抑制能力和可靠性。基于高性能嵌入式ARM微处理器的新一代远程数据采集和监控系统具有重要的应用意义。
整个系统的结构设计
基于嵌入式ARM的平台的远程数据采集和监控系统的整个结构图在以下的图1中展示。在这系统的计划中,通过使用广泛用于多种行业如电气电力,石油,化工,冶金,钢铁,运输等的嵌入式ARM处理器来开发远程I / O数据采集模块。该系统主要用于的集中采购和将各种电和热信号如电压,热电阻,热电偶在生产过程中进行数字转换。转换的数据可直接在液晶显示器上显示,也可以通过使用的Modbus / RTU或的Modbus / TCP协议的RS485总线或以太网网络通信接口被发送到嵌入式控制器。嵌入控制器平台的数据通过进一步以太网的分析和处理被传送至远程监控中心的工作站。与此同时,这些数据可以存储在远程监控中心数据库服务器的实时数据库中。该系统具有双冗余网络和远程通讯功能,它可以确保通信网络的干扰抑制能力和可靠性。
基于嵌入式ARM远程I / O数据采集系统的硬件平台使用32位ARM嵌入式微处理器和软件平台使用的是开源的并且可移植,削减和巩固的实时多任务操作系统的第二代UC / OS核心。实时操作系统(RTOS)使设计和应用的扩大变得非常容易,增加新的功能时也没多大变化。通过几个独立的任务的应用,实时操作系统使得应用的设计过程极为简单。
苏州大学本科生毕业设计(论文)
系统的硬件设计
基于嵌入式ARM平台的远程I / O数据采集系统具有很高的普遍性,每个购置设备配备24收购方式的I / O渠道且彼此孤立。每个I / O通道可以选择不同的电压和电流信号,以及温度信号如热电阻,热电偶等。在05V的,010毫安和4100TL智能嵌入式以太网串口转换模块。该ZNE500mV的电压信号可以直接接到模拟多路复用器(复用器)的INPx正极和INNx负极。45V的电压信号必须用阻抗转换。热电阻的电阻信号如Cu50,Cu100,Pt50和Pt100应在接到某些频道的复用器INPx正极和INNx负极前连接一1毫安的恒流源。
图4显示了使用16位ADC芯片AD7715的ADC信号电路。芯片与系统的连接非常简单,只需要CS(芯片选择),SLCK(系统时钟),DIN(数据输入),DOUT(数据输出)和DRDY(数据准备)5根线。
由于ARM微处理器具有高速,低功耗,低电压等优点,这使它在低噪音,纹波权力,瞬态响应性能,时钟来源的稳定,功率控制和许多其他方面需要有更高的要求。为了改善系统的可靠性该系统复位电路中使用特殊的微处理器电源监测芯片MAX708S。图5展示了该系统复位电路。
系统软件的设计与实现
苏州大学本科生毕业设计(论文)
基于嵌入式ARM平台的远程I / O数据采集系统的软件使用的是开源的并且可移植,削减和巩固的实时多任务操作系统的第二代UC / OS核心。RTOS的关键部分是实时多任务的核心,其基本功能包括任务管理,资源管理,系统管理,计时器管理,内存管理,信息管理,队列管理等。通过API服务职能核心使用这些功能。
该系统软件平台使用的是单一化的uC/ OS第二代实时简化操作系统核心,使整个结构系统简单和应用层次复杂。整个系统的设计包括操作系统的任务和一系列的用户应用程序。系统的主要职能是实现系统硬件和操作系统的初始化。硬件初始化包括中断,键盘,液晶显示器等。操作系统初始化包括控制模块和事件控制,在多任务调度前,至少有一个任务开始。一个开端任务已建立在这一系统,这系统主要负责初始化和启动的时钟,开办中断,通信任务模块的初始化,以及任务分工等。为了完成实时多任务系统的多种职能那个任务必须被划分。
图6显示系统软件的功能任务。根据任务的重要性和实时要求,系统的应用曾划分为六个不同优先级的任务,其中包括A / D数据采集任务,系统监控,接受队列,数据传送,键盘输入,液晶显示屏显示。A / D数据采集任务要求最高的实时要求和液晶显示器显示任务是最低的。因为每个任务都有不同的优先事项,通过使用系统挂断功能或延迟功能更高的优先任务可以开始已经准备好的任务。
图7显示的是AD7715的数据转换流。A / D转换器的应用是数据采集系统的一个重要组成部分。在uS/ OS的第二代实时操作系统的核心中,A / D驱动程序的实现过程主要取决于A / D转换器的转换时间,有转换价值的模拟频率,输入通道的数量,转换频率等等。典型的A / D转换电路由模拟复用器(复用器),放大器和模拟到数字转换器(ADC)组成。
图8显示了申请程序转移的驱动程序。驱动程序可以在模拟通道读取由复用器,那么几微秒的延迟,以便使信号通过多路开关,并使其稳定。然后,当转换开始时,ADC被触发,并且驱动程序在一个周期内等待ADC的触发,直到完成转换。当等待的进展,该驱动程序检测ADC的状态信号。如果等待时间比规定的时间越长,周期应该结束。在等待的周期时间,如果转换完成ADC的信号被检测到,驱动程序应改为转换的结果,然后将结果返回给应用程序。
图9显示了缓冲区和信号量的序列接收图。由于外围串行设备的存在CPU的运行速度匹配,一个缓冲区是必要的,当数据发送到序列,它必须被写入缓冲区,然后通过串行逐一地被发送出去。当从串行端口收到数据,这些数据将不会被处理直到收到一些字节,因此先前的数据可以存储在缓冲区中。在实践中,两个缓冲区,一个接收缓冲区和一个发送缓冲区,它们是需要从内存开放出来。在这里缓冲区像循环队列数据结构一样被定义。
由于uC/OS-II提供额外时间等待机制的信号,串口也具有额外的阅读和写作能力。如
苏州大学本科生毕业设计(论文)
果收到的数据信号初值为0,它表示循环缓冲区是空的。在中断收到后,ISR从UART接受缓冲区中读到收到的数据,并投入接收缓冲区域,最后通过收到的数据开始用户执行读操作的的任务。在整个过程中,变量价值目前字节在存储缓冲区中的字节的变量值是可以被询问的,这能够表明接收缓冲区是否已满。为了降低数据丢失的可能性和避免浪费存储空间应合理地设置缓冲区的大小。
结论
随着工业过程控制领域的快速发展和网络,智能,数字化分布式控制系统广泛应用,有必要发展对数据准确性和控制可靠性要求更高的系统。由于较差的实时性和可靠性基于单片机数据采集系统已逐步被淘汰。随着嵌入式ARM处理器的迅速普及,ARM处理器替代单芯片实现数据采集与控制成为了一种新的趋势。嵌入式ARM系统能够适应数据采集系统的严格要求,如功能,可靠性,成本,大小,耗电量等等。
篇3:基于嵌入式ARM平台的远程IO数据采集系统的研究和开发
关键词:嵌入式系统,模拟信号,数字信号,特殊信号
数据采集系统的历史较为悠久,近年来,随着电子工业的发展,便携式数据采集系统产品层出不穷。根据不同的采集信号,有不同的设计产品。雷达接口信号采集系统由于待采集信号的复杂性和未知性,其设计更为复杂。
1 数据采集产品现状
一般数据采集系统会按照其总线的不同而分类。常用的总线有以下几种:ISA、PCI、USB、PC104、CAN。
其中USB总线的产品凭借其极高的传输速率和便携性,在市场上占有重要的地位。
USB总线便携式数据采集系统产品的设计原理一般比较简单,一种比较典型的设计是,设计者使用Cypress公司的USB2.0控制器CY7C68013来控制Maxim公司的MA X 1312采样数模转换芯片。这样把由MAX1312采集的数据直接通过USB控制器向上位机发送。设计框图如图1所示。
该数据采集系统只能实现较简单的数据采集功能,不具备功能扩展性。
2 基于嵌入式系统的数据采集系统现状
近年来,不少人投入到基于嵌入式系统的数据采集系统的研究开发中,开发的成果也相当丰富。
按照是否使用ARM将基于嵌入式开发平台的数据采集系统分为非基于ARM和基于ARM两类。
2.1 非基于A R M嵌入式平台的数据采集系统
非ARM嵌入式平台的数据采集系统一般都采用单片机作为其控制核心。结构一般包括选路控制器、AD转换、单片机等几个部分。
不使用ARM的数据采集系统,其功能受到单片机功能的限制,采样速率有限,存储空间较小,不能满足高速大容量采样的需求,更不可能在仪器上运行分析软件,从而摆脱电脑独立工作。某些基于单片机的数据采集系统也只能完成最简单的数据采集功能,而没有进行特殊应用的扩展,其功能甚至不如某些公司非嵌入式系统的USB采集卡。
2.2 基于A R M的嵌入式平台的数据采集系统
ARM系列微处理器功耗低、性能优于单片机,是便携式设备理想的选择,所以ARM越来越多的被应用到便携式数据采集系统。
由于ARM功能强大,能支持一些高级的应用,所以很多情况下,基于ARM的嵌入式系统的数据采集系统具有一定的针对性。它们往往是针对一种专门的对象,提供相关的应用功能。
目前基于ARM的嵌入式系统在数据采集中已经有比较多的应用。每种应用都有它们自己的针对性,并根据对象的不同要求进行了不同的设计。基于ARM的嵌入式系统,是基本原理相似,实质却是天壤之别。
3 基于ARM嵌入式平台的雷达数据采集系统
该采集系统分为便携式数据采集系统,数据管理及分析系统两大部分。便携式数据采集系统主要完成数据的采集和数据的前期处理,获得数据的特征信息,并能回显数据。数据管理及分析系统部署于上位机,用于对数据的存储管理和对比分析。如图2所示
采集对象分为三种类型:模拟信号、数字信号和特殊信号。由各自独立的采集电路实现。模拟信号通过量程自动控制及AD转换电路转换为数字信号,再由FPGA进行采集处理;数字信号则经过缓冲驱动后直接由FPGA处理;特殊信号经过幅值控制和适当的反向后,交由FPGA处理。
倍程自动控制通过压控继电器来实现,将输入电压按比例衰减到合适的范围,然后和基准电压比较确定输入电压的大小范围,根据这个范围,决定继电器的开合,最终将输入电压降低到-10 V~+10 V的范围,并记录衰减的倍数。
AD转换电路采用频率500 Ksps的AD采集芯片AD7665,实现-10 V~+10 V的模拟信号到数字信号的转换。
若待采集的数字信号为TTL信号,而FPGA的输入信号是CMO S信号,则信号进入FPGA前需要先经过一级缓冲驱动芯片处理。
特殊信号为脉宽仅有0.2 us的信号,使用简单运算放大稳压电路就可以实现稳压和反向的功能。不过为了保证信号不失真,需要采用高速运放。
FPGA则接收上面各种信号,并根据控制指令,将信号存储于外接的大容量SRAM中。为了实现这些功能,需要编写一套FPGA程序,实现一个控制系统的功能。该程序包括:采集电路的数字部分、系统时钟、AD采集控制、特殊信号采集控制、数字信号采集控制、SRAM控制、控制系统核心、嵌入式系统接口等部分。如图3所示
嵌入式系统部分采用比较小巧的ARM9系列的嵌入式平台作为硬件开发平台,从而使工作组要集中在软件开发上。开发系统选用了开源的操作系统Linux,从而增加开发的可控性。图形开发环境使用了嵌入式QT,嵌入式QT作为一款开源的图形开发平台有着广泛的应用。与FPGA的通讯使用了串口,FPGA端的串口的波特率基本不受太大的限制,串口速度的主要限制在嵌入式系统端。而S3C2410可以达到460800的串口波特率。嵌入式系统最终将数据存储于SD卡中,便于转存到PC机。
PC机软件系统属于Wi ndow s操作系统,所以采用了MFC作为开发平台。软件系统首先需要将SD卡中的数据转存到PC机的指定目录便于管理。软件系统提供数据显示、比较功能,为后续分析提供基础。
参考文献
[1]刘满仓,雷卫宁,王春成.基于ARM的高精度数据采集系统设计[J].现代电子技术,2012(8).
[2]吕实诚,宋晓波,王晶.基于网络的高精度数据采集卡设计[J].哈尔滨理工大学学报,2012(2).
[3]夏文岳,袁海文.一种复杂数据采集平台在独立电源系统或电力电子装置中的应用[J].电力电子,2012(1).
篇4:基于嵌入式ARM平台的远程IO数据采集系统的研究和开发
关键词:智能家居;Linux系统;arm9;以太网
中图分类号:TP273.5
随着计算机与嵌入式技术的生活化,各种智能化、信息化的消费电子产品不断涌现。这些家用电器在方便人们的生活,提高人们的生活质量的同时,也提出了一个问题,如何对家庭中越来越多的信息家电进行有效的控制。智能家居是由欧美等发达国家提出的一种概念,旨在将家庭中离散的信息设备连接到一个家庭智能化系统上进行集中的或异地的监视控制和家庭事务的管理。随着网络技术和通信技术的不断发展和人们对生活要求的不断提高,实现家庭智能远程控制成为一种趋势,追求精神内涵、安全舒适、便捷智能化和自动化为理想目标。为此,本文提出了一种基于arm9处理器S3C2440的智能家居远程控制系统的设计方法。
1 系统设计
本系统通过多个不同的模块,包括处理器模块、显示模块、存储模块、家电控制模块、安防控制模块、摄像头模块、GPRS模块、蓝牙模块以及以太网接口等[1]。通过这些模块,系统实现了以下与智能家居相关的功能:
(1)家居监控。系统可使用户实时查看家中的温湿度、PM2.5等环境指数。当这些环境指数超出设定的阈值时,系统通过GPRS模块,向用户手机发出短信报警。
(2)远程控制。系统通过家电控制模块,可以让用户对家中的一些家具电器进行控制。
(3)安防功能。可在网络页面上开启视频监控功能,进行实时视频监控,并实现视频存储及移动监测报警,达到安防作用。
(4)门禁功能。可以启用RFID门禁功能作为辅助工具,实现家居的门禁效果。
系统硬件框图如图1所示。
由于篇幅有限,接下来介绍主要功能模块。
1.1 主处理器模块
该模块是整个系统的核心,完成所以接口的调度和事件的处理。主模块选用三星公司开发的一款基于arm920t内核和0.18umCMOS工艺的16/32位RISC微处理器,主频可达500多MHz。具有成本低,功耗低,性能高,接口众多,且其稳定性于可靠性经多年市场的实践,方案成熟,技术支持好。众多的接口令其能轻松完美地驱动系统的各项外设,较高的主频及优秀的CPU及豐富的RAM能令其完美的运行linux系统,完成整体系统的要求。
1.2 通信模
本系统采用以太网接口,GPRS模块,Zigbee模块,蓝牙模块等方式与外界通信。
以太网接口选用DM9000A芯片,与主处理器以16位总线接口相连,可根据需要以单工或全双工模式运行。通过其内部操作时序,可实现系统与以太网的相接。[2-3]
GPRS模块、zigbee模块和蓝牙模块则采用市场上较为成熟的sim900a,cc2530,cc2540等解决方案。这些方案久经市场考验,极为成熟。
1.3 家居外设
本系统采用多项智能家居的外设,如家居控制,环境监控,视频监控等模块。外设与处理器通过can总线,spi总线,USB接口等方式通信[4]。
家居控制模块包括电灯,窗帘,空调等的控制。电灯由继电器控制,服务器记录状态;为了最小程度改变空调结构,系统通过架设红外发射管模拟遥控器。窗帘通过步进电机所转过的角度来控制开闭程度。
环境监控模块则由一系列的传感器构成,如PM2.5传感器,温湿度传感器等。数据一方面上传服务器,可供用户登录查看。另一方面通过阈值监控报警功能,实现安防作用。
视频监控模块采用专用的带USB接口的集成摄像头模块。主机接上大容量的sd卡,能够在用户需要时储存特定时间段的视频,便于日后查看。
2 系统软件设计
整个系统由引导装载程序(U-Boot),设备驱动,嵌入式linux内核以及应用程序组成。这也符合一般嵌入式系统的软件构成[5-6]。
其中,操作系统使用Linux2.6系统内核,应用程序主要包括二个部分:一是是智能家居系统的主应用程序;二是以太网与图形应用界面。
第一部分的主要功能的实现,主要是应用程序的编写,程序流程图如图2所示。
第二部分是图形界面的相关设计。本系统采用qt3软件进行具体界面的设计与移植。
本设计中,先设置好主窗口,在主窗口上添加与控制主题相关的按钮图片。在用户按下按钮时,显示相应界面。在各个外设的界面上,同样用按钮表示相应的操作。这些功能通过qt3的添加控件可以实现。
3 整机效果
在实验室智能家居实验房间内装备相应的系统,通过手机登陆网络,连接服务器ip地址后,通过用户名与密码登陆系统,能够完成相应的操作,并在环境参数超过阈值的时候发送手机短信报警。
4 结束语
通过实验室中的模拟家居环境测试,各项家居外设控制正常,各项监控安防装置能够正常工作,用户能够通过以太网对系统进行智能操控,达到了初期的设计目标。测试结果表明,该系统设计合理,可靠性强,成本低,可操作性好,适合大面积推广。
参考文献:
[1]戴刚,高洋,陈煌华.基于ARM的智能家居远程控制系统的硬件设计[J].世界电子元器件,2007(08).
[2]严厉平.嵌入式智能家庭网关的研究与设计[J].微计算机信息,2005(02):14-16.
[3]刘霞辉,段承先.基于TCP/IP协议的网络家电控制器[J].机械工程与自动化,2009(02):170-172.
[4]徐锋,刘欣,方加宝.智能家居远程控制系统设计[J].低压电器,2009(04):21-24.
[5]孙弋.基于S3C2440的嵌入式Linux开发实例[M].西安:西安电子科技大学出版社,2010.
[6](英)马修.Linux程序设计[M].北京:人民邮电出版社,2010.
作者简介:林昊然(1994.07-),男,本科在读,研究方向:电子电路。
作者单位:中国计量学院,杭州 310018
篇5:基于嵌入式ARM平台的远程IO数据采集系统的研究和开发
1.1 硬件系统设计
硬件系统设计主要包括单机硬件系统设计与多机组网互联设计两个方面:
(1) 单机硬件系统设计。为有效降低设计成本, 单机硬件系统设计可分为承载ARM最精简系统的核心板与根据隔离电源、LCD显示接口及RJ45接口等的具体功能要求而设计的扩展板两个部分。核心板主要包括CPU、FLASH、SDRAM、以太网网卡、声卡以及串口电平转换电路等, 其中可根据应用需求来选择F L A S H与SDRAM, 本文设计中的FLASH是Samsung公司研制生产的K9F1208, 采用NAND技术的存储容量为64MB×8位的高可靠FLASH存储器, 而SDRAM也是该公司生产32M的K4S561632, 并用两片来构成32位系统。而扩展板按要求设计, 并可以根据具体情况所需增加USB接口、输入输出接口以及音频功放电路等。总之, 单机硬件系统设计只要通过简单的网络设计便可以利用网卡接口与因特网连接。
(2) 多机组网互联设计。多机组网互联设计的重点在于多机系统的连接, 通常可先将距离较近的控制设备通过网口与连接因特网的交换机连接组成局域网, 对于范围较大的局域网则可加中继器。若是组网环境的安全可靠性要求较高, 则可以依据工业以太网的要求来实现组网目的。
1.2 软件系统设计
软件系统的设计主要包括以下几个方面:
(1) 建立交叉开发环境。由于资源受限, 直接在硬件平台上编写软件是较为困难的, 而通常采用的是宿主机/目标机开发模式, 即是将编写于通用计算机上的程序通过交叉编译而生成可以再目标平台上运行的二进制代码格式, 然后将其下载到目标平台上实现运行。
(2) 选择图形用户界面。较之于通用的图形用户界面, 嵌入式系统下的图形用户界面要求更高的性能与可靠性, 且还要可配置并占用资源少, 本文设计中采用相对较成熟的Qt/Embedded, 它是一个有高可靠性和可移植性的多平台C++图形应用界面程序框架, 对于移植到嵌入式版本可以更便捷可靠, 且由瓦安备的网络支持, 还有各种部件以支持TCP/IP协议。
(3) 网络编程。选用应用较广的TCP/IP协议、客户机/服务器模型并基于socker编程技术进行网络编程, 服务器在客户机/服务器模型中处于监听等待状态至有客户提出服务地址的连接要求, 服务程序被客户要求激活并提供服务, 而在ARM控制设备为服务器的监控应用中, 可按一对一或一对多模式设置ARM控制设备, 而ARM可响应客户机并根据越好的通讯协议交互数据以实现远程监控。
2、基于ARM的嵌入式远程控制系统的实现应用 (如图1)
上图所示即为系统服务端管理员的运行界面, 结合了触摸屏以及LCD显示并为减小硬件体积而设计了软键盘, 通过直接点击视频区方位, 管理员可实现对摄像头转动的控制, 还可以直接利用界面按钮来管理用户信息。
为保证客户数量较多或是访问频繁等情况时系统的正常稳定运行, 需要对这种情况进行模拟测试并对系统的运行状况进行观察, 也就是对服务端提供的网络视频服务的饱和状态进行稳定性测试与压力测试。通过测试程序Web Application Stress对源自于开发板的网络视频服务的20个线程进行连续5分钟的访问测试, 而测试结果表明:系统响应速度很快, 刷新视频图像的平均时间依然是不超过0.2秒, 而对于较多客户端浏览器频繁访问网络视频服务的需求也能同时满足, 即是说, 开发板所提供的服务能有效保持持续高效。并且, 在系统工作连续48小时进行时, 服务端对于随机“添加”或“删除”授权网络用户列表等操作并无不良反应, 也没有死机或重启现象, 能持续正常运转, 具有良好的稳定性。
3、结语
总之, 监控系统已经在现代化生活与生产中发挥了重要作用, 并得到人们的广泛认可, 也必将长期应用于生活与生产实际, 而计算机网络技术的快速发展为监控系统能更好地发挥作用奠定了可靠的技术基础, 远程监控系统在目前已有的基础上, 经过不断的研究和分析, 还将在安保领域得到更高的重视和广泛应用。
摘要:本文即是从远程控制系统入手, 对基于ARM的嵌入式Internet远程控制系统的设计与实现进行分析和探讨。
关键词:ARM,嵌入式Internet,远程控制系统
参考文献
[1]孟力.基于ARM处理器的嵌入式远程温度监控系统设计[J].电工电气, 2009 (6) .
[2]方勇军, 王云景, 赵红旗, 邓亲恺.基于ARM和互联网技术的远程控制系统的设计[J].仪表技术, 2007 (6) .
[3]陈岩, 叶炜.基于ARM的远程控制系统的设计[J].自动化仪表, 2005 (11) .
相关文章:
嵌入式操作系统程课程设计报告01-12
基于ARM嵌入式的远程监控系统设计01-12
高考英语完形填空解题策略与技巧01-12
嵌入式系统设计基础总结报告01-12
弹载嵌入式系统设计技术01-12
2019党员干部观看《榜样4》经典观后感01-12
嵌入式设计系统01-12
基于嵌入式系统的电力系统监控软件设计01-12
基于闪存的海量图像存储系统的设计01-12