Domain Analysis Methods for MCU Embedded Systems

Publisher:JoyfulSerenadeLatest update time:2015-04-15 Source: eechinaKeywords:MCU Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere
1 Introduction

MCU (Micro Controller Unit), also known as single chip microcomputer, refers to a chip-level computer that integrates the computer's CPU, RAM, ROM, timer and multiple I/O interfaces on a single chip with the emergence and development of large-scale integrated circuits. At present, each MCU embedded system is developed in a closed manner, and there is a lot of duplication between different systems, which greatly increases the cost and cycle of software development. At the same time, the reliability of the system cannot be guaranteed. MCU embedded development faces the problems of rapid expansion of software scale and complexity, tight development time, and ensuring development quality. Therefore, new embedded software development technology is urgently needed. In

1968, Mellroy first proposed the idea of ​​software reuse in his paper "Mass Production of Software Components", which aims to explore the process of producing software using "software components designed for reuse purposes", which has attracted great attention. Among various software reuse methods, component-based software development technology (CBSD) is also a hot topic of research, and has also achieved good results in practice.

The componentized software process can be divided into two independent sub-processes: domain engineering (developing components) and application process (developing applications using components). Domain engineering is the main technical means for producing reusable software assets. It includes three stages: domain analysis, domain design, and domain implementation. In the entire software reuse process, domain analysis is the key. Only through domain analysis can reusable assets (domain models, software architecture, reusable components, etc.) in similar systems be obtained to further support the reuse of new system development in the domain. Therefore, it is extremely important to form an effective domain analysis method in MCU embedded systems.

2 MCU embedded system development model and current status

2. 1 MCU embedded system development model

At present, the software process of MCU embedded systems is basically centered on the main process including human-machine interface processing (slow processing), external asynchronous interrupt processing (urgent processing), and timing input, plus various other control components such as movement control processing (processing according to certain rules). Every time the MCU completes a function, its processing process follows the IPO model (Input, Process, Output), as shown in Figure 1.

1.gif 
Figure 1 IPO Status

For each model, its input parameters and output results are in fixed formats, so for a mature model, its behavior is determined and its constraints are clear. Because of these characteristics, the cohesion and stability of the MCU embedded system field can be clearly observed.

Because of the cohesion of the field, we can use relatively few and limited reusable information to reflect the needs and applications of the entire field. Because of the stability of the field, the results we obtain through field engineering can compensate for the manpower and material resources spent on field engineering in future work.

2.2 Status of MCU Embedded System Development

The application of MCU can penetrate into all aspects of human life. The key reason is that it can achieve different functions and target different applications through flexible customization of software. With the increasing number of functions, the difficulty of MCU embedded system development has also increased. If the built-in ROM capacity is within 8K bytes, an experienced technician can spend 2-3 months alone to develop software in assembly language, but it will be more difficult to complete the ROM of more than 16K alone. Especially in the field of consumer electronics, product replacement has changed from years to months or even weeks, which has led to the frequent recall of products due to quality problems in enterprises that rely on product quality. It is worth noting that in development, experienced developers usually selectively reuse previous work results (code, software system, tools, documents), but this reuse is generally personal, and the source of reuse is also the previous experience of individuals. In a specific field, such as an enterprise, such reuse is frequent, and they have the following characteristics:

· There are many reusable resources and opportunities for reuse in a field, but it is usually impossible to manage reusable resources, decide when to reuse and how to reuse, and thus effectively control the quality of products.

· In a field, individuals often control certain reusable resources, and reusable resources cannot be shared, resulting in waste of resources and failure to further improve productivity.

· The departure of individuals who control resources leads to resource loss; new individuals cannot systematically obtain these resources, resulting in reduced work efficiency.

This type of reuse is called ad-hoc reuse. If the resources in the domain can be effectively integrated and managed and reused in a more effective way, the production efficiency of software products can be further improved, production costs can be reduced, and product quality can be improved. This method is called systematic reuse. Domain engineering is proposing solutions to this series of problems.

3 Domain Engineering and Domain Analysis

3.1 The meaning of domain A domain

refers to the functions, problems, problem solutions or knowledge areas covered by a group of application systems with similar or similar software requirements. Domains can be divided into horizontal domains and vertical domains: horizontal domains refer to similar problem spaces obtained by functional classification of modules within the application system, such as database systems, workflow systems, etc.; vertical domains refer to business areas covered by a group of similar application systems with similar business requirements, and our MCU embedded system domain belongs to the vertical domain.

3.2 Domain Engineering

Domain engineering is the process of establishing basic capabilities and necessary foundations for the application engineering of a group of similar or similar systems. It covers all activities to establish reusable software components. Domain engineering analyzes the systems in the domain, identifies the common features and variable features of these applications, selects and abstracts the objects and operations that characterize these features, forms a domain model, and generates the architecture common to the applications in the domain based on the domain model, namely the domain-specific software architecture (DSSA), and on this basis, identifies, develops and organizes reusable components. [page]

In the activities of domain engineering, a series of standards can be formed by systematically cross-comparing domain-related knowledge. These standards form regulations for the selection of components and the generation of new components, thereby guiding and regulating the development of new products. At the same time, since these choices have been demonstrated over a long period of time and practice, these standards are also scientific. When we want to develop a new system in the same domain, we only need to determine the new requirements based on the domain model, and then form a new system design based on the software architecture of the specific domain, and select, construct components based on relevant standards, and assemble them into the new system. In this way, the quality and development efficiency of the new system will be reliably guaranteed, and the company can also manage and monitor the entire development process through behavioral norms.

3.3 The meaning and method of domain analysis

In systematic software reuse, the existence of sufficient reusable information is very important. This information needs to be explicitly represented so that it can be reused during the development process. This reusable information, together with some auxiliary information for convenient location and operation, constitutes the reuse infrastructure. The purpose of domain analysis is to establish this reusable infrastructure, which means "the process of identifying, capturing and organizing reusable information such as objects and operations in a class of similar systems in a specific domain". The

three key processes of domain analysis are: ① Establishment of domain boundaries: By analyzing existing technical materials and typical systems, and integrating the opinions of domain experts, define the scope and boundaries of domain analysis, and collect necessary information for conducting domain analysis; ② Domain modeling stage: Based on the domain boundaries obtained in the domain boundary establishment stage and the relevant information collected in the domain, use the corresponding modeling knowledge and tools to establish a domain model with the commonality and variability characteristics of the data and capabilities of the application systems in the domain; ③ Software architecture modeling stage: Establish a software architecture model (DSSA) that describes solutions to specific problems in the domain through the domain model that has been obtained and the relevant standards designed in the domain.

4 MCU Embedded System Domain Analysis Method

4.1 Determination of Domain Boundary of MCU Embedded System Domain

Here, we do not intend to choose a domain that is suitable for all MCU system development, but a relatively narrow domain, such as the air conditioning industry in the home appliance manufacturing industry. In such an industry, since the basic functions of the product to be implemented are basically fixed for a long time, the needs of customers are relatively stable, so that in the domains for similar products, there are many functions that are the same and the software architecture is the same. This provides very favorable conditions for domain analysis. When analyzing these domains, the data mainly comes from typical systems in this field, the advice of domain experts, the experience of engineers, customer needs, development kits provided by hardware manufacturers, control theory, the development history and development trends of this field, etc. After collecting these resources, it will form the context of domain analysis, that is, the boundary of the domain.

4.2 Domain Modeling of MCU Embedded System Domain

The significance of the domain model is to organize the information of the domain in a more acceptable way. It includes formal models and informal information. The former is a description of the solution, and the latter is a supplement to the domain knowledge. For the domain we have chosen, the software architecture of a specific industry is relatively stable. For each specific product, there will be some minor differences in the functions implemented. It is common that after a prototype appears, many modifications will be made to the prototype to meet the different needs of market customers. Therefore, in view of such domain characteristics, we have the following suggestions for the process at this stage:

· Formal model: adopt a feature-oriented domain model. The definition of a feature is generally a system feature that can be perceived by users or customers. However, each organization can also organize and select a domain model based on its own characteristics.

· Domain dictionary: The domain dictionary is obtained through dialogue with domain experts and analysis of relevant standards. The role of the domain dictionary is to provide an accurate and convenient communication environment for participants in the field.

· Unified identification: Use a standardized, universal symbol system to describe concepts in the domain.

4.3 Software Architecture in the MCU Embedded System Domain

DSSA (Domain-Specific Software Architecture) is not a representation of a single system, but a high-level design that can adapt to the needs of multiple systems in the domain. It contains components and rules for component interconnection. When developing a new system in this field, these components can be used, and according to these rules, a specific system structure that meets the current system requirements can be constructed8. A relatively important concept in DSSA is the reference architecture, which aims to achieve architecture reuse. Figure 2 shows a reference architecture (partial) in the field of air-conditioning controllers.

2.gif 
Figure 2 Reference architecture in the field of air conditioning controllers (partial)

In the figure above, each box represents a component. Its subordinates represent sub-components derived from the decomposition of the previous component. Multiple sub-components can form a larger component, which can support more efficient reuse.

DSSA also includes some requirements specifications, as well as descriptions and standards for interfaces. For the MCU embedded system field, since there are industry standards for the interfaces of many peripherals, how to make the software that controls these hardware also be written according to a unified industry standard is a necessary and feasible solution. Software written according to the standard can be easily extracted into components and used in our system. In practice, we found that it is feasible to agree on this standard from the following aspects:

· Scope of application of software: such as MCU type, application scheme, etc.;

· Hardware characteristics and usage of peripherals;

· Standardization of peripheral control process: including algorithms and flow charts;

· Standardization of interface parameters: naming rules, types, lengths, etc.;

· Some relevant precautions: such as some restrictions made to comply with national regulations, relevant security requirements;

5 Summary

Innovation of this article: The author introduces the concept and method of domain analysis, and introduces a domain analysis method suitable for the field of MCU embedded systems based on the characteristics of the field of MCU embedded systems. This method has been applied to the author's current project. Practice has proved that this is a feasible path with great potential. How to combine more means to achieve our goals will be the focus of future work.
Keywords:MCU Reference address:Domain Analysis Methods for MCU Embedded Systems

Previous article:Design and application of SED1335 in single chip microcomputer system
Next article:Design of Freescale+HC08+MCU Integrated Development Environment

Recommended ReadingLatest update time:2024-11-16 22:37

STM8 MCU software determines the reset source
Let me tell you about the port remapping of STM32 microcontroller. Here we take the remapping of USART1 as an example. There are many I/O ports on STM32, and there are also many built-in peripherals such as I2C, ADC, ISP, USART, etc. In order to save lead pins, these built-in peripherals basically share pins with I/
[Microcontroller]
Detailed explanation of idata, xdata, pdata, and data of 51 MCU
data: fixedly refers to the first 128 RAM from 0x00 to 0x7f, which can be directly read and written with acc, with the fastest speed and the smallest generated code. bit: refers to the bit addressable area from 0x20 to 0x2f idata: fixedly refers to the first 256 RAM from 0x00 to 0xff, of which the first 128
[Microcontroller]
51 MCU Tutorial from Scratch - 16 MCU Bit Operation Instructions
In the previous routines of running lights, we are used to "bits". One bit is the on and off of a light, but the instructions we learned are all introduced with "bytes": byte movement, addition, subtraction, logical operations, shifting, etc. Using bytes to handle some mathematical problems, such as controlling the tem
[Microcontroller]
AVR MCU timer 0 compare match function test TIME0_CTC
/*Don't talk nonsense*/ /*Test the compare match function of AVR timer 0*/ #include iom16v.h #define uchar unsigned char #define uint unsigned int #define set_bit(a,b) a|=(1 b) #define clr_bit(a,b) a&=(1 b) #define get_bit(a,b) a&(1 b) #pragma interrupt_handler time0ctc_isr:20 void time0ctc_isr()//Timer counter 0 c
[Microcontroller]
The principle of I2C bus digital potentiometer and its interface design with single chip microcomputer
1 Introduction  ; ; ; With the increasing application of I2C bus, there are more and more types of interface chips and memories compatible with I2C bus. Among them, digital potentiometers have been recognized by a large number of electronic engineering technicians for their convenient adjustment, long service life, li
[Microcontroller]
The principle of I2C bus digital potentiometer and its interface design with single chip microcomputer
Application of Serial Data Acquisition Method in Single Chip Microcomputer Voltage Meter
Among the commonly used A/D conversion chips (such as ADC0809, ICL7135, ICL7109, etc.), ICL7135 is different from the others. It is a four-and-a-half-bit dual-integral A/D converter with high precision (equivalent to 14-bit binary), low price, strong anti-interference ability, etc. Usually, designers use single-chip
[Microcontroller]
Electronic table C51 program made by STC single chip microcomputer
The circuit is very simple so I won't draw it. It is made of STC series microcontroller. The display part is two 74hc573 chips connected to P1 port, and then use P3.0 to control the segment selection. The key definition program has instructions. It is very easy to build. The following picture is the effect picture.
[Microcontroller]
Electronic table C51 program made by STC single chip microcomputer
Transplantation and Development of μCOS-II on ATmega128 MCU
Introduction This article introduces the process of porting μC/OS-Ⅱ to ATMEL's 8-bit microcontroller ATmega128. The so-called porting is to make a real-time kernel run on a certain microprocessor, and develop drivers on this basis to make it a practical embedded system. Embedded systems include hardware and so
[Microcontroller]
Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号