Method and system for implementing driving on SPI equipment under VxWorks operating system

A technology of vxworks, operating system, applied in the direction of program control devices, etc., can solve problems such as unfavorable code maintenance, serious code coupling between application layer and driver layer, etc., to improve system performance and accuracy, improve stability, and reduce the degree of coupling. Effect

A technology of vxworks, operating system, applied in the direction of program control devices, etc., can solve problems such as unfavorable code maintenance, serious code coupling between application layer and driver layer, etc., to improve system performance and accuracy, improve stability, and reduce the degree of coupling. Effect

CN104965700AActive Publication Date: 2015-10-07航天欧华信息技术有限公司

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method and system for implementing driving on SPI equipment under VxWorks operating system
  • Method and system for implementing driving on SPI equipment under VxWorks operating system
  • Method and system for implementing driving on SPI equipment under VxWorks operating system

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0053] In order to make the object, technical solution and advantages of the present invention clearer, the present invention will be further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described here are only used to explain the present invention, not to limit the present invention.

[0054] figure 1 It is a structural framework diagram for driving SPI devices under the VxWorks operating system. The VxWorks operating system includes the application layer, the kernel layer and the SPI device driver layer. The application layer includes the user's application software and application programs. The kernel layer includes the I / O subsystem, and the I / O subsystem is provided with a system driver table, a system device table and a system file descriptor table. In order to improve the efficiency of data transmission, the kernel layer is also provided with a sending buffer and a receiv...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The present invention relates to a method and system for implementing driving on SPI equipment under a VxWorks operating system. The VxWorks operating system comprises an application layer, a kernel layer and an SPI equipment driving layer. The method adopted by the VxWorks operating system comprises: acquiring custom SPI equipment component description file and SPI driver registry function prototype from the SPI equipment driving layer; according to the custom SPI equipment component description file and SPI driver registry function prototype, forming a compiling rule for an SPI driver; according to the compiling rule, carrying out register on the SPI driver on the kernel layer and initializing the SPI driver, wherein the step of initializing the SPI driver comprises the substeps of setting SPI driver interruption and operations corresponding to the SPI driver interruption and setting a sending cache region and a receiving cache region on the kernel layer; enabling the SPI equipment driving layer to carry out data interaction with the sending cache region and the receiving cache region of the kernel layer by SPI driver interruption; and enabling the kernel layer to carry out data interaction with the application layer by an application interface. According to the method and system for implementing driving on the SPI equipment under the VxWorks operating system, the coupling degree of codes can be reduced and stability and reliability of the SPI communication are improved.

Description

technical field [0001] The invention relates to the technical field of power distribution automation, in particular to a method and system for driving SPI equipment under the VxWorks operating system. Background technique [0002] Currently, the Wind River WorkBench 3.3 development platform provided by Wind River in the United States does not provide a standard SPI (Serial Peripheral Interface, Serial Peripheral Interface) driver development model. Driver development engineers under the VxWorks operating system in the industry mainly use the SPI of the single-chip microcomputer. Driver development model and traditional I / O device driver model development model to develop SPI device drivers. [0003] (1) SPI driver development model for MCU [0004] The SPI driver development model of the MCU is a custom driver development model. During the driver development process, the following tasks need to be completed: write the establishment of the cache, initialize, add data, and ge...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
07 Oct 2015
Publication
CN104965700A
IPC
G06F9/44
Inventors
丁明伟