CN107943259A - Power-off reset method and apparatus based on VxWorks system - Google Patents

Power-off reset method and apparatus based on VxWorks system Download PDF

Info

Publication number
CN107943259A
CN107943259A CN201610892762.6A CN201610892762A CN107943259A CN 107943259 A CN107943259 A CN 107943259A CN 201610892762 A CN201610892762 A CN 201610892762A CN 107943259 A CN107943259 A CN 107943259A
Authority
CN
China
Prior art keywords
cpu
power down
operating system
reset
hardware circuit
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201610892762.6A
Other languages
Chinese (zh)
Other versions
CN107943259B (en
Inventor
赵建立
和艳丽
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Putian Information Technology Co Ltd
Original Assignee
Putian Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Putian Information Technology Co Ltd filed Critical Putian Information Technology Co Ltd
Priority to CN201610892762.6A priority Critical patent/CN107943259B/en
Publication of CN107943259A publication Critical patent/CN107943259A/en
Application granted granted Critical
Publication of CN107943259B publication Critical patent/CN107943259B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/24Resetting means

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Retry When Errors Occur (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The present invention relates to a kind of power-off reset method and apparatus based on VxWorks system, this method includes:In the program exception of operating system, by all hardware circuit power down of CPU minimum systems in the operating system;If the hardware circuit power down time reaches preset time period, all hardware circuit of power down is powered on, the sequential of all hardware circuits of the CPU for making to reset in CPU minimum systems with resetting is consistent.The above method can ensure that all the chip reset sequential and electrification reset sequential of CPU minimum systems are consistent, and realize the normal startup of vxworks operating system.

Description

Power-off reset method and apparatus based on VxWorks system
Technical field
The present invention relates to the communication technology, more particularly, to a kind of power-off reset method and apparatus based on VxWorks system.
Background technology
Vxworks operating system is a embedded real-time operating system of WindRiver companies design, it is capable of providing Good reliability and remarkable real-time, be widely used in the high-quality precision and sophisticated technologies such as communication, military affairs, Aeronautics and Astronautics and In the high field of requirement of real-time.
In the embedded board of vxworks operating system, some peripheral circuits composition CPU minimum systems of CPU and CPU, Including network interface card, serial ports, memory, FLASH chip etc..
In vxworks operating system, if since the software anomalies such as program fleet, memory overwriting can cause the reset of CPU, This reset is the reboot functions of operating system, and after performing reboot, cpu reset, it is controlled after cpu reset restarting again Peripheral circuit is resetted.
At present, vxworks operating system can only reset CPU sheets due to CPU calling reboot resets caused by program exception Body, then the peripheral circuit connected with CPU, such as network interface card, exchange chip, clock chip, DDR chips etc. cannot reset at the same time, After cpu reset starts, peripheral circuit is resetted again, it is impossible to ensure all chip reset sequential of CPU minimum systems and upper Reply bit timing by cable to be consistent, triggering hardware anomalies sometimes causes system normally to start.
The content of the invention
For disadvantages described above, the present invention provides a kind of power-off reset method and apparatus based on VxWorks system, Neng Goubao All the chip reset sequential and electrification reset sequential of card CPU minimum systems are consistent, and realize vxworks operating system just Often start.
In a first aspect, the power-off reset method provided by the invention based on VxWorks system, including:
In the program exception of operating system, by all hardware circuit power down of CPU minimum systems in the operating system;
If the hardware circuit power down time reaches preset time period, all hardware circuit of power down is powered on, makes CPU The sequential of all hardware circuits of the CPU resetted in minimum system with resetting is consistent.
Alternatively, by the operating system the step of all hardware circuit power down of CPU minimum systems before, the side Method further includes:
To cpu reset.
Alternatively, the CPU minimum systems include:The periphery electricity of CPU and the CPU in the embedded board of operating system Road.
Alternatively, the peripheral circuit of the CPU includes following one or more:
Network interface card, exchange chip, clock chip, DDR chips and FLASH chip.
Alternatively, the preset time period is to determine the time according to needed for the cpu reset.
Alternatively, to cpu reset, including:
The operating system calls reboot functions to carry out cpu reset.
Alternatively, by all hardware circuit power down of CPU minimum systems in the operating system, including:
The all hardware circuit power down of CPU minimum systems in operating system described in reboot function call FUNCA function pairs;
The FUNCA functions call when being articulated to CPU exceptional resets beforehand through system function rebootHoodAdd Hook Function on reboot functions, and with all hardware circuit power down for making CPU minimum systems in the operating system Function.
Alternatively, all hardware circuit of power down is powered on, including:
The all hardware circuit of reboot function call FUNCA function pair power down powers on;
The FUNCA functions call when being articulated to CPU exceptional resets beforehand through system function rebootHoodAdd Hook Function on reboot functions, and powered on all hardware circuit for making CPU minimum systems in the operating system Function.
Second aspect, the present invention provide a kind of power-off reset device based on VxWorks system, including:
Power down module, in the program exception of operating system, by the operating system CPU minimum systems it is all Hardware circuit power down;
Judgment module, for judging whether power down mould hardware circuit power down time in the block reaches preset time period;
Module is powered on, for determining that hardware circuit power down time reaches preset time period in judgment module, then to power down All hardware circuit powers on, and the sequential of all hardware circuits of the CPU for making to reset in CPU minimum systems with resetting is consistent.
The third aspect, the present invention provide a kind of operating system, which includes any of the above-described device.
As shown from the above technical solution, the power-off reset method and apparatus of the invention based on VxWorks system, are operating During the program exception of system, all hardware circuit power down preset time period of CPU minimum systems can be made, and then powered on again, It ensure that the CPU resetted in CPU minimum systems is consistent with all hardware circuit sequence, so as to fulfill vxworks operating system Normal startup.
Brief description of the drawings
By reference to attached drawing can be more clearly understood the present invention characteristic information and advantage, attached drawing be schematically without It is interpreted as carrying out any restrictions to the present invention, in the accompanying drawings:
Fig. 1 is the flow chart for the power-off reset method based on VxWorks system that one embodiment of the invention provides;
Fig. 2 is the structure diagram for the power-off reset device based on VxWorks system that one embodiment of the invention provides.
Embodiment
It is to better understand the objects, features and advantages of the present invention, below in conjunction with the accompanying drawings and specific real Mode is applied the present invention is further described in detail.It should be noted that in the case where there is no conflict, the implementation of the application Feature in example and embodiment can be mutually combined.
Many details are elaborated in the following description to facilitate a thorough understanding of the present invention, still, the present invention may be used also To be implemented using other different from other modes described here, therefore, protection scope of the present invention and from described below Specific embodiment limitation.
The present invention relates to embedded system technology field, is especially a kind of CPU based on VxWorks system multiple in exception During position, operating system calls reboot functions automatically, electric under the whole CPU peripheral circuits including CPU at this time, then again Power on.Ensure the complete power-off reset of CPU minimum systems.
As shown in Figure 1, Fig. 1 shows the power-off reset method based on VxWorks system that one embodiment of the invention provides Flow diagram, the method for the present embodiment includes the steps:
101st, in the program exception of operating system, by all hardware circuit of CPU minimum systems in the operating system Power down.
For example, the CPU minimum systems referred in the step may include:CPU in the embedded board of operating system With the peripheral circuit of the CPU.
In addition, the peripheral circuit of the CPU in the present embodiment may include following one or more:Network interface card, exchange chip, when Clock chip, FLASH chip and DDR chips.
It should be noted that the random procedure that the program exception of aforesaid operations system can be regarded as current operation system is abnormal, The not specific user program for being limited to operate on CPU of the present embodiment is abnormal, is both operated including user program or including vxWorks System program itself.
If the 102, the hardware circuit power down time reaches preset time period, all hardware circuit of power down is powered on, The sequential of all hardware circuits of the CPU for making to reset in CPU minimum systems with resetting is consistent.
Specifically, by the operating system the step of all hardware circuit power down of CPU minimum systems before, the side Method further includes:
To cpu reset.For example, operating system can call reboot function pairs CPU to be resetted.
It should be noted that the preset time period in above-mentioned steps 102 is to determine time according to needed for the cpu reset 's.
In practical applications, it is " all hardware of CPU minimum systems in the operating system is electric in abovementioned steps 101 Road power down ", it may include:
The all hardware circuit power down of CPU minimum systems in operating system described in reboot function call FUNCA function pairs;
FUNCA functions in the step can be tune when being articulated to CPU exceptional resets by system function rebootHoodAdd Hook Function on reboot functions, and having falls all hardware circuit of CPU minimum systems in the operating system The function of electricity.
In addition, " being powered on to all hardware circuit of power down " in abovementioned steps 102, it may include:
The all hardware circuit of reboot function call FUNCA function pair power down powers on;
At this time, FUNCA functions here are tune when being articulated to CPU exceptional resets by system function rebootHoodAdd Hook Function on reboot functions, and with making on all hardware circuit of CPU minimum systems in the operating system The function of electricity.
That is, advance custom function FUNCA in the present embodiment, is completed to CPU minimum systems in this function Power-off reset operation.
For example, system function rebootHoodAdd is mounted to cpu reset function reboot, in rebooHookAdd functions The self-defined FUNCA functions of middle addition, automated execution reboot functions during CPU exceptional resets, due to reboot mounted from The dynamic FUNCA functions called, so reboot calls FUNCA functions automatically when performing, FUNCA functions complete CPU minimum systems Power-off reset.That is, by system function rebootHookAdd functions by self-defined FUNCA function hooks to reboot functions, It is automatic to call FUNCA functions when reboot is performed, so as to complete the power-off reset of CPU minimum systems.
Thus, the above method calls self-defined using rebootHoodAdd to be articulated to the mode of reboot functions FUNCA functions, give CPU minimum system hardware chip power-off resets, and then complete the power-off reset to CPU minimum systems, keep away It is abnormal to exempt from the startup caused by minimum system hardware chip reset timing is inconsistent, ensures that the normal of system starts.
In addition, the embodiment of the present invention also provides a kind of power-off reset device based on VxWorks system, as shown in Fig. 2, should Device further includes:Power down module 21, judgment module 22, power on module 23;
Wherein, power down module 21, in the program exception of operating system, being by CPU minimums in the operating system The all hardware circuit power down of system;For example, call all hardware of CPU minimum systems in operating system described in FUNCA function pairs Circuit power down;
Judgment module 22, for judging whether power down mould hardware circuit power down time in the block reaches preset time period;
Module 23 is powered on, for determining that hardware circuit power down time reaches preset time period in judgment module, then to power down All hardware circuit power on, for example, powering on module 23 all hardware circuit of FUNCA function pair power down can be called to power on;Make The sequential of all hardware circuits of the CPU resetted in CPU minimum systems with resetting is consistent.
Alternatively, in other embodiments, above-mentioned power-off reset device may also include the reseting module not shown in figure, The reseting module can be used for before power down module is to all hardware circuit power down of CPU minimum systems to cpu reset.In reality In, which can call reboot functions to carry out cpu reset.
CPU minimum systems in the present embodiment may include the periphery of the CPU and the CPU in the embedded board of operating system Circuit.
Special instruction, foregoing preset time period is to determine the time according to needed for the cpu reset.
It should be noted that the power-off reset device of the present embodiment can perform the power-off reset described in foregoing any embodiment Method, referring to foregoing description, this will not be detailed here for the present embodiment.
When the above-mentioned power-off reset device based on VxWorks system may be implemented in CPU exceptional resets, it can ensure CPU most Mini system can power-off reset, realize that the sequential of CPU minimum systems is consistent, ensure the normal startup of operating system.
The third aspect, the embodiment of the present invention also provide a kind of operating system, which may include above-mentioned any implementation Device described in example.
In the present invention, term " first ", " second " are only used for description purpose, and it is not intended that instruction or hint are opposite Importance.Term " multiple " refers to two or more, unless otherwise restricted clearly.
Although being described in conjunction with the accompanying embodiments of the present invention, those skilled in the art can not depart from this hair Various modifications and variations are made in the case of bright spirit and scope, such modifications and variations are each fallen within by appended claims Within limited range.

Claims (10)

  1. A kind of 1. power-off reset method based on VxWorks system, it is characterised in that including:
    In the program exception of operating system, by all hardware circuit power down of CPU minimum systems in the operating system;
    If the hardware circuit power down time reaches preset time period, all hardware circuit of power down is powered on, makes CPU minimum The sequential of all hardware circuits of the CPU resetted in system with resetting is consistent.
  2. 2. according to the method described in claim 1, it is characterized in that, by the operating system CPU minimum systems it is all hard Before the step of part circuit power down, the method further includes:
    To cpu reset.
  3. 3. according to the method described in claim 1, it is characterized in that, the CPU minimum systems include:Operating system it is embedded The peripheral circuit of CPU and the CPU in board.
  4. 4. according to the method described in claim 3, it is characterized in that, the peripheral circuit of the CPU includes following one kind or more Kind:
    Network interface card, exchange chip, clock chip, DDR chips and FLASH chip.
  5. 5. according to the method described in claim 2, it is characterized in that, the preset time period is according to needed for the cpu reset Time determine.
  6. 6. according to the method described in claim 2, it is characterized in that, to cpu reset, including:
    The operating system calls reboot functions to carry out cpu reset.
  7. 7. according to the method described in claim 6, it is characterized in that, by the operating system CPU minimum systems it is all hard Part circuit power down, including:
    The all hardware circuit power down of CPU minimum systems in operating system described in reboot function call FUNCA function pairs;
    The reboot letters that the FUNCA functions call when being and being articulated to CPU exceptional resets by system function rebootHoodAdd Hook Function on number, and there is all hardware circuit power down for making CPU minimum systems in the operating system.
  8. 8. according to the method described in claim 6, it is characterized in that, powered on to all hardware circuit of power down, including:
    The all hardware circuit of reboot function call FUNCA function pair power down powers on;
    The reboot letters that the FUNCA functions call when being and being articulated to CPU exceptional resets by system function rebootHoodAdd Hook Function on number, and have the function of to make all hardware circuit of CPU minimum systems in the operating system to power on.
  9. A kind of 9. power-off reset device based on VxWorks system, it is characterised in that including:
    Power down module, in the program exception of operating system, by all hardware of CPU minimum systems in the operating system Circuit power down;
    Judgment module, for judging whether power down mould hardware circuit power down time in the block reaches preset time period;
    Module is powered on, for determining that hardware circuit power down time reaches preset time period in judgment module, is then owned to power down Hardware circuit powers on, and the sequential of all hardware circuits of the CPU for making to reset in CPU minimum systems with resetting is consistent.
  10. 10. a kind of operating system, it is characterised in that including the device described in the claims 9.
CN201610892762.6A 2016-10-13 2016-10-13 Power failure reset method and device based on VxWorks system Expired - Fee Related CN107943259B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610892762.6A CN107943259B (en) 2016-10-13 2016-10-13 Power failure reset method and device based on VxWorks system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610892762.6A CN107943259B (en) 2016-10-13 2016-10-13 Power failure reset method and device based on VxWorks system

Publications (2)

Publication Number Publication Date
CN107943259A true CN107943259A (en) 2018-04-20
CN107943259B CN107943259B (en) 2020-12-25

Family

ID=61928321

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610892762.6A Expired - Fee Related CN107943259B (en) 2016-10-13 2016-10-13 Power failure reset method and device based on VxWorks system

Country Status (1)

Country Link
CN (1) CN107943259B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109361368A (en) * 2018-12-14 2019-02-19 无锡思泰迪半导体有限公司 A kind of filter and its control method of the integrated comparator with reset function
CN117540443A (en) * 2023-10-26 2024-02-09 中国人民解放军军事科学院系统工程研究院 Method for avoiding abnormal power failure damage of equipment for operating system

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020029374A1 (en) * 2000-07-14 2002-03-07 Moore Richard John Generalised program hooks
CN1549542A (en) * 2003-05-15 2004-11-24 中兴通讯股份有限公司 Digital communication system resetting apparatus and method
CN1949773A (en) * 2006-10-25 2007-04-18 华为技术有限公司 Method for starting network communication apparatus and device thereof
CN101615031A (en) * 2009-05-07 2009-12-30 浙江中控自动化仪表有限公司 The failure detection circuit of embedded dual processor system
CN102707782A (en) * 2012-05-15 2012-10-03 江苏中科梦兰电子科技有限公司 Multi-core central processing unit (CPU) based computer mainboard reset system and method
CN103984610A (en) * 2014-06-11 2014-08-13 武汉邮电科学研究院 FPGA (Field Programmable Gate Array) based power failure protection system and method
CN104503799A (en) * 2014-12-29 2015-04-08 长园深瑞继保自动化有限公司 Method for performing uninterrupted control over peripherals in system starting process
US20160065440A1 (en) * 2011-05-10 2016-03-03 Microsoft Technology Licensing, Llc Methods and Computer Program Products for Collecting Storage Resource Performance Data Using File System Hooks

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020029374A1 (en) * 2000-07-14 2002-03-07 Moore Richard John Generalised program hooks
CN1549542A (en) * 2003-05-15 2004-11-24 中兴通讯股份有限公司 Digital communication system resetting apparatus and method
CN1949773A (en) * 2006-10-25 2007-04-18 华为技术有限公司 Method for starting network communication apparatus and device thereof
CN101615031A (en) * 2009-05-07 2009-12-30 浙江中控自动化仪表有限公司 The failure detection circuit of embedded dual processor system
US20160065440A1 (en) * 2011-05-10 2016-03-03 Microsoft Technology Licensing, Llc Methods and Computer Program Products for Collecting Storage Resource Performance Data Using File System Hooks
CN102707782A (en) * 2012-05-15 2012-10-03 江苏中科梦兰电子科技有限公司 Multi-core central processing unit (CPU) based computer mainboard reset system and method
CN103984610A (en) * 2014-06-11 2014-08-13 武汉邮电科学研究院 FPGA (Field Programmable Gate Array) based power failure protection system and method
CN104503799A (en) * 2014-12-29 2015-04-08 长园深瑞继保自动化有限公司 Method for performing uninterrupted control over peripherals in system starting process

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
CHENGYE ZHANG、SHENGLAN DENG、HONG NING: "A local checkpoint mechanism for on-board computing", 《2012 IEEE INTERNATIONAL CONFERENCE ON INFORMATION SCIENCE AND TECHNOLOGY》 *
WOODHEAD: "《电子产品世界论坛》", 2 January 2008 *
刘尚军: "《ARM嵌入式技术原理与应用 基于XSCALE及VxWorks操作系统》", 30 September 2007 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109361368A (en) * 2018-12-14 2019-02-19 无锡思泰迪半导体有限公司 A kind of filter and its control method of the integrated comparator with reset function
CN117540443A (en) * 2023-10-26 2024-02-09 中国人民解放军军事科学院系统工程研究院 Method for avoiding abnormal power failure damage of equipment for operating system

Also Published As

Publication number Publication date
CN107943259B (en) 2020-12-25

Similar Documents

Publication Publication Date Title
KR101611373B1 (en) Apparatus and method for booting hibernation in portable terminal
CN203745958U (en) SIM card extension device and mobile terminal extension system with same
CN106775869B (en) Loading method and terminal equipment
US10219135B1 (en) Near field communication (NFC) enhanced computing systems
EP3432205A1 (en) Method for controlling infrared fill light and related products
US20150035386A1 (en) Battery Management Scheme for NFC
RU2524862C2 (en) Integrated microcircuit, information processing apparatus, software module control method, information processing system, information processing method and programme
CN206805598U (en) Storage card
CN109067416A (en) Method for realizing hot plug and start of SIM card and intelligent hardware
CN107943259A (en) Power-off reset method and apparatus based on VxWorks system
US10212272B1 (en) Near field communication enhanced computing systems
CN111142885A (en) eSIM device management method, device, equipment and storage medium
EP3082375B1 (en) Communications chip integrated with a sim card
CN109117406B (en) PCIE hot plug test method, device, terminal and storage medium
CN210691297U (en) Starting device of controller and controller
CN108196617B (en) BMC time setting method, device and system and readable storage medium
CN113961252B (en) PCIE board card anti-lost method, device and computer readable storage medium
CN104461659A (en) High-reliability computer starting method
CN214751393U (en) Microcontroller and computing system
CN109450682B (en) IB network card communication configuration method and device, terminal and storage medium
CN108419260B (en) SIM card connection control method, mobile terminal and storage medium
CN109739565A (en) A kind of method, apparatus, computer equipment and storage medium for guaranteeing Bootrom and operating normally
CN102467426B (en) Method for forbidding option read-only memory of external card in basic input/output system (BIOS)
CN111142950B (en) Device for realizing EMMC starting operation system by using JTAG
EP3091469A1 (en) Data card application method and data card

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20201225