Cite

Introduction

Interactive electronic technical manual (IETM) is a digital technical manual made according to the standard digital format and in the form of text, graphics, tables, audio and video [1], which provides fault diagnosis, maintenance and other functions for weapon equipment or civil equipment through human-computer interaction [2]. Fault diagnosis IETM is an integrated IETM system focusing on the field of equipment fault diagnosis. The most basic work of IETM is to process technical data. How to manage a large amount of data information? How to use the stored information for fault diagnosis? How to use information to complete the interaction with users? The effective solution of these problems is the key to develop fault diagnosis IETM. In the common technical framework of IETM shown in Figure 1, XML and its related technologies account for a large proportion. It can be seen that XML technology plays a very important role in IETM development. This paper takes the above three problems as the background and according to the international standard S1000D standard as the IETM standard to describe the application of XML in fault diagnosis IETM, including using XML to create fault information data module, displaying control equipment fault information and using XML to build IETM database. It systematically expounds the relationship between XML Technology and fault diagnosis IETM, so as to provide solutions and ideas for the above problems.

Figure 1.

Technical framework commonly used by IETM

Summary of XML and Its Related Technologies
Summary of XML Technology

Extensible markup language (XML) [3,4,5] is a meta markup language. It is an effective tool designed to transmit and store data depending on some rules and applications. It is flexible, simple and easy to expand. Users can use any tag to define XML instance document [6]. An XML instance document contains elements and attributes. The document body has three parts: preface, body and end, which are respectively composed of multiple element nodes. Each element node has its own attributes and can expand child nodes. The writing of XML document is essentially to organize each element node reasonably. XML integrates data reuse, data display separation, scalability, syntax freedom and structured integrated data. It has unique advantages in data storage and management, powerful super connection, cross platform, cross network, cross program language data description, efficient organization of a large amount of data and so on. Of course, XML also has some disadvantages. For example, it allows users to develop tags with different rules according to needs. Although it makes the search easier and flexible, it also increases the complexity of documents, and the same data will occupy more space than stored in other style databases [7]. Therefore, when applying XML to IETM, we should take comprehensive consideration and reasonably define tags.

Overview of XML constraint rules

XML documents need to follow several basic rules when editing, including having and only one root element node; If each element node has a start tag, it must have an end tag; Each element node should be reasonably contained in the parent element and cannot be cross referenced; In order to make the creation of an element meaningful, the attribute of an element cannot be empty. In addition to the basic rules that need to be followed, when creating XML documents, appropriate schemas should be selected to describe and restrict their document structure. For this purpose, XML provides two schemas: document type definition (DTD) and XML schema. DTD [8] is a set of syntax rules about markers. It defines the logical structure of the document and specifies the elements, entities, attributes of elements and the relationship between elements and entities used in the document. XML schema [9] is the successor of DTD. It improves the shortcomings of DTD, such as non-extensibility, non-compliance with XML syntax, non-support for namespace applications, support for a few simple data types, etc. XML schema is the standard schema recommended by W3C at present, and is gradually becoming the mainstream schema of XML description and binding document structure. The analysis and comparison of the two are shown in Table I. Through the analysis and comparison of the two, XML schema itself provides a more standardized and complete mechanism to restrict an XML file than DTD, which has obvious advantages. Therefore, in the description process, this paper selects XML scheme schema to describe and restrict the XML document structure.

Table type styles

Technical model Main advantages and disadvantages
DTD DTD comes from and is a subset of SGML. It is the standard before schema and an important part of XML1.0. Its definition is a specific application domain. It is mainly used for validation and good form verification. The main advantage of DTD is that it can quickly determine whether a document is valid by using a parser to match regular expressions and data patterns in the document. Its main disadvantages are that it uses non-XML syntax, requires special processing tools, and does not support various data types and spatial mechanisms. DTD cannot introduce other DTDs, and its scalability is poor.
XML Schema XML Schema is the standard recommended by W3C at present. It introduces data type and namespace, supports internal reference of schema, has good expansibility, can be converted between different schemas through mapping, and has good data interchangeability. For this trend, this schema will replace DTD and be used to define rules for XML documents in all types of network applications. Its main advantage is that the schema itself is an XML document with good data scalability, consistency and accuracy. From the user's point of view, it has better simplicity, legibility and ease of use, better support for data exchange and stronger data binding. The main disadvantage of is that the schema cannot define entities like DTD, and it is more complicated than DTD.
XML DOM overview

XML DOM, fully known as XML document object model, is a standard model for XML documents. It defines the standards and methods of accessing and operating XML documents. XML DOM regards the whole XML document as a node tree, in which each component is defined as a node that can be accessed and processed. In the XML DOM node tree shown in Figure 2, each node is independent and related to each other.

Figure 2.

XML DOM tree example

Figure 3.

Eight types of DM commonly used in S1000D standard

For example, when the user accesses the XML element and the attributes of any node in the XML document, the user can access the XML element or delete the attributes of any node through JavaScript. XML DOM is a powerful tool for users to operate XML documents. It can not only arbitrarily control the content of the whole XML document, which brings great flexibility to the development of fault diagnosis IETM, but also plays an important role in the integration and transformation between relational database and XML [10].

XML is Applied to the Creation of Data Module
Data Module

IETM includes various technical information such as equipment function, performance, operation principle, program, operation, maintenance, detection, inspection, fault report and exception handling, disassembly procedure, assembly... Which need to be stored [10], and then display pictures, words and other information on the electronic screen for users to consult and browse [11]. S1000D standard stipulates that technical information is organized by data module (DM), which is the smallest information unit in IETM technical data. S1000D standard defines 13 types of DM, as shown in figure 3, among which 8 types of DM are commonly used.

What may be needed in fault diagnosis IETM include description information data module, maintenance step information module, fault information data module, maintenance plan data module, etc. The data module consists of two parts: Identification and status segment(IDSTATUS) and Content segment(CONTENT). The Identification and status part is used to identify and control the data module, which is mainly used to identify and locate the data module. This part is invisible to the user. The data module code (DMC) and the version number of the data module constitute the unique identification of the data module, which is used to manage the data module in CSDB. The content part describes most of the information that users can view in the data module. This paper mainly takes the creation of fault information data module as an example to describe the role of XML in the creation of data module.

Fault information data module

The fault information data module is an information collection that gives specific fault finding and troubleshooting methods according to different fault causes during the design and use of the equipment. It is used to describe the phenomenon, cause, relevant information of fault parts, brief solutions or detailed fault isolation procedures. It is the main basis for the fault diagnosis IETM system to realize the fault diagnosis function. The fault information data module is divided into three parts: reference information, fault report information and fault isolation procedure. Among them, the fault report describes the fault content, fault isolation describes the troubleshooting of the fault, and the reference information is used to quote other technical data. The constituent elements of each part of the fault information data module are shown in Figure 4.

Figure 4.

Structure diagram of fault information data module

Creating fault information data module with XML

In order to meet the principle of “Edit once, reuse” and avoid the uncertainty of user-defined labels, when creating the fault information data module, XML stipulates that there are specific element labels to describe the information of each part of the module, in which the fault report is divided into the following four categories: isolated faults described by element <ifault>; Detected faults described by element <dfault>; Observed faults described by element <ofault>; Associated faults described with element <cfault>. Fault isolation information describes the fault information and gives the basic steps of fault isolation, which is described by element <afi>. Fault isolation information includes various information elements describing fault isolation diagnosis. This part is the focus of studying equipment fault information model and the inevitable factor to improve the success rate of fault reasoning task [12]. The final generated data module is a complete XML file. Figure 5 shows the breakdown.xml of fault information data module document fragment.

Figure 5.

Code snippets for XML documents

When creating the fault information data module, this paper selects the XML scheme mode for breakdown Generate file breakdown.xsd, Figure 6 is the description form of fault information data module in schema mode.

Figure 6.

Schema mode of fault information DM

When using, you need to add a pattern reference to the header of the generated fault information data module:

<xmlns:xsi="http://www.w3.org/2001/XMLSchemainstance"xsi:schemaLocation="http://www.w3schools.com breakdown.xsd">

Because XML schema itself is an XML document, and the basic syntax rules of defining document structure through XML are consistent, the created data module can be shared and used in multiple IETM systems.

XML Display Control Fault Information

The display control of fault information in XML mainly includes two parts. One part is the storage and query of fault information, that is, the information is classified and written into the XML document by using the tag, so that the fault information has certain structural relationships such as inclusion, connection and dependence through the element tag. At this time, the XML document will be modeled as an annotated diagram, which is actually a tree sequence, and each tree represents a document or element [13]. When making IETM system, data module code, information control code, information type and metadata information are written and stored in XML. For example, the creation of fault information data module is the process of information storage; Query is to find out the fault information that meets the needs of users in the data module, that is, the XML file set, according to the relevant fault query conditions submitted by users. Due to the increasing popularity of XML for data representation, people query XML mainly through keyword query [14], which needs to access the structural tags in XML to obtain the content. The other part is to provide technical support for the interactive fault diagnosis process by describing the fault reasoning process in the data module, and realize the information interaction by controlling the label of XML. In the whole process of XML display and control of fault information, it also involves the transformation with database.

XML display style

Because XML documents can customize labels, have no information to display data, and separate data from display styles, corresponding technologies are needed to display information to users. XML can be displayed using Cascading style sheet (CSS), Extensible style sheet language transformations (XSLT) and scripting language JavaScript. For the breakdown.xml in Chapter 2 uses three methods as follows.

1) Using CSS style sheets: Cascading style sheet (CSS) is a computer language used to represent file styles such as HTML or XML. It can not only modify the web page statically, but also format the elements of the web page dynamically with various scripting languages. There are two ways to use CSS to control the display format of XML. One is to directly use CSS style by embedding <html: style> in the XML document. You must first define the namespace of HTML like “http://www.w3.org/TR/REC-html40” before you can use the tags in HTML The syntax is shown in Figure 7.

Figure 7.

XML document embedded CSS example

The second is to break down the tags in the XML file CSS file. Some code examples of CSS file are as follows:

ifault {background-color: #ffffff;width: 100%;}

Then link the CSS file to the XML file, so that the tags in the XML document can display with breakdown.css file.

<?xml-stylesheet type="text/css" href="breakdown.css"?>

Compared with the first method, this method is more flexible and convenient. It can not only apply CSS files to multiple XML documents, but also write the label styles of multiple XML documents in one CSS file to realize one-time generation and reuse.

2) Using XSLT style sheets: XSLT is a language used to transform one XML document into another XML document or other types of documents. The principle is to convert the XML file into a document that can be recognized by the browser, such as HTML, before the browser displays it. When using it, you need to generate breakdown.xsl file, The code fragment is shown in Figure 8.

Figure 8.

Code snippets for XSLT documents

And through the breakdown.xml add The following code:

<?xml-stylesheet type="text/xsl" href="breakdown.xsl"?>

reference XSLT style sheets to XML documents to work. Through breakdown.xsl file, you can choose to add elements and attributes to the output file, remove elements and attributes, rearrange and classify elements, test and hide or show which elements.

3) Use JavaScript to dynamically display: This method mainly uses the XMLHttpRequest object to parse the XML document into the XML DOM object, and then operate the DOM object through JavaScript to obtain the information in the XML document and display it. The specific method is to define a new XMLHttpRequest object through the xmlhttp = new xmlhttprequest() operation. When the system adopts the server centered B / S structure, the XMLHttpRequest object can be used to exchange data with the server in the background, and then send a request to the server using the open() and send() methods of the XMLHttpRequest object. The method is xmlhttp.open("GET","breakdown.xml",false);xmlhttp.send(); "breakdown.xml" in the open () method is the address of the XML document on the server, and finally xmldoc = xmlhttp.responseXML; Use the responsexml attribute to return the XML document object. At this time, you can use JavaScript to manipulate the methods and attributes of the DOM node tree to check and parse the object. For example, x = xmldoc getElementsByTagName("ifault"); Locate the tag name in the XML document through the getElementsByTagName () method to obtain the content in the tag.

In the above three methods, general XSLT is the preferred XML style sheet language, and its display control flow is shown in Figure 9. During display, the required data module and its corresponding XSLT style are sent to the reader for display, and the XSLT style written in a certain mode has certain universality and can be reused.

Figure 9.

XML display control process

XML oriented interactive fault reasoning mechanism

The interactive fault reasoning mechanism can adjust the user's fault symptom input as the premise part of the diagnosis rules, and then match the knowledge base. If the matching is successful, the action part of the rules will be executed until the diagnosis conclusion is reached or the rule base is exhausted. Or write the internal logical relationship of the question into the XML document, analyze, reason and judge the user's answer to the previous question to put forward the next question, and get the final diagnosis conclusion in this cycle. In the above two mechanisms, the diagnostic rules, knowledge base information and problems involved in reasoning can be described in the form of XML and displayed in the style in Chapter 3.1 when necessary.

Relationship between XML and database

There is a core concept in S1000D standard - common source database (CSDB). As a container for storing information and management information in IETM system, CSDB stores all the information required by the technical manual, including data modules. The data modules mentioned above are composed of XML documents, so that XML documents can be accessed through the database. At the same time, pictures, videos, audio and other data are also stored in the database, and the information in the database can be referenced in the XML document, Therefore, it is very important to select an appropriate mapping model from XML to database [1516] to realize the mutual transformation between XML documents and database data. Using table mode, there are two main forms of conversion between XML document and database.

1) The transformation from XML document to database: parses the label in XML document into the form of table and inserts it into the database. Starting from the root node in XML document, take the label information as the attribute in the table until the last label in XML document is traversed. The attribute field definition of each tag in the database is shown in the table II. To take the <breakdown> tag in the breakdown.xml document as an example. The XML document number starts from 1 and the tag number starts from 1. Then the fields in the <breakdown> tag corresponding table have XmlID = 1, LableID = 1, LabelName = "breakdown". At the same time, two tag types are defined in XML, one is the element tag element and the other is the attribute tag attribute. Here, breakdown is the element tag, so LabelType = "element". The tag does not contain text information, and LabelVal = null. Because < breakdown > is the root node, there are no parent tags, but only child tags, so LabelParent = 0 and LabelChild = 1. By analogy, in this way, the label data in the XML document is mapped to the data in the database for storage, and the information in the XML document can be obtained by accessing the table from the database.

Label attribute field definition

Attribute field Data type Field description
XmlID Integer XML document ID of the tag
LabelID Integer ID of the tag
LabelName Varchar(30) The name of the label
LabelType Varchar(30) Type of label
LabelVal Varchar(255) Text information in label
LabelParent Integer The ID of the label's parent label
LabelChild Integer The ID of the child tag of this tag

2) The mapping from database information to XML document: That can create an XML document for each table in the database, take the table name as the root node of the XML document, generate the sub elements under the root node with the information in the table in behavioral units, and a row of information is a sub element node, and then associate the fields in each row of information as the sub elements or attributes of the sub nodes, and the attributes of the fields as the attributes of the sub element labels. When XML schema is used to constrain the structure of XML document, it shall be consistent with the field type defined in the database. For example, if the data type of field x defined in the database table is integer, only numbers shall be used for the text of label <x> in XML document. In this way, a label node is generated in the XML document until the last field of the last row of information in the table.

Evelopment Process and Application Implementation of IETM for Fault Diagnosis Based on XML

XML can store data according to needs, transmit content in an interactive way, and provide the interface between data and external elements to operate data. It realizes the efficient storage and sharing of information between different systems and reduces the development cost. Therefore, XML is the best choice for developing fault diagnosis IETM[17]. Taking the IETM in XML format generated from traditional paper documents as an example, from data storage to display to users, and then to fault diagnosis in an interactive way, the design flow of XML based fault diagnosis IETM is shown in Figure 10.

Figure 10.

Design flow of fault diagnosis IETM based on XML

Firstly, the fault information is analyzed from data storage to display, and it is allocated to the corresponding data module through XML editor according to the modular design idea. Then, the structure of each data module is described and constrained based on XML schema; Then, the XML document is stored in the database according to certain conversion rules; Finally, the display style sheet of XML document is written, and the data is retrieved and output to the browser according to the needs of users by converting it into HTML document. Figure 11 is an interactive fault diagnosis interface for users. In this interface, users can not only consult the displayed fault information for diagnosis, but also input fault information, complete the diagnosis by using the fault reasoning mechanism and diagnosis rules stored in the data module, and obtain the diagnosis results and relevant information through the above displayed process. The specific implementation methods of each part have been described in the previous chapters of this paper, and will not be described here.

Figure 11.

Fault diagnosis interface

Conclusion

XML technology provides an effective means for efficient storage, integration and sharing of data in fault diagnosis IETM. From the creation of fault information data module, to the management and display of fault information, to the association with database, XML covers almost every stage of IETM development. This paper systematically analyzes the application of XML technology in fault diagnosis IETM, and expounds the technologies involved in each application process in detail. By integrating these technologies, the preliminary display system of IETM for fault diagnosis is realized. The research shows the key role of XML technology in IETM development, which provides ideas for developing IETM based on XML in the new situation, and is of great significance to system development in the field of equipment maintenance and support and equipment fault diagnosis. At present, the research on XML technology and the implementation of the system are still in the initial stage, and the follow-up work should consider the combination with other advanced technologies to further explore the deeper application of XML technology in fault diagnosis IETM.

eISSN:
2470-8038
Language:
English
Publication timeframe:
4 times per year
Journal Subjects:
Computer Sciences, other