0% found this document useful (0 votes)
84 views4 pages

Design of Automatic Meteorological Data Acquisition System Based On ARM and CAN Bus

Design of Automatic Meteorological Data Acquisition System based on ARM and CAN Bus. It fulfills the acquisition requirements of the analog signals, digital signals and intelligent sensor data. It is transplanted Linux operating system to embedded processor, and making use of Internet to send meteorological data in Linux operating system.

Uploaded by

Senthil Kumar
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
84 views4 pages

Design of Automatic Meteorological Data Acquisition System Based On ARM and CAN Bus

Design of Automatic Meteorological Data Acquisition System based on ARM and CAN Bus. It fulfills the acquisition requirements of the analog signals, digital signals and intelligent sensor data. It is transplanted Linux operating system to embedded processor, and making use of Internet to send meteorological data in Linux operating system.

Uploaded by

Senthil Kumar
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

Design of Automatic Meteorological Data Acquisition System Based on ARM and CAN Bus

Jvfang Jin1
Department of Electrical Engineering Chengdu University of Information Technology Chengdu, China [email protected]
AbstractAimed at the current situation that the domestic automatic meteorological data acquisition system is almost based the use of foreign products, a design method of multi-channel meteorological data acquisition system was given which based on ARM and CAN Bus. In the design, it fulfills the acquisition requirements of the analog signals, digital signals and intelligent sensor data through a combination of hardware and software technologies. In order to improve systems real-time answering capability and multi-task processing capability, it is used main collector + external bus + sub-collector + sensors + peripheral equipment in structure design of hardware. At the same time, it is transplanted Linux operating system to improve the reliability and scalability of system. It is translated Linux operating system to embedded processor, and making use of Internet to send meteorological data in Linux operating system. Then the complicated cabling project could be omitted, the data were sent without PC, and in favor of constituting Large-scale meteorological monitoring network. (Abstract) KeywordsData acquisition; Embedded Linux; CAN bus; Driver(key words)

Baoqiang Wang2
Department of Electrical Engineering Chengdu University of Information Technology Chengdu, China [email protected] expansion, improving the timeliness and accuracy of the meteorological observation, and achieving the commands of automatic meteorological observation. II. SYSTEM DESIGN

As shown in Fig.1, the design of the automated meteorological data acquisition system is based on the embedded Linux and the CAN bus.

I.

INTRODUCTION

Figure.1 Automatic Meteorological Data Acquisition System

Nowadays meteorology has been closely related to the human civil and industrial activities. Meteorological detection plays an important role in defense, social and economic development. With the gradual implement of national sustainable development strategies, meteorology detection is more and more important for us. Meanwhile, there are everincreasing demands for meteorological observations. The traditional design pattern of meteorological data acquisition system was based on the single-chip microcomputer. In this situation, there are many problem including system precision, real-time analysis capabilities, the man-machine interface and so on.Computing power, storage capacity and the amount of information were limited by this technica. In the same time, both the distance of data transmission and the use of data acquisition module with PC or notebook computer cost too much money and time. Compared with the situations above, the pattern of using embedded LINUX system assumes a higher real-time and stability in meteorological data acquisition, meanwhile the hardware smaller, power consumption lower and expansibility better. The Linux operating system supports the TCP / IP protocol, so it can transmit data directly without PC. This pattern also has many other advantages, such as speeding up the development of the system, facilitating the works of the future
978-0-7695-3962-1/10 $26.00 2010 IEEE DOI 10.1109/ICMTMA.2010.598 989

Embedded Linux is a kind of small operating system, which is composed by a cut-off core (kernel) and several modules that depended on the needs. Its characteristics are as follows, micro-kernel of only several hundred KB; supporting X86 and more than 30 kinds of 8bit ~ 64 bit of the MPU and MCU, supporting a variety of ROM memory; the features of multi-tasking, multi-process and a certain degree of real-time; supporting completed communications network; supporting TCP / IP protocol and other common agreement; supporting self-developed agreement; a graphical user interface (GUI); supporting network, database and multimedia and communicating data by the network and processing data in real time; source opened which can be cut according to specific needs; a series of development tools;a good property of software open and the program on the Linux host can be transplanted to embedded Linux system freely, a strong technical support and so on. CAN (controller area network) field bus is a kind of serial multi-master communication network. CAN is not only a network, but also a kind of protocol. Its main features are as follows, the pattern based on the CSMA / CD-CR model, the use of non-destructive arbitration mechanism, short-frame data structure; the CRC data check function, the data transmission

based on the differential approach, queue priority according to message ID, the system well expansibility, anti-interference ability and reliability. The automatic meteorological data acquisition system which is based on the multi-tasking, real-time embedded Linux OS and the CAN network constitutes a building-block structure, facilitating future updates or changes. A. System Hardware Design As shown in Fig.1 above, automatic meteorological data acquisition systems hardware consists of main collector, subcollector, sensors and peripheral equipment (including power supply, [terminal] computer, communications interface and external memory). The main collector and sub-collector microprocessor adopt an ATMEL chip AT91SAM9263 which based on the ARM926EJ-S processor. Its frequency is up to 200MHz and it has a CAN bus controller integrated in chip. Sub-collector is hang on to the main collector through CAN bus. In order to achieve the minimum allocation of automatic meteorological data acquisition system, the main collector is joined only several basic meteorological elements sensors, taking charge of the collection of the basic meteorological data (Its structure is shown in Fig.2).

Figure.3 Sub-collector Structure of Automatic Meteorological Data Acquisition System

When the system is needed of being expanded or increasing element sensors as the change of environment or technology progress, we have no need to change the connection of the existing sensors and wiring. We just need to add new subcollector and /or sensors to the system and conduct simple software upgrade or configuration. B. System Software Design System software includes embedded operating system and application software. We have chosen a high real-time, costeffective, stable and multi-tasking operating systemLINUX OS as the platform of the system software design according to the needs of the design. 1) Construction of Embedded Linux System The system software is mainly built in the main collector, including three elements at least: bootstrap program, Linux micro-kernel and initialization process. In addition, there are several functions needed to be expanded, such as, the achievement of the agreement to CAN master, the achievement to jffs2 file system in the internal memory and external memory card, the basic collection, processing, storage and internet transmission of the data, the establishment of the Web server and remote parameter settings, data monitoring, the loading of data files and the main collector reset. Sub-collector software is needed to achieve the agreement to CAN slave, scans its articulated sensor according to the predetermined sampling frequency and converts the electric signal obtained into a readable microcontroller signal, gains the sequence of measurements of meteorological variables, converts the measurements of meteorological variables , changes the sensor output signal into meteorological units, gets the instantaneous sampling values, and sampling values will be sent to the CAN bus according to CAN agreement. 2) Reduction and Compilation of the Kernel Micro-computer's storage space is small, while the standard Linux is a PC OS, which needs to reduce the Linux kernel. It can only retain some modules that the embedded system needs and must remove some useless modules when compiling the kernel. In order to satisfy a certain degree of real-time requirements, it should shield the kernels virtual memory management mechanisms. There are two ways to launching

Figure.2 Main collector structure of automatic meteorological Data Acquisition System

In addition, the main collector is in charge of collecting, controlling, processing, storing, transmitting all kinds of meteorological factors data and fulfilling the function that configures and manages the sub-collector. The sub-collector is composed of hardware and embedded software. In order to simplify the design trouble of the system, sub-collector microprocessor also adopts the same chip AT91SAM9263.It is mainly responsible for collecting corresponding meteorological data. At the same time, it is also responsible for scanning its articulated sensor according to the predetermined sampling frequency in the working condition and sending the sampling data to the main collector after receiving the synchronization signal which is sent by the main collector. Its structure is shown in Fig.3,

990

Linux, one is that drivers were directly compiled into the kernel; the other is that drivers were loaded at runtime (that is, kernel module). The advantages of the former are that users can call them at any time without installing them, but it largely costs storage space. The latter is that drivers were prepared in the form of module, and they will be loaded into kernel when needed. Maybe it would increase the occupation of system resources and running time, but it is negligible compared to the huge consumption of kernel resources. Meanwhile, this way can provide many conveniences for the software development. When the users need to modify a hardware driver or correct their errors, they can dynamically unload the old version and load the new version; but if the driver has been wrote into the kernel, the users must recompile the kernel and restart the system when testing procedures after each revise. Therefore, the system is chosen the second approach to start the kernel. 3) Device Drivers Operating system is responsible for managing software and hardware of the system. Device drivers play the role as a bridge between the hardware and user application program. They make the application program have nothing to do with the underlying hardware through interface function provided by them. For the system, we need to prepare drives for I/O port, serial and CAN controller. There are three types of equipment in Linux system, Character Devices, Block Devices and Network Equipment. Character devices can only be read and write data sequentially, and provide byte-stream operation to the external. Block devices can be read and write data randomly. All these three types of equipments have a rough same structure of the drivers. a) The structure of device drivers In Linux system, the equipment is generally mapped to a special device file. The user can freely perform any operation on it like an ordinary file. Each device is treated as a file in Linux so that the application program can use system calls, such as read and write, to operate it as an ordinary file. The structure of the Linux device drivers is shown in Fig.4.

For the Character and Block Devices, Linux kernel have been conducted an unified abstraction on their file operations, such as open, close, read, write, ioctl, poll, mmap and so on, which are embodied in the structure file_operations included in the fs.h document. struct file_operations{Struct module*owner;
// Module owner

loff_t(*llseek) (struct file*,loff_t,int);


// file-moved pointer, only be used for random access devices

ssize_t(*write)(struct

file*,const

char*,size_t,loff_t*);

//Write data to the characters device

ssize_t(*read)(struct file*,char*,size_t,loff_t*);
//Read data from the device, similar to write

unsigned int(*poll)(struct file*,struct poll_table_struct*);


//Query the state of equipment

int(*ioctl)(struct inode*,struct file*,unsigned int,unsigned long); //control equipment, commands except reading and writing int(*mmap)(struct file*,struct vm_area_struct*); //Map the content of the equipment to address space int(*lock)(struct file*,int,struct file_lock*); //File locking for mutually exclusive visit when file is sharing Int(*open)(struct inode*,struct file*); // Open the device and perform I/O operation int(*release)(struct inode*,struct file*); //Shut down equipment and release the resources }; Seen from the definition of the structure file_operations above, all of its members are function pointers. So in essence, the core of function jump table visits the driver by this structure. The structure used in the procedure is as follows: static struct file_operations test_fops= { owner:THIS_MODULE, write:test_write, read:test_read, ioctl:test_ioctl, open:test_open, release:test_release, }; In the Linux kernel, it uses the macros module_init () and module_exit to initialize the driver module and record the name of function that had quitted, the template of driver is as follows,

Figure.4 Structure of Linux Device Driver

b) The template of drivers

#include<linux/module.h> #include<linux/config.h> #include<linux/init.h> Static int__init name_of_initialization_routine(void)

991

{ /* Driver initialization and operational definition */ } Static void__exit name_of_cleanup_routine(void) { /*The handling operations after the ending of the driver*/

time of meteorological detection, high precision, high degree of automation, cost-effective, a long-time and continuous observations, good reliability, high stability, anti-jamming, etc.

}
module_init(name_of_initialization_routine); module_exit(name_of_cleanup_routine); The drivers of the meteorological data acquisition system can be prepared according to the driver template supplied above. Drivers that should mainly include CAN bus driver, clock driver, serial driver and some hardware drivers. They can be loaded when the system starts at boot time by the kernel module after they were completed and compiled successfully. Then, user application program can directly manage and configure the software and hardware of the Automatic Meteorological Data Acquisition System according to document. 4Application software Application software mainly includes system data quality control software, data processing software and Web browser interface. The data quality control software of the system pretreats the data that collected, removes the unreasonable data. Then the data obtained is transmitted to data processing software for processing, forming the specified data format. A data browse page for the users will be provided by Web browser. Users can modify, add and delete the data through the browse page. At the same time, users can achieve the function of data query and data retrieval. The implementation of the system is shown right in Fig.5. III. CONCLUSION

Figure.5 Implementation flow chart of system

ACKNOWLEDGMENT The authors of the paper are grateful to Chengdu University of Information Technology. REFERENCES
[1] Z.L.Ao, The Design and Implementation of Automatic Meteorological Data Acquisition System Based on CAN Bus. Computer Measurement and Control, pp.491-498,2006. Z. K. Hu and J.Q. Li, Design of Automatic Meteorological Data Acquisition System Based on Embedded Linux. Electronics Engineers, Vol. 30, No. 2, pp. 69-71, 2004. Z. K. Hu and J.Q. Li, Design of Automatic Meteorological Data Acquisition System Based on Embedded Linux. Electronics Engineers, Vol. 30, No. 2, pp. 69-71, 2004. Z. B. Shu, et al, Field Bus Motion Control System. Publishing House of Electronics Industry, 2006. Z. J. Li, Field Bus and its Applications Technology. Machinery Industry Press, pp.495, 2005. Zhou Yu, et al, The Design and Implementation of driver of CAN bus based on Embedded Linux. Computers and automation technology, Vol. 34, No. 8, pp. 50-52, 2008. Peng Yu, Embedded Data Acquisition System Based Linux, Technology Center.

[2]

[3]

[4]

The system, whose design is based on Embedded Linux and CAN bus architecture, has a building-block structure and intelligent function modules. In terms of software design, it supports any combination of systems function modules. So, there is no need to change the original hardware and software design, just to add new sub-collector and/or sensors to the system and conduct simple software upgrade/configuration. The advantages of such a design are as follows, a higher real-

[5] [6]

[7]

992

Common questions

Powered by AI

The CAN (Controller Area Network) bus enhances the functionality of the automatic meteorological data acquisition system by providing a robust and reliable method for data transmission between system components. Its features include a non-destructive arbitration mechanism, a short-frame data structure, and CRC data check functions, all contributing to high data integrity and error detection capabilities . The CAN bus model supports multi-master communication, enhancing the system's ability to manage multiple data sources effectively. Additionally, its anti-interference capability and well-defined protocol structures ensure that data collected by sub-collectors is transmitted accurately to the main collector .

The main advantages of using an embedded Linux system for meteorological data acquisition include higher real-time processing capabilities and system stability. The embedded Linux system supports a reduced kernel that offers good multi-tasking and process handling. It allows for the system to operate independently of PCs, facilitating the direct transmission of data via TCP/IP and supporting the development and expansion of a large-scale meteorological network . Additionally, it provides a flexible platform where drivers and system functions can be dynamically managed, which is essential for handling the diverse data processing needs in real-time environments .

The ARM processor, specifically the ATMEL chip AT91SAM9263, is central to the operation of the automatic meteorological data acquisition system. It is utilized in both the main and sub-collectors, providing the necessary processing power for data collection, processing, controlling, and transmission tasks . Its integration with a CAN bus controller enables efficient handling of data communication and task management, leveraging up to 200MHz frequency for real-time data processing . The ARM processor's capabilities ensure the system maintains high performance with low power consumption, which is crucial for the continuous and reliable operation of meteorological monitoring systems.

Improved real-time processing capabilities in meteorological data acquisition systems are enabled by several design elements, including the use of the ARM-based processor which provides high processing speeds and efficiency. The integration of the CAN bus supports parallel data processing and efficient communication between multiple system components, essential for real-time data management . Additionally, the embedded Linux OS presents a compact yet powerful platform supporting multi-tasking and real-time scheduling, ensuring that data is processed and transferred quickly and predictably . Together, these elements facilitate prompt data acquisition and processing, maximizing the system’s capability to provide timely meteorological insights.

The CAN bus protocol contributes to the anti-jamming capabilities of the meteorological data acquisition system primarily through its robust error detection features and differential signaling. It employs CRC (Cyclic Redundancy Check) for error checking, ensuring data integrity during transmission. The use of unique identifiers for messages helps in organizing data priority and reducing collisions, which is particularly important in the shared communication environment typical of fieldbus architectures . Furthermore, the protocol's differential signaling minimizes susceptibility to electromagnetic interference, a common issue in outdoor and long-distance data transmission contexts, thus preserving the reliability and precision of meteorological data collection.

The Linux operating system's support for TCP/IP significantly enhances data transmission in meteorological data systems by enabling direct and efficient network communication for data transfer. TCP/IP is a reliable protocol that ensures data packets are transmitted promptly and accurately over the network, which is critical for systems needing real-time data exchange and minimal data loss. This protocol reduces dependency on PCs for data handling, enabling data to be sent directly from embedded devices to centralized servers or monitoring tools over the Internet or local networks . This feature facilitates the integration of meteorological data into larger data systems and supports real-time monitoring and analysis capabilities essential for timely weather forecasting and environmental analysis.

Using modules for drivers in Linux enhances system flexibility because it allows drivers to be loaded and unloaded dynamically as needed without requiring system recompilation or reboot. This modular approach means that system resources are conserved as drivers do not need to occupy memory constantly; they are loaded only when required. This is crucial in embedded systems like a meteorological data acquisition system where memory and processing resources are limited. Furthermore, it simplifies software maintenance and updating processes, as drivers can be replaced individually without impacting the entire system's operation . This dynamic management of drivers is integral to coping with the diverse and evolving demands of meteorological data processing and device management.

Using a building-block structure in the design of a meteorological data acquisition system allows for greater adaptability and scale-up capabilities. This approach aids in the modular expansion of the system, where new functionalities can be added as independent modules without affecting the core system configuration. As technological advancements occur or environmental monitoring needs change, new components or sensors can be easily integrated into the existing framework, ensuring the system remains up-to-date and capable . Additionally, this design minimizes costs and efforts associated with system upgrades or reconfiguration, hence presenting a future-proof solution that enhances the responsiveness and long-term value of meteorological data systems.

The system can be expanded by adding new sub-collectors and/or sensors, which can be integrated without altering the existing hardware or software setup. The modular design of the system, based on embedded Linux and CAN bus architecture, allows for seamless expansion. This design supports the dynamic addition of new components by configuring and updating the software to accommodate enhanced operational requirements. This flexibility is achieved without the need to disconnect or alter the existing network of sensors and collectors, making the system both cost-effective and highly adaptable to technological advancements or environmental changes .

The integration of a web server enhances the functionality of the automatic meteorological data acquisition system by providing a platform for remote monitoring, data access, and control. It allows users to interact with the system through a web interface, making it possible to view data, perform configurations, and update system settings from disparate locations via standard internet browsers. This accessibility facilitates quick responses to changing weather conditions or system states, enhancing the system’s usefulness in real-time meteorological monitoring . Additionally, it supports the dissemination of data to broader networks or cloud services for further analysis, contributing to advanced data utilization and collaborative meteorological research.

You might also like