CN108804126A - A kind of method for upgrading software and device - Google Patents
A kind of method for upgrading software and device Download PDFInfo
- Publication number
- CN108804126A CN108804126A CN201810497401.0A CN201810497401A CN108804126A CN 108804126 A CN108804126 A CN 108804126A CN 201810497401 A CN201810497401 A CN 201810497401A CN 108804126 A CN108804126 A CN 108804126A
- Authority
- CN
- China
- Prior art keywords
- installation procedure
- upgrading
- server
- stored
- video frequency
- 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.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/60—Software deployment
- G06F8/65—Updates
- G06F8/654—Updates using techniques specially adapted for alterable solid state memories, e.g. for EEPROM or flash memories
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/60—Software deployment
- G06F8/61—Installation
- G06F8/62—Uninstallation
Abstract
A kind of method for upgrading software of the application offer and device, this method are applied to the video frequency collection card of not tape operation system, including:It receives the installation procedure that server is sent and is stored in random access memory ram, the installation procedure embedded software currently used to video frequency collection card is run in RAM and is upgraded;If upgrading failure, video frequency collection card is then triggered to be restarted, after restart, the installation procedure used before the upgrading stored in flash storage is stuck in using video acquisition to restore embedded software, in this way, the installation procedure received is temporarily stored in RAM, the installation procedure of the embedded software to being used before the upgrading that is stored in flash storage does not cover, if upgrading failure, video frequency collection card embedded software can also be restored to according to the installation procedure of the embedded software used before the upgrading stored in flash storage before version, the use of video frequency collection card is not influenced, therefore, better user experience.
Description
Technical field
This application involves video frequency collection card technical field more particularly to a kind of method for upgrading software and device.
Background technology
Video frequency collection card is to carry out video to handle essential hardware device, is widely used in education, automobile, peace
The industries such as anti-, in practical application, the demand of the user of any industry to video acquisition can all be constantly occurring variation, so video
Capture card usually all has upgrade requirement.
Traditional mode upgraded to video frequency collection card is to upgrade manually:Using specific download device by the installation of system
Program transportation is upgraded automatically to video frequency collection card, then by video frequency collection card, since video frequency collection card present position is extremely divided
It dissipates, so the mode upgraded manually takes, effort, cost is higher, moreover, the position of partial video capture card installation is relatively high,
So the danger upgraded manually is also bigger.
Therefore, the mode of remote upgrade has been gradually appeared, the mode of remote upgrade can utilize video frequency collection card band itself
Cable network is communicated with upgrade server, has great advantage.But for the video frequency collection card of not tape operation system
Speech, because it is to drive the external equipment being connected with itself to work using embedded software, and to collected video figure
As carrying out picture signal processing operation, so the peripheral hardware driving or the upgrading of video processing program to video frequency collection card are substantially all
The embedded software that it is installed is upgraded, therefore, for the video frequency collection card of not tape operation system, once it is installed
The failure of embedded software remote upgrade, if occurred crashing or run collapse, that is, " race winged " being commonly called as, video frequency collection card cannot
Normal work, and can only depot repair, in this way, user will not have whithin a period of time, video frequency collection card will be available, user experience not
It is good, and producer also needs to repair, and takes, effort.
Invention content
A kind of method for upgrading software of the embodiment of the present application offer and device, to solve the video acquisition of not tape operation system
If card remote upgrade failure, as occurred crashing or run collapse, can only depot repair, caused by user whithin a period of time
There is no that video frequency collection card is available, and the problem of producer also needs to repair, and takes, effort.
In a first aspect, a kind of method for upgrading software provided by the embodiments of the present application, is applied to the video of not tape operation system
Capture card, including:It receives the installation procedure that server is sent and is stored in RAM, later, installation procedure pair is run in RAM
The currently used embedded software of video frequency collection card is upgraded, if upgrading failure, triggers video frequency collection card and is restarted, and
After restart, the installation procedure used before the upgrading stored in flash storage is stuck in using video acquisition to embedded software
Restored.
Using the above scheme, when the video frequency collection card to non-tape operation system carries out remote upgrade, server can be sent out
The installation procedure sent is stored temporarily in RAM, and it is currently used to video frequency collection card that the installation procedure received is run in RAM
Embedded software upgraded, in this way, the installation procedure received is temporarily stored in RAM, not to being stored in flash storage
Upgrading before the installation procedure of embedded software that uses covered, if upgrading failure, video frequency collection card can also basis
The installation procedure of the embedded software used before the upgrading stored in flash storage embedded software is restored to before version
This, does not influence the use of video frequency collection card, without depot repair again, better user experience, and it is time saving, laborsaving.
Under a kind of possible embodiment, before receiving the installation procedure that server is sent and being stored in RAM, may be used also
Software upgrade instruction to receive server transmission later restarts video frequency collection card according to software upgrade instruction, and
It after restarting, is sent to server and upgrades ready information, installation procedure is sent with trigger the server.
Under a kind of possible embodiment, upgrading failure is determined according to following steps:Periodically by video frequency collection card
The value of interior timer is initialized as preset value, in escalation process, if more than the value no initializtion of preset time timer
For preset value, then upgrading failure is can determine.
Under a kind of possible embodiment, further include:If it is determined that system upgrade success, then will deposit in flash storage
The installation procedure used before the upgrading of storage replaces with the installation procedure used when this upgrading, in this way, in flash storage always
It is stored with the installation procedure that video frequency collection card the last time uses when successfully upgrading, to prepare for remote upgrade next time.
Under a kind of possible embodiment, if upgrading successfully, by what is used before the upgrading stored in flash storage
Installation procedure replaces with the installation procedure used when this upgrading:When successfully installing the installation procedure received, start
Timer, if video frequency collection card can store Flash still in normal operation when the timing time of timer reaches preset duration
The installation procedure used before the upgrading stored in device replaces with the installation procedure used when this upgrading, in this way it can be ensured that storage
It is reliable, stablizes to the installation procedure in flash storage.
Under a kind of possible embodiment, flash storage includes the first storage region and the second storage region, will
The installation procedure used before the upgrading stored in flash storage replaces with the installation procedure used when this upgrading, if
Determine that the installation procedure used before upgrading is stored in the first storage region, then the installation procedure used when can upgrade this is deposited
Store up into the second storage region, in this way, using in flash storage the first storage region and the second storage region store in turn
The installation procedure of embedded software latest edition, flexibility are more preferable.
When it is implemented, server is to send installation procedure to video frequency collection card by the frame data in certain period of time
, so, under a kind of possible embodiment, receives the installation procedure that server is sent and be stored in RAM and include:To clothes
Each frame data that business device is sent carry out cyclic redundancy check and extract the process carried in the frame data when verification passes through and add
Program segment after close and preservation, it is close according to the decryption being stored in advance in flash storage after receiving all program segments
Each program segment of preservation is decrypted in code, to obtain installation procedure, in this way, cyclic redundancy check is carried out to every frame data,
The bit error rate in communication process can be effectively reduced, and then improves the success rate of remote upgrade.
Under a kind of possible embodiment, is sent to server after upgrading ready information, can also judge video
Whether capture card does not receive any frame data of server transmission within the set duration, if so, can terminate this upgrading behaviour
Make, and sends the information of upgrading failure to server, when to avoid communication abnormality between video frequency collection card and server, video
The case where capture card also waits for always installation procedure and cannot be normally carried out video acquisition.
Second aspect, a kind of software updating apparatus provided by the embodiments of the present application are applied to the video of not tape operation system
Capture card, including:Receiving module, for receive server transmission installation procedure and be stored in random access memory ram,
In, installation procedure upgrades for the embedded software currently used to video frequency collection card;Upgraded module, in RAM
The operation installation procedure embedded software currently used to video frequency collection card upgrades;If upgrading failure, triggers video and adopts
Truck is restarted, and after restart, the installation procedure used before the upgrading stored in flash storage is stuck in using video acquisition
Embedded software is restored.
Under a kind of possible embodiment, receiving module is additionally operable to receive installation procedure and the preservation that server is sent
Before in random access memory ram, the software upgrade instruction that server is sent is received;Upgraded module is additionally operable to according to software liter
Video frequency collection card is restarted in grade instruction;After restart, it is sent to server and upgrades ready information, sent out with trigger the server
Send installation procedure.
Under a kind of possible embodiment, upgraded module is specifically used for determining upgrading failure according to following steps:Period
The value of timer in video frequency collection card is initialized as to property preset value;In escalation process, if more than preset time timing
The value no initializtion of device is preset value, it is determined that upgrading failure.
Under a kind of possible embodiment, upgraded module will be deposited if being additionally operable to upgrade successfully in flash storage
The installation procedure used before the upgrading of storage replaces with the installation procedure used when this upgrading.
Under a kind of possible embodiment, upgraded module is specifically used for:When successfully installing the installation procedure received,
Start timer;If video frequency collection card deposits Flash still in normal operation when the timing time of timer reaches preset duration
The installation procedure used before the upgrading stored in reservoir replaces with the installation procedure used when this upgrading.
Under a kind of possible embodiment, flash storage includes the first storage region and the second storage region, upgrading
Module is specifically used for:If it is determined that the installation procedure used before upgrading is stored in the first storage region, then make when upgrading this
In installation procedure storage to the second storage region.
Under a kind of possible embodiment, server is to send installation procedure by the frame data in certain period of time
, receiving module is specifically used for:Cyclic redundancy check is carried out to each frame data that server is sent to carry when verification passes through
It takes the encrypted program segment of the process carried in the frame data and preserves;According to the decryption being stored in advance in flash storage
Each program segment of preservation is decrypted in password, to obtain installation procedure.
Under a kind of possible embodiment, upgraded module, be additionally operable to sent to server upgrade ready information it
Afterwards, if not receiving any frame data of server transmission within the set duration, terminate this updating operation, and can be to service
Device sends the information of upgrading failure.
The third aspect, a kind of computer provided by the embodiments of the present application, including at least one processing unit and at least one
A storage unit, wherein the storage unit has program stored therein code, when said program code is executed by the processing unit
When so that the computer executes the step of above-mentioned method for upgrading software.
Fourth aspect, a kind of computer readable storage medium provided by the embodiments of the present application, including program code, when described
When program code is run on computers, the step of making the computer execute above-mentioned method for upgrading software.
In addition, technique effect caused by any design method can be found in first aspect in second aspect to fourth aspect
Technique effect caused by middle difference realization method, details are not described herein again.
These aspects or other aspects of the application can more straightforward in the following description.
Description of the drawings
Fig. 1 is the application scenarios schematic diagram of method for upgrading software provided by the embodiments of the present application;
Fig. 2 is the schematic diagram of video frequency collection card provided by the embodiments of the present application;
Fig. 3 is the flow chart of method for upgrading software provided by the embodiments of the present application;
Fig. 4 is the structure chart of software updating apparatus provided by the embodiments of the present application;
Fig. 5 is the hardware structure of computer schematic diagram provided by the embodiments of the present application for realizing method for upgrading software.
Specific implementation mode
If in order to solve the video frequency collection card remote upgrade failure of not tape operation system, collapsed as occurred crashing or running
Burst, can only depot repair, caused by user it is available without video frequency collection card whithin a period of time, and producer also needs to be tieed up
Repair, take, effort the problem of, the embodiment of the present application provides a kind of method for upgrading software and device.
Video frequency collection card mentioned in the embodiment of the present application refers to the video frequency collection card of not tape operation system, also referred to as naked
The video frequency collection card of race.For the video frequency collection card of naked race, due to its not tape operation system, so needing using embedded
Software realizes the function similar to operating system, and here, it is soft that embedded software belongs to lightweight for operating system
Part, so development cost is relatively low, wherein embedded software is used to drive the external equipment being connected with video frequency collection card to carry out work
Make, and for carrying out picture signal processing to the collected video image of video frequency collection card.
In practical application, the video acquisition of naked race is stuck in after installation embedded software, you can what driving was connected with itself
External equipment, such as camera, serial ports, work, and can carry out picture signal processing to collected video image, this
In, the driver and video processing program of peripheral hardware are all coupling in embedded software, cannot be individually to video acquisition
Peripheral hardware driving or video processing program in card are upgraded.
Video frequency collection card during the application is implemented may include two kinds of operating modes, one is video capture mode, one is
Software upgrading pattern, when under video capture mode, video frequency collection card carries out video acquisition, and by collected video information
The storage device being connected with itself is sent to be stored;When under software upgrading pattern, video frequency collection card and server into
Row communication upgrades the embedded software of itself installation, and can carry out the trial operation of video acquisition, trial operation after upgrading
After success, before recycling the installation procedure of the latest edition received to be stuck in the upgrading stored in flash storage to video acquisition
Installation procedure covered.Under normal conditions, video frequency collection card is all operated under video capture mode, only when the system of progress
When upgrading, it is just switched to software upgrading pattern.
Fig. 1 shows the application scenarios schematic diagram of method for upgrading software provided by the embodiments of the present application, including server and
Multiple video frequency collection cards, server can upgrade the embedded software used in each video frequency collection card by network, and
And it is stored in the flash storage of each video frequency collection card used when the last successfully upgrading embedded software
Installation procedure.
First, the operational process of video frequency collection card is illustrated.
Usually, video frequency collection card by itself be stored in flash storage using the installation procedure of embedded software,
When video acquisition is stuck in each startup, the installation procedure preserved in flash storage is copied in the specified region of RAM into
Row operation, to complete the initialization to peripheral hardware driving and video processing program, later, you can carry out video acquisition.
In the prior art, it is first to wipe in flash storage when the embedded software to video frequency collection card upgrades
The installation procedure of the latest edition received is written in the installation procedure of version before again later, then, then by the installation journey of latest edition
Sequence is copied in the specified region of RAM and is run, i.e., embedded software currently used to video frequency collection card upgrades, this
Sample, if broken down in escalation process, because the installation procedure of version has been not present before embedded software, depending on
The embedded software of version before frequency capture card can not also trace back to, at this point, for a user, video frequency collection card cannot be just
Often carry out video acquisition, as having broken down, can only depot repair, user will be whithin a period of time without video frequency collection card
It can use.
In order to solve this problem, it in the embodiment of the present application, is risen when to the embedded software that video frequency collection card uses
When grade, the installation procedure for the latest edition that server is sent can be stored in flash storage first, but be temporarily stored in RAM
In, and run installation procedure in RAM and embedded software is upgraded, if upgraded successfully, then wipe in flash storage
The installation procedure stored before, and then will be in the storage to flash storage of the installation procedure of latest edition;If upgrading failure, also
Embedded software can be restored according to the installation procedure used before the upgrading stored in flash storage, in this way, will connect
The installation procedure received is temporarily stored in RAM, the installation not to the embedded software used before the upgrading that is stored in flash storage
Program is covered, if upgrading failure, video frequency collection card can also be according to using before the upgrading stored in flash storage
The installation procedure of embedded software embedded software is restored to before version, do not interfere with the use of video frequency collection card,
Without depot repair again, better user experience, and it is time saving, laborsaving.
When it is implemented, can also multiple storage regions be divided into the flash storage of video frequency collection card, then, make
The installation procedure that embedded software latest edition used in video frequency collection card is alternately stored with two storage regions therein, makes
With such mode, installation procedure just can be stored in video by video frequency collection card when receiving the installation procedure of server transmission
In capture card in corresponding storage region, the installation procedure used when upgrading can also be stored in video again after successfully upgrading
In capture card in corresponding storage region, flexibility is more preferable.
The mode stored in turn is illustrated with reference to specific embodiment.
As shown in Fig. 2, for the schematic diagram of video frequency collection card provided by the embodiments of the present application, wherein video frequency collection card
Flash storage includes two storage regions:Storage region 1 and storage region 2, storage region 1 and storage region 2 are in turn
In practical application, a flag can be arranged in the installation procedure for storing embedded software latest edition used in video frequency collection card
Flag, flag=1 indicate that the installation procedure used when the last successfully upgrading is stored in storage region 1;Flag=2 tables
Show that the installation procedure used when the last successfully upgrading is stored in storage region 2, as installation procedure is in 1 He of storage region
Storage in turn in storage region 2, flag flags also can alternating values between 1 and 2.
Under normal conditions, video frequency collection card is operated under video capture mode, when the software liter for receiving server transmission
When grade instruction, video frequency collection card can be restarted and be switched to software upgrading pattern, and later, video frequency collection card can notify server
Preparation upgrade status is had been enter into, if video frequency collection card does not receive any frame data of server transmission within the set duration,
It is abnormal to can determine that the communication between server exists, and then is switched to video capture mode with ends with system updating operation, and
The information of upgrading failure is sent to server;Otherwise, each frame data that video frequency collection card can send server recycle
Redundancy check is extracted the encrypted program segment of the process carried in the frame data and is stored in RAM, wait for when verification passes through
After having received all program segments, each program segment of preservation is carried out according to the clear crytpographic key being stored in advance in flash storage
Decryption, to obtain the installation procedure of latest edition.
Further, the installation procedure of latest edition can be loaded into the specified region of RAM by video frequency collection card, be referred at this
Determine operation installation procedure in region to upgrade embedded software, if after success installation procedure, video frequency collection card is persistently transported
The capable time is more than preset time, then can determine and this time upgrade successfully, and then can be by the installation journey for the latest edition that this is received
In sequence storage to flash storage, it is assumed that current flag=1 can then store the installation procedure of latest edition to flash storage
Storage region 2 in, also, update flag=2.
When it is implemented, being provided with timer in video frequency collection card, such as watchdog circuit, video frequency collection card can be periodically
The value of watchdog circuit is initialized into preset value, that is, feeds dog, when being upgraded, if more than preset time watchdog circuit
Value all no initializtions are preset value, then upgrading failure are can determine, at this point, watchdog circuit can be such that video frequency collection card weighs automatically
It opens, after restarting, video frequency collection card can re-read the value of flag, use the example above, it is assumed that flag=1 before upgrading, then, video
Installation procedure in storage region 1 can be loaded into the specified region of RAM by capture card, and peace is run in this specifies region
Dress program initializes external equipment and video processing program, i.e., is restored to the embedded software that video frequency collection card uses
Version before update, in this way, the stability of video frequency collection card in remote upgrade procedure can be improved, user experience is also more preferable.
As shown in figure 3, for the flow chart of method for upgrading software provided by the embodiments of the present application, include the following steps:
S301:Video frequency collection card receives the software upgrade instruction that server is sent, and is restarted according to software upgrade instruction,
And software upgrading pattern is selected after restart.
S302:It is sent to server and upgrades ready information.
S303:Judge whether not receiving any frame data that server is sent within the set duration, if so, into
S304;Otherwise, into S305.
S304:Video capture mode is switched to terminate updating operation, and notifies the information of server updating failure.
S305:Receive and preserve the installation procedure of the latest edition of server transmission.
In practical application, user belongs to private data mostly using the video data that video frequency collection card acquires, if by
Great economic loss may be brought to user by arbitrarily stealing, and therefore, also need to ensure when upgrading video frequency collection card
The safety of installation procedure, for example installation procedure is encrypted, installation procedure is usurped to avoid criminal to obtain user
Private data.
Specifically, server can make an appointment the clear crytpographic key of installation procedure with video frequency collection card, subsequently carry out it is remote
When journey upgrades, what server was sent to video frequency collection card is by encrypted installation procedure, such as using 128 secret key length
Advanced Encryption Standard (Advanced Encryption Standard, AES) Encryption Algorithm installation procedure is encrypted, depending on
After frequency capture card receives installation procedure, can according to the clear crytpographic key stored in flash storage in advance to installation procedure into
Row decryption, in this way, installation procedure in transmission process is by encrypted, safety is preferably ensured.
In addition, server sends installation procedure generally by the frame data in certain period of time, it is contemplated that communicated
Bit error rate problem in journey, each frame data that video frequency collection card can also send server carry out cyclic redundancy check, if
Verification does not pass through, then when verification passes through, then can extract the warp carried in the frame data to the server request retransmission frame data
It crosses encrypted program segment and is stored in RAM, after receiving all program segments, recycling is stored in advance in Flash and deposits
Each program segment of preservation is decrypted in clear crytpographic key in reservoir, to obtain installation procedure, in this way, it is ensured that receive
The correctness of installation procedure improves the probability for successfully upgrading video frequency collection card as much as possible.
S306:Installation procedure is loaded into the specified region of RAM, operation installation procedure is currently used to video frequency collection card
Embedded software upgraded.
In practical application, if there is new demand or the installation journey of its embedded software used in video frequency collection card
There is mistake in sequence, is required for upgrading embedded software.
S307:Judge whether to upgrade successfully, if so, into S308;Otherwise, into S309.
When it is implemented, video frequency collection card is internally provided with timer, and when video frequency collection card normal operation, video acquisition
The value of timer regularly can be initialized as preset value by card, if being more than preset time timer when carrying out remote upgrade
Value no initializtion be preset value, then can determine upgrading failure.If exception is not present during the installation process, can successfully pacify
After the installation procedure for filling latest edition, start timer and carry out timing, if video when the timing time of timer reaches preset duration
Capture card then can determine and upgrade successfully still in normal operation.
S308:The installation procedure used before the upgrading stored in flash storage replaced with and is used when this upgrading
Installation procedure.
Specifically, the installation procedure used before the upgrading stored in flash storage is first wiped, and then this is risen
In the installation procedure write-in flash storage used when grade.
Optionally it is determined that when system upgrade success, the information upgraded successfully can also be sent to server.
S309:Triggering video frequency collection card is restarted, and after restart, is stuck in flash storage and is deposited using video acquisition
The installation procedure used before the upgrading of storage restores embedded software.
That is, the installation procedure used before the upgrading stored in flash storage is loaded into the specified region of RAM,
Operation installation procedure drives peripheral hardware in the specified region and video processing program initializes, to which embedded software is extensive
The multiple version to before update.
Particularly, it when carrying out subregion to flash storage, can also will be received after step S305 newest
The installation procedure of version is stored in flash storage, also, the installation of latest edition no matter when is stored into flash storage
Program can first determine the region of the installation procedure used before storage upgrading in flash storage, it is assumed that the region is Flash
First storage region of memory can then store the installation procedure of latest edition to the second memory block in flash storage
In domain, to achieve the purpose that the first storage region and the second storage region store the installation procedure of latest edition in turn.
Based on same inventive concept, a kind of software liter corresponding with method for upgrading software is additionally provided in the embodiment of the present application
Stage arrangement, the device are applied to the video frequency collection card of non-tape operation system, the principle and the application solved the problems, such as due to the device
Embodiment method for upgrading software is similar, therefore the implementation of the device may refer to the implementation of method, and overlaps will not be repeated.
As shown in figure 4, for the structure chart of software updating apparatus provided by the embodiments of the present application, including:
Receiving module 401, for receive server transmission installation procedure and be stored in random access memory ram, wherein
Installation procedure upgrades for the embedded software currently used to the video frequency collection card;
Upgraded module 402 runs the installation procedure embedded software currently used to video frequency collection card in RAM and rises
Grade;If upgrading failure, is triggered video frequency collection card and is restarted, after restart, is stuck in flash storage using video acquisition
The installation procedure used before the upgrading of storage restores embedded software.
Under a kind of possible embodiment, receiving module 401 is additionally operable to receive installation procedure and the guarantor that server is sent
Before in random access memory ram, the software upgrade instruction that server is sent is received;
Upgraded module 402 is additionally operable to restart video frequency collection card according to software upgrade instruction;After restart, to clothes
Business device, which is sent, upgrades ready information, and installation procedure is sent with trigger the server.
Under a kind of possible embodiment, upgraded module 402 is specifically used for determining upgrading failure according to following steps:
The value of timer in video frequency collection card is periodically initialized as preset value;
In escalation process, if the value no initializtion more than preset time timer is preset value, it is determined that upgrading is lost
It loses.
Under a kind of possible embodiment, upgraded module 402 will be in flash storage if being additionally operable to upgrade successfully
The installation procedure used before the upgrading of storage replaces with the installation procedure used when this upgrading.
Under a kind of possible embodiment, upgraded module 402 is specifically used for:
When successfully installing the installation procedure received, start timer;
If video frequency collection card stores Flash still in normal operation when the timing time of timer reaches preset duration
The installation procedure used before the upgrading stored in device replaces with the installation procedure used when this upgrading.
Under a kind of possible embodiment, flash storage includes the first storage region and the second storage region, upgrading
Module 402 is specifically used for:
If it is determined that the installation procedure used before upgrading is stored in the first storage region, then the peace used when upgrading this
It fills in program storage to the second storage region.
Under a kind of possible embodiment, server is to send installation procedure by the frame data in certain period of time
, receiving module 401 is specifically used for:
Cyclic redundancy check is carried out to each frame data that server is sent to extract in the frame data when verification passes through
The encrypted program segment of process of carrying simultaneously preserves;
Each program segment of preservation is decrypted according to the clear crytpographic key being stored in advance in flash storage, is pacified
Fill program.
Under a kind of possible embodiment, upgraded module 402 is additionally operable to sending the ready information of upgrading to server
Later, if not receiving any frame data of server transmission within the set duration, terminate this updating operation;To server
Send the information of upgrading failure.
As shown in figure 5, being the hardware structure of computer provided by the embodiments of the present application for realizing method for upgrading software
Schematic diagram, including processor 501, communication interface 502, memory 503 and communication bus 504, wherein processor 501, communication connects
Mouth 502, memory 503 completes mutual communication by communication bus 504.
Memory 503, for storing computer program;
Processor 501, when for executing the program stored on memory 503 so that computer executes above-mentioned software liter
The step of grade method.
A kind of computer readable storage medium provided by the embodiments of the present application, including program code, work as said program code
When running on computers, make computer execute above-mentioned method for upgrading software the step of.
It should be understood by those skilled in the art that, embodiments herein can be provided as method, system or computer program
Product.Therefore, complete hardware embodiment, complete software embodiment or reality combining software and hardware aspects can be used in the application
Apply the form of example.Moreover, the application can be used in one or more wherein include computer usable program code computer
The computer program production implemented in usable storage medium (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.)
The form of product.
The application is flow of the reference according to method, apparatus (system) and computer program product of the embodiment of the present application
Figure and/or block diagram describe.It should be understood that can be realized by computer program instructions every first-class in flowchart and/or the block diagram
The combination of flow and/or box in journey and/or box and flowchart and/or the block diagram.These computer programs can be provided
Instruct the processor of all-purpose computer, special purpose computer, Embedded Processor or other programmable data processing devices to produce
A raw machine so that the instruction executed by computer or the processor of other programmable data processing devices is generated for real
The device for the function of being specified in present one flow of flow chart or one box of multiple flows and/or block diagram or multiple boxes.
These computer program instructions, which may also be stored in, can guide computer or other programmable data processing devices with spy
Determine in the computer-readable memory that mode works so that instruction generation stored in the computer readable memory includes referring to
Enable the manufacture of device, the command device realize in one flow of flow chart or multiple flows and/or one box of block diagram or
The function of being specified in multiple boxes.
These computer program instructions also can be loaded onto a computer or other programmable data processing device so that count
Series of operation steps are executed on calculation machine or other programmable devices to generate computer implemented processing, in computer or
The instruction executed on other programmable devices is provided for realizing in one flow of flow chart or multiple flows and/or block diagram one
The step of function of being specified in a box or multiple boxes.
Although the preferred embodiment of the application has been described, created once a person skilled in the art knows basic
Property concept, then additional changes and modifications may be made to these embodiments.So it includes excellent that the following claims are intended to be interpreted as
It selects embodiment and falls into all change and modification of the application range.
Obviously, those skilled in the art can carry out the application essence of the various modification and variations without departing from the application
God and range.In this way, if these modifications and variations of the application belong to the range of the application claim and its equivalent technologies
Within, then the application is also intended to include these modifications and variations.
Claims (18)
1. a kind of method for upgrading software is applied to the video frequency collection card of not tape operation system, which is characterized in that including:
It receives the installation procedure that server is sent and is stored in random access memory ram, the installation procedure to described for regarding
The currently used embedded software of frequency capture card is upgraded;
The installation procedure embedded software currently used to the video frequency collection card is run in the RAM to upgrade;
If upgrading failure, is triggered the video frequency collection card and is restarted, after restart, is stuck in using the video acquisition
The installation procedure of the embedded software used before the upgrading stored in flash storage carries out the embedded software
Restore.
2. the method as described in claim 1, which is characterized in that receive the installation procedure that server is sent and be stored in and deposit at random
Before in reservoir RAM, further include:
Receive the software upgrade instruction that the server is sent;
The video frequency collection card is restarted according to the software upgrade instruction;
After restart, it is sent to the server and upgrades ready information, the installation procedure is sent to trigger the server.
3. method as claimed in claim 1 or 2, which is characterized in that determine upgrading failure according to following steps:
The value of timer in the video frequency collection card is periodically initialized as preset value;
In escalation process, if the value no initializtion more than timer described in preset time is the preset value, it is determined that rise
Grade failure.
4. method as claimed in claim 1 or 2, which is characterized in that further include:
If upgrading successfully, the installation procedure used before the upgrading stored in the flash storage is replaced with into this upgrading
When the installation procedure that uses.
5. method as claimed in claim 4, which is characterized in that if upgrading successfully, by what is stored in the flash storage
The installation procedure used before upgrading replaces with the installation procedure used when this upgrading, including:
When successfully installing the installation procedure received, start timer;
It, will be described still in normal operation if the timing time of the timer reaches video frequency collection card when preset duration
The installation procedure used before the upgrading stored in flash storage replaces with the installation procedure used when this upgrading.
6. method as claimed in claim 5, which is characterized in that the flash storage includes the first storage region and second
The installation procedure used before the upgrading stored in the flash storage is replaced with and to be used when this upgrading by storage region
Installation procedure, including:
If it is determined that the installation procedure used before upgrading is stored in first storage region, then the peace used when upgrading this
It fills in program storage to second storage region.
7. the method as described in claim 1, which is characterized in that the server is sent out by the frame data in certain period of time
Installation procedure is sent, the installation procedure that server is sent is received and is stored in random access memory ram, including:
Cyclic redundancy check is carried out to each frame data that the server is sent to extract in the frame data when verification passes through
The encrypted program segment of process of carrying simultaneously preserves;
Each program segment of preservation is decrypted according to the clear crytpographic key being stored in advance in the flash storage, obtains institute
State installation procedure.
8. the method for claim 7, which is characterized in that sent to the server after upgrading ready information, also
Including:
If not receiving any frame data that the server is sent within the set duration, terminate this updating operation, and to
The server sends the information of upgrading failure.
9. a kind of software updating apparatus is applied to the video frequency collection card of not tape operation system, which is characterized in that including:
Receiving module, for receive server transmission installation procedure and be stored in random access memory ram, the installation procedure
Upgrade for the embedded software currently used to the video frequency collection card;
Upgraded module, for running embedded currently used to the video frequency collection card of the installation procedure in the RAM
Software is upgraded;If upgrading failure, is triggered the video frequency collection card and is restarted, after restart, adopted using the video
Collection is stuck in the installation procedure of the embedded software used before the upgrading stored in flash storage, to the embedded software
Part is restored.
10. device as claimed in claim 9, which is characterized in that
The receiving module connects before being additionally operable to the installation procedure that reception server is sent and being stored in random access memory ram
Receive the software upgrade instruction that the server is sent;
The upgraded module is additionally operable to restart the video frequency collection card according to the software upgrade instruction;After restart,
It is sent to the server and upgrades ready information, the installation procedure is sent to trigger the server.
11. the device as described in claim 9 or 10, which is characterized in that the upgraded module is specifically used for according to following steps
Determine upgrading failure:
The value of timer in the video frequency collection card is periodically initialized as preset value;
In escalation process, if the value no initializtion more than timer described in preset time is the preset value, it is determined that rise
Grade failure.
12. the device as described in claim 9 or 10, which is characterized in that
The upgraded module, if being additionally operable to upgrade successfully, the installation that will be used before the upgrading stored in the flash storage
Program replaces with the installation procedure used when this upgrading.
13. device as claimed in claim 12, which is characterized in that the upgraded module is specifically used for:
When successfully installing the installation procedure received, start timer;
It, will be described still in normal operation if the timing time of the timer reaches video frequency collection card when preset duration
The installation procedure used before the upgrading stored in flash storage replaces with the installation procedure used when this upgrading.
14. device as claimed in claim 13, which is characterized in that the flash storage includes the first storage region and the
Two storage regions, the upgraded module are specifically used for:
If it is determined that the installation procedure used before upgrading is stored in first storage region, then the peace used when upgrading this
It fills in program storage to second storage region.
15. device as claimed in claim 9, which is characterized in that the server is by the frame data in certain period of time
Installation procedure is sent, the receiving module is specifically used for:
Cyclic redundancy check is carried out to each frame data that the server is sent to extract in the frame data when verification passes through
The encrypted program segment of process of carrying simultaneously preserves;
Each program segment of preservation is decrypted according to the clear crytpographic key being stored in advance in the flash storage, obtains institute
State installation procedure.
16. device as claimed in claim 15, which is characterized in that
The upgraded module is additionally operable to after sending the ready information of upgrading to the server, if within the set duration not
Any frame data that the server is sent are received, then terminate this updating operation;Upgrading failure is sent to the server
Information.
17. a kind of computer, which is characterized in that including at least one processing unit and at least one storage unit, wherein
The storage unit has program stored therein code, when said program code is executed by the processing unit so that the computer
Perform claim requires the step of 1~8 any the method.
18. a kind of computer readable storage medium, which is characterized in that including program code, when said program code is in computer
When upper operation, the step of making the computer perform claim require 1~8 any the method.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810497401.0A CN108804126A (en) | 2018-05-22 | 2018-05-22 | A kind of method for upgrading software and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810497401.0A CN108804126A (en) | 2018-05-22 | 2018-05-22 | A kind of method for upgrading software and device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN108804126A true CN108804126A (en) | 2018-11-13 |
Family
ID=64091480
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810497401.0A Pending CN108804126A (en) | 2018-05-22 | 2018-05-22 | A kind of method for upgrading software and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108804126A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109511110A (en) * | 2018-12-29 | 2019-03-22 | Tcl移动通信科技(宁波)有限公司 | A kind of WIFI configuration software installation control method, device and storage medium |
CN111722856A (en) * | 2019-03-19 | 2020-09-29 | 上海汽车集团股份有限公司 | Method and device for upgrading firmware in vehicle-mounted microcontroller |
CN112631635A (en) * | 2021-03-10 | 2021-04-09 | 武汉瓯越网视有限公司 | Live broadcast client updating method and device, electronic equipment and storage medium |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6601212B1 (en) * | 2000-03-29 | 2003-07-29 | Hewlett-Packard Development Company, Lp. | Method and apparatus for downloading firmware to a non-volatile memory |
CN101355434A (en) * | 2007-07-24 | 2009-01-28 | 中兴通讯股份有限公司 | Method and apparatus for upgrading software of multimedia remote terminal |
CN104156249A (en) * | 2014-08-18 | 2014-11-19 | 四川九成信息技术有限公司 | Embedded software upgrading method |
-
2018
- 2018-05-22 CN CN201810497401.0A patent/CN108804126A/en active Pending
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6601212B1 (en) * | 2000-03-29 | 2003-07-29 | Hewlett-Packard Development Company, Lp. | Method and apparatus for downloading firmware to a non-volatile memory |
CN101355434A (en) * | 2007-07-24 | 2009-01-28 | 中兴通讯股份有限公司 | Method and apparatus for upgrading software of multimedia remote terminal |
CN104156249A (en) * | 2014-08-18 | 2014-11-19 | 四川九成信息技术有限公司 | Embedded software upgrading method |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109511110A (en) * | 2018-12-29 | 2019-03-22 | Tcl移动通信科技(宁波)有限公司 | A kind of WIFI configuration software installation control method, device and storage medium |
CN109511110B (en) * | 2018-12-29 | 2022-05-06 | Tcl移动通信科技(宁波)有限公司 | WIFI configuration software installation control method and device and storage medium |
CN111722856A (en) * | 2019-03-19 | 2020-09-29 | 上海汽车集团股份有限公司 | Method and device for upgrading firmware in vehicle-mounted microcontroller |
CN111722856B (en) * | 2019-03-19 | 2024-04-09 | 上海汽车集团股份有限公司 | Method and device for upgrading firmware in vehicle-mounted microcontroller |
CN112631635A (en) * | 2021-03-10 | 2021-04-09 | 武汉瓯越网视有限公司 | Live broadcast client updating method and device, electronic equipment and storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US9705678B1 (en) | Fast CAN message authentication for vehicular systems | |
CN101377744B (en) | Method and apparatus for recovering terminal equipment software upgrade | |
CN108804126A (en) | A kind of method for upgrading software and device | |
CN102238093B (en) | Service interruption prevention method and device | |
CN109358882A (en) | A kind of television terminal carries out the method and device of firmware upgrade | |
US9996425B2 (en) | System and method for agentless backup of virtual machines | |
CN102609349A (en) | Method and system for screen capture in server failure | |
CN102411523A (en) | Method and device for storing file backups and backup method for file systems | |
CN111240722B (en) | Method for upgrading firmware over the air, and terminal, server and system applied by same | |
CN108170457A (en) | Firmware upgrade method, device and VR head-mounted displays | |
CN105677398A (en) | Universal embedded computer software on-line upgrading method | |
CN105740017A (en) | Cloud television system upgrading method and device | |
US20180077232A1 (en) | Method and Device for Establishing Communication Connection | |
CN104636666A (en) | Method and safety device for safely processing information of mobile terminal | |
CN104918114A (en) | Method and device for upgrading operation system | |
CN104978223B (en) | The method for realizing Web mode updating apparatus firmwares | |
CN111104201A (en) | System migration method and device, electronic equipment and storage medium | |
CN110083379A (en) | A kind of server component upgrade method and relevant apparatus | |
CN114780127A (en) | Embedded equipment firmware updating method, embedded equipment and development end equipment | |
CN106210877A (en) | The method for upgrading system of intelligent television and device | |
CN105550071A (en) | System file upgrading and detecting method and communication device | |
CN109710377B (en) | Method for recovering kvm virtual machine from faulty distributed storage | |
CN111078463A (en) | Data backup method, device and system | |
CN109271190A (en) | A kind of device updating method and embedded device | |
CN104572255B (en) | A kind of multilayer application trustship method, apparatus and system |
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 | ||
TA01 | Transfer of patent application right | ||
TA01 | Transfer of patent application right |
Effective date of registration: 20200306 Address after: 101300, No. two, 1 road, Shunyi Park, Zhongguancun science and Technology Park, Beijing, Shunyi District Applicant after: Beijing Tucson wisdom Technology Co., Ltd. Address before: 101300, No. two, 1 road, Shunyi Park, Zhongguancun science and Technology Park, Beijing, Shunyi District Applicant before: TuSimple |