Implementation of Low Cost Data Logger Using Flash Disk with File Allocation Table

Total Page:16

File Type:pdf, Size:1020Kb

Implementation of Low Cost Data Logger Using Flash Disk with File Allocation Table Implementation of Low Cost Data Logger Using Flash Disk with File Allocation Table Panupong Thanutong1, Dusit Thanapatay2, Kamol Kaemarungsi3 and Tsuyoshi Isshiki4 1TAIST Tokyo Tech, ICTES Program, Dept. of Electrical Engineering, Kasetsart University, Jatujak, Bangkok 10900, Thailand 2Dept. of Electrical Engineering, Kasetsart University, Jatujak, Bangkok 10900, Thailand 3Embedded System Technology Laboratory, National Electronics and Computer Technology Center, Pathumthani 12120, Thailand 4 Dept. of Communications & Integrated Systems, Tokyo Institute of Technology, S3-66, 2-12-1, Ookayama, Meguro-ku, Tokyo 152-8550, JAPAN computer for further analysis using software analyzing tools. Abstract— Data logger is a device used for storing Data loggers can be applied in various fields such as in [1] measurement data. It can be used in wide range of embedded where data logger is used to observe city’s air environment or in logging applications. This paper reports on practical development [2] where it is used for collecting galvanic skin response (GSR). experience and design’s details of a low cost data logger prototype. In this paper, we developed a prototype of low cost data The data logger in this paper is also compared with two of existing data loggers in the literature. This data logger combines 32-bits logger as a part of our planned research project in a microcontroller and flash disk with file allocation system (FAT) hydrological system application for monitoring rivers. The data together with programming technique to control the hardware for logger will be connected to a hydrological sensing system recording and monitoring of general proposes measurements. which consists of a set of wireless sensor nodes and several This data logger stores the data on removable flash disk for hydrological sensors. However, to test our prototype in this convenient and can forward real time measurement data through paper we decided to use basic sensor device which can be RS232 standard serial port to be display on LCD. The applications studied in this paper are based on logging of obtained easily such as temperature and humidity sensors. temperature and relative humidity from a SHT15 digital sensor. These sensor devices are low cost and simple to integrate to our The data are stored in form of comma-separated values file (CSV) data logger prototype. For example, SHT15 is an integrated because this file format can be read and understood by many temperature and relative humidity sensors in one package [9] platform applications such as MySQL, MS-Excel, and MATLAB. which is very convenient. We designed our prototype of data The microcontroller in this prototype provides power down mode logger based on [3] with different structure for both hardware function that can save energy during long waiting operation and its storage memory can record measurement data for several and software. years. Keyword: data logger, embedded system, temperature and Relative humidity sensing, FAT system. I. INTRODUCTION owadays, the applications of embedded and ubiquitous N sensing systems are increasingly popular. Examples of embedded sensing application are in the area of monitoring systems such as meteorology, hydrological, mining and food industries. A data logger is an embedded electronic device that can be a part of those monitoring systems. The main functionality of data logger is to record data from sensing system over time. Generally, a data logger can obtain data from Fig 1. System architecture of the data logger measurements in several ways such as through attached Fig. 1 illustrates the system architecture of the data logger in analog-to-digital converter (ADC) or sensory data sent via this paper. At the center, the microcontroller is the heart of the various communication protocols and serial communication data logger where we use STM32 ARM Cortex M3 which is a port (USART). The data maintained in the data logger collected low cost 32-bit microcontroller with a lot of built-in from monitoring system can be transferred to personal functionalities. Our data logger consists of major component such as a RS232 serial interface for communication with personal computer, a SHT15 temperature and relative humidity sensor for measuring environment, a 16-character by 2-line [9]. Finally, this data logger prototype can also take inputs from liquid crystal display (LCD) to display data output, Micro SD other measurements through additional ADC ports on the card for a storage memory, and other analog input/output (I/O). MCU. The ARM Cortex M3 provides three channel of 10-bit The organization of this paper is as follows. First, Section II ADC for connecting with other sensors such as CO2 sensor as in describes the hardware design and each major component. [1]. Note that the data logger circuit can measure voltage Next, Section III describes our embedded software design for between 0 and 3.3V at ADC channel 1. the data logger. Next, Section IV reports on preliminary C. Storage Memory measurement results and compares our data logger with others. Finally, Section V concludes our work and briefly mention Traditionally, the storage memory for most data loggers was about our future works. based on electrically erasable programmable read-only memory (EEPROM) or small general purpose random access memory II. HARDWARE DESIGN (RAM) [6]. These devices were easy to use and require lower write cycle. However, today flash memory in form of MicroSD A. Microcontroller Unit (MCU) card is getting cheaper with larger capacity. Thus, MicroSD The selected microcontroller unit for the data logger system cards are gaining popularity in modern embedded system. The is an STM32F103 ARM Cortex M3 [15]. This microcontroller MicroSD cards used in this prototype are very small with (MCU) provides a good price per performance when compared dimension of 15mm x 11mm x 0.7 mm and weight only 0.0.4g to others well known microcontrollers such as MSP430 [5], [1]. The capacity of MicroSD used in this work is 2 GBytes AVR32 [6], and PIC16 [7]. The price of this MCU is very since it is the maximum physical limitation for FAT16 [1]. The attractive among those popular MCUs. With 32-bit main advantage for using MicroSD card as data storage system architecture, it provides better computational power at similar is the ease of transferring data directly to other electronic or lower price point than some 16-bit architecture. The major devices such as laptops or smart phones which support FAT advantage of ARM Cortex M3 lies in its Thumb-2 instruction format as file system. User can reduce the time to transfer and set which allows this MCU to have 32-bit performance with convert the data from traditional EEPROM to other data 16-bit code density [8]. Moreover, it can run at 1.25 DMIPS analysis systems. (Dhrystone Million Instructions per Second)/MHz. The MCU D. Circuit Diagram is faster up to 35% and up to 45% less code than ARM7TDMI [8]. It is fully equipped with a number of peripheral interfaces Our data logger prototype is developed on existing such as I2C, SPI, USART, analog-to-digital converter (ADC) development board called ET-STM32F103 from ETT and digital-to-analog converter (DAC). Another reason for Company [11]. Fig. 2 depicts a circuit diagram of our prototype choosing this MCU is that its manufacturer provides free which is based on schematic from [11] that were attached with license of standard firmware libraries to be used in SHT15 from [9] and an LCD. Note that the peripherals around development of complex applications. the MCU are similar to the architecture in Fig. 1 which consists of RS232 interface, LCD, SHT15 sensor, and SDMCC socket B. Measurement Module for SD card. We chose this board because we needed a stable For our evaluation purpose, we initially use only one sensor hardware platform for programming and performing for our test. A sensor device called SHT15 is attached directly experiment. We plan to develop our own print circuit board to the microcontroller ARM Cortex M3. SHT15, which is a (PCB) once the prototype and its peripherals have been well known sensor device, is applied in measurement module verified. where it provides sensory data to our data logger. This sensor device has analog-to-digital conversion over linear temperature and relative humidity and it has built-in on chip ADC circuit [9]. Thus, we do not require separate ADC before attach the sensor device to MCU. This simplifies the testing of our prototype. Note that with the structure of this SHT15 sensor chip is different from the one used in [3] where they used pure analog sensors. Additional advantages of this sensor device are that it can reduce the component count and the hardware complexity. Another advantage of SHT15 is that it has fast response time and uses CMOSens technology to guarantee reliability and stability [9]. The size of this device is also small with a dimension of 7.47 x 4.93 x 2.5 mm. Its weight is only 100 mg. The sensor also requires low power consumption with average current consumption of 28µA and can be used with single power supply between 2.4V and 5.5V [9]. The SHT15 has operating range for temperature between -40 to 123.8 Fig 2.Simplified circuit diagram of the system Celsius and range for relative humidity between 0 to 100%RH III. SOFTWARE DESIGN B. Programming Language A. Flowchart Diagram of the Data Logger The software was developed using C language, cross-compiled, and loaded into the MCU. We used IAR The flowchart of embedded software that controls our data Embedded Work Bench for ARM as a complier tool [12]. logger is showed in Fig. 3. In this section, we briefly explain the operation of our data logger. C. FAT File System In the first step, user needs to configure parameters for To implement the FAT File System into the propose data sensory data recording via USART.
Recommended publications
  • Task Order 7 of the Commercial Motor Vehicle Technology Diagnostics and Performance Enhancement Program Foreword
    Task Order 7 of the Commercial Motor Vehicle Technology Diagnostics and Performance Enhancement Program Foreword This project is one of several performed under the provisions of Section 5117 of the Transportation Equity Act of the 21st Century (TEA-21). The primary objective of this project was to explore the potential for the development of cost-effective vehicle data recorder (VDR) solutions tailored to varied applications or market segments. Through a combination of technical research and analysis, including business-related cost-benefit assessment, potential VDR configurations ranging from fundamental to comprehensive were explored. The work performed under the project included: • Capturing the available results of this research and synthesizing information from the commercial vehicle user, original equipment manufacturer (OEM), equipment supplier, and recorder manufacturer communities. • Profiling high-level functional requirements of VDRs, which were extracted from industry and government findings (NHTSA, FHWA, TRB, ATA/TMC), as well as surveying and interviewing key industry stakeholders, and assessing end-user needs and expectations regarding VDR capabilities and required data parameters. • Developing several VDR concepts with different levels of VDR sophistication. VDR concepts were formulated and targeted for the following end-use applications: − Accident reconstruction and crash causation − Operational efficiency − Driver monitoring • Profiling and analyzing advanced VDR technologies that could be added to any of the concepts developed. • Identifying and estimating the costs and benefits for each of the VDR concepts developed. The results from this project can be used by motor carriers in helping evaluate vehicle data recorder applications, costs, and potential benefit scenarios. Notice This document is disseminated under the sponsorship of the Department of Transportation in the interest of information exchange.
    [Show full text]
  • 2010 Test & Measurement Catalogue
    2010 Test & Measurement Catalogue Established in 1991, Pico Technology is a worldwide leader in the field of PC- based test equipment and data acquisition. Our products regularly win industry awards, with our past achievements including: We offer all of our customers unbeatable technical support, with our team of experts on call to answer your query or to advise you on the best product to suit your need. Our stringent quality controls ensure that you receive the highest quality products with the very best level of service. We often get comments like this from our customers : “I would like to add that in today’s world and economic climate it is truly refreshing to learn that there are still companies in this country which market products like yours, and who you can call up and get met with the level of help and support which I have been shown.” BC, UK. CONTENTS PC Oscilloscopes 03 Temperature & Humidity Data Loggers 41 PicoScope Software 09 TC-08 41 PicoScope 2000 Series 13 Thermocouples 42 PicoScope 3000 Series 15 PT-104 43 PicoScope 4000 Series 17 PT100 Temperature Sensors 44 PicoScope 5000 Series 19 HumidiProbe 45 PicoScope 6000 Series 21 Other Products 46 PicoScope 9000 Series 23 - Education Kit 47 Oscilloscope Accessories 29 - EnviroMon 48 Data Loggers & Data Acquisition 35 - Automotive Scopes & Kits 48 PicoLog Software 35 Ordering Information 49 Voltage Data Loggers 39 - PicoLog 1000 Series 39 - ADC-20 & ADC-24 40 PicoScope PC OSCILLOSCOPES COMPACT AND PORTABLE UNITS FREE SOFTWARE UPDATES Unlike traditional bench-top instruments that contain a PC as well as the If you’re lucky you can return a traditional DSO to the supplier for a firmware measuring hardware, Pico Technology’s PC oscilloscopes are light and portable.
    [Show full text]
  • Smart Real Time Data Logging System for Industrial Automation Using I2C Protocol
    Published by : International Journal of Engineering Research & Technology (IJERT) http://www.ijert.org ISSN: 2278-0181 Vol. 8 Issue 07, July-2019 Smart Real Time Data Logging System for Industrial Automation using I2C Protocol R. Sarojini1 M. Vijayakumar2 Assistant Professor, Assistant Professor, Department of ECE, Department of ECE, Government College of Engineering Srirangam Government College of Engineering Dharmapuri S. Ramalingam3* Research Scholar, Department of EEE, Alagappa Chettiar Government College of Engineering and Technology Karaikudi Abstract- This proposed paper work aims to develop a I2C is superior among all this these technologies. As I2C has the protocol based industrial machine status and data monitoring feature of low cost, easy to implement, Error checking, high system. It was the I2C bus for addressing the machines and it data transmission rate. Hence this project describes the I2C also has the capability of connecting up to 256 machines. We based communication between the electronic devices for can do this in a single I2C chip. In order to reduce the cost, industrial automation [2]. manual work and interfaced with ATmega 328 microcontroller and to improve the efficiency by using I2C bus. The industrial In general industrial machine monitoring is a process remote machine monitoring system plays an important role in of periodically monitoring the status of the machine to industrial application and they are to a large extent reinforce the overall products productivity. The information universally. sent by the machine
    [Show full text]
  • Cave Pearl Data Logger – a Flexible Arduino-Based 3 Logging Platform for Long-Term Monitoring in Harsh 4 Environments 5 Patricia A
    Preprints (www.preprints.org) | NOT PEER-REVIEWED | Posted: 16 January 2018 doi:10.20944/preprints201801.0139.v1 Peer-reviewed version available at Sensors 2018, 18, 530; doi:10.3390/s18020530 1 Article 2 Cave Pearl Data Logger – A flexible Arduino-based 3 Logging Platform for Long-Term Monitoring in Harsh 4 Environments 5 Patricia A. Beddows 1 * and Edward K. Mallon 2 6 1 Department of Earth & Planetary Sciences, Northwestern University, 2145 Sheridan Rd – Tech F374, Evanston, 7 IL 60208-3130; [email protected] 8 2 Triple Point Design, LLC; [email protected] 9 * Correspondence: [email protected]; Tel.: +1-224-420-0977 10 11 Abstract: A low-cost data logging platform is presented for environmental monitoring projects that 12 provides long-term operation in remote or submerged environments. Three premade “breakout boards” from 13 the open-source Arduino ecosystem are assembled into the core of the data logger. The components are selected 14 based on low-cost and ready availability, making the loggers easy to build and modify without specialized tools, 15 or a significant background in electronics. Power optimization techniques are used to extend the life of this 16 module-based design to >1 year on standard AA batteries. Robust underwater housings are built for these 17 loggers using common PVC fittings. The flexibility of this prototyping system is illustrated with two field studies 18 recording drip rates in a cave, and water flow in a flooded cave system. 19 20 Keywords: data logger; environmental monitoring network; open source; submersible; under-water; critical 21 zone observatory; cave; Yucatan Peninsula, vadose hydrology; subterranean karst estuary.
    [Show full text]
  • Secure Can Logging and Data Analysis
    THESIS SECURE CAN LOGGING AND DATA ANALYSIS Submitted by Duy Van Department of Systems Engineering In partial fulfillment of the requirements For the Degree of Master of Science Colorado State University Fort Collins, Colorado Fall 2020 Master’s Committee: Advisor: Jeremy Daily Steve Simske Christo Papadopoulos Stephen Hayne Copyright by Duy Van 2020 All Rights Reserved ABSTRACT SECURE CAN LOGGING AND DATA ANALYSIS Controller Area Network (CAN) communications are an essential element of modern vehicles, particularly heavy trucks. However, CAN protocols are vulnerable from a cybersecurity perspective in that they have no mechanism for authentication or authorization. Attacks on vehicle CAN systems present a risk to driver privacy and possibly driver safety. Therefore, developing new tools and techniques to detect cybersecurity threats within CAN networks is a critical research topic. A key component of this research is compiling a large database of representative CAN data from operational vehicles on the road. This database will be used to develop methods for detecting intrusions or other potential threats. In this paper, an open source CAN logger was developed that used hardware and software following the industry security standards to securely log and transmit heavy vehicle CAN data. A hardware prototype demonstrated the ability to encrypt data at over 6 Megabits per second (Mbps) and successfully log all data at 100% bus load on a 1 Mbps baud CAN network in a laboratory setting. An AES- 128 Cipher Block Chaining (CBC) encryption mode was chosen. A Hardware Security Module (HSM) was used to generate and securely store asymmetric key pairs for cryptographic communication with a third-party cloud database.
    [Show full text]
  • Test & Measurement
    TEST & MEASUREMENT PRODUCT CATALOG Established in 1991, Pico Technology is a worldwide leader Foreword in the field of PC-based test equipment and data acquisition. By Alan Tong, Founder and Managing Director, Pico Technology Our products regularly win industry awards, with our past achievements including: When I started designing and building Pico oscilloscopes over 25 years ago, I could not have imagined how technology within the electronics industry would develop. Today I am proud that Pico is the market leader in PC-based oscilloscopes. We work closely with our ever-growing customer base. Whether we are continuously developing the product range at our headquarters near Cambridge, UK, in our USA office in Texas, or with our RF design team in Vilnius, Lithuania, we are committed to meeting customers’ needs through advances in technology. For example, PicoScope is now touchscreen compatible and works not only with Windows, but with Mac and Linux too. Our high-end features, SDK and excellent support mean that PicoScope is being embedded into more systems than ever before. We offer all of our customers unbeatable technical support, with It’s this heritage and innovation that allows us to create products for the electronics industry that continually our team of experts on call to answer your query or to advise grow in capability and have become well loved. We hope you find what you need within this catalog, as we you on the best product to suit your need. Our stringent quality show you our product range and demonstrate the ease of use and simplicity of our PicoScope 6 software.
    [Show full text]