CN103530153A - Remote updating method of user electricity utilization information collecting terminals - Google Patents
Remote updating method of user electricity utilization information collecting terminals Download PDFInfo
- Publication number
- CN103530153A CN103530153A CN201310471577.6A CN201310471577A CN103530153A CN 103530153 A CN103530153 A CN 103530153A CN 201310471577 A CN201310471577 A CN 201310471577A CN 103530153 A CN103530153 A CN 103530153A
- Authority
- CN
- China
- Prior art keywords
- files
- whole
- main website
- upgrading terminals
- acquisition terminal
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 44
- 230000005611 electricity Effects 0.000 title abstract description 4
- 238000012545 processing Methods 0.000 claims abstract description 14
- 238000012795 verification Methods 0.000 claims description 60
- 238000004891 communication Methods 0.000 claims description 11
- 230000002159 abnormal effect Effects 0.000 claims description 5
- 238000002360 preparation method Methods 0.000 claims description 5
- 206010048669 Terminal state Diseases 0.000 claims description 3
- 238000003860 storage Methods 0.000 claims description 3
- 238000012546 transfer Methods 0.000 claims description 3
- 238000012423 maintenance Methods 0.000 abstract description 6
- 230000007547 defect Effects 0.000 abstract description 3
- 241001269238 Data Species 0.000 description 2
- 230000005540 biological transmission Effects 0.000 description 2
- 239000000463 material Substances 0.000 description 2
- 230000015572 biosynthetic process Effects 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000010586 diagram Methods 0.000 description 1
- 239000006185 dispersion Substances 0.000 description 1
- 238000009826 distribution Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 238000005457 optimization Methods 0.000 description 1
- 230000002787 reinforcement Effects 0.000 description 1
- 230000009466 transformation Effects 0.000 description 1
Images
Landscapes
- Stored Programmes (AREA)
- Information Transfer Between Computers (AREA)
Abstract
The invention relates to a remote updating method of user electricity utilization information collecting terminals. The method includes the steps that firstly, a collecting terminal is selected as a currently-updated terminal by a master station; secondly, all frame file blocks and single-frame check data are transmitted to the currently-updated terminal by the master station, all the frame file blocks are checked by the currently-updated terminal, whole file check data are transmitted to the currently-updated terminal by the master station, the whole program updating file is checked by the currently-updated terminal, and updating processing on the currently-updated terminal is finished; thirdly, whether updating processing of all collecting terminals is finished or not is judged by the master station: if not, the next collecting terminal is selected as the currently-updated terminal and the second step is carried out, and if yes, remote updating is finished. The remote updating method of the user electricity utilization information collecting terminals can achieve remote updating and maintenance of the collecting terminals and thoroughly overcome defects of a traditional updating method.
Description
Technical field
The present invention relates to a kind of user power utilization information acquisition terminal remote upgrade method, can realize remote upgrade maintenance terminal equipment.
Background technology
According to the applicant understood, user power utilization information acquisition system can be national grid " SG186 engineering " provide user in real time/historical power information data, also can be low and medium voltage distribution network, rural power grid provide substation transformer, common transformer, rural comprehensive transformer etc. in real time/historical data and operating mode ruuning situation.User power utilization information acquisition system can pass through built power communication net, and provide quickly and easily in real time/historical power information ,Wei State Grid Corporation of China's reinforcement self work also provides high-quality electricity consumption service that data supporting is provided to client.
User power utilization information acquisition system generally includes the acquisition terminal that is dispersed in each collection point, and with the main website server of acquisition terminal communication connection.In the process of maintenance customer's power information acquisition system, often because demand change increases function, solves the reasons such as on-the-spot operation problem, optimizer flow process, need to implement upgrade maintenance operation to each acquisition terminal.Traditional upgrading mode is " artificial local upgrade " mode, by technical support personnel's carried terminal ROMPaq, to acquisition terminal scene, carries out local upgrade.Yet, because acquisition terminal quantity is many, distributional region is wide, dispersion degree is high, field running environment is poor, this traditional upgrading mode cannot meet the requirement of batch processing, high-timeliness, and upgrading all can take a large amount of human and material resources at every turn, has increased the operation cost of user power utilization information acquisition system.
Summary of the invention
Technical matters to be solved by this invention is: the problem existing for prior art, a kind of user power utilization information acquisition terminal remote upgrade method is proposed, and realize the remote upgrade of acquisition terminal is safeguarded, thoroughly overcome the defect of traditional upgrade method.
The technical scheme that the present invention solves its technical matters is as follows:
An information acquisition terminal remote upgrade method, is characterized in that, comprises the following steps:
It is current upgrading terminals that an acquisition terminal is selected by the first step, main website;
Second step, main website send each frame blocks of files and the single frames checking data that through single frames checking algorithm draw corresponding with each frame blocks of files being formed by whole program upgrade file division in advance frame by frame to current upgrading terminals; Current upgrading terminals is by each frame blocks of files of described single frames checking algorithm verification;
San Bu, main website sends the whole file verification data that through whole file verification algorithm draw corresponding with whole program upgrade file to current upgrading terminals; Current upgrading terminals is by the whole program upgrade file of described whole file verification algorithm verification;
The 4th step, current upgrading terminals upgrading processing finish; The whether all acquisition terminal upgrading processing of main station judging finish, and to select if not next acquisition terminal be current upgrading terminals and go to second step, if remote upgrade finishes.
Applicant is in depth finding in practical studies for a long time, although the size of acquisition terminal program upgrade file only has hundreds of KB to number MB, but limited by the transmission of power communication net, cannot be by the disposable acquisition terminal that is sent to of program upgrade file, program upgrade file division can only be become to some frame blocks of files, then be sent to frame by frame acquisition terminal.For guaranteeing the safety and reliability of this send mode; applicant further works out first every frame blocks of files is carried out to verification; again whole program upgrade file is carried out the technological means of verification; with this, guarantee that program upgrade file is sent to acquisition terminal like clockwork; the possibility of avoiding data to be stolen and usurping, farthest protects the safety of power information.
The present invention further perfect technical scheme is as follows:
Preferably, in second step, as follows for the single frames checking algorithm detailed process of each frame blocks of files:
S1. initialization: making variable W_CRC is 16 bits, each bit value is zero; Make data pointer i=1;
S2. get 8, the left side of variable W_CRC and be saved to variable W_CRC1; Get 8, the right of variable W_CRC and be saved to variable W_CRC2;
S3. read the i byte data of present frame blocks of files, and these data and variable W_CRC2 are carried out to XOR, income value is N;
S4. the numerical value of the N order in password table and variable W_CRC1 are carried out to XOR, income value is saved to variable W_CRC; Described password table by least 256 >=0x0 and≤the sexadecimal numerical value predetermined order of 0xffff forms; The initial order of described password table is numbered zero;
S5. make data pointer i=i+1, judge whether present frame blocks of files reads complete, if go to S6, go to if not S2;
S6. the numerical value negate to variable W_CRC, obtains the single frames checking data of present frame blocks of files.
Preferably, in the 3rd step, as follows for the whole file verification algorithm detailed process of whole program upgrade file:
T1. initialization: making variable W_CS is 32 bits, each bit value is zero; Make data pointer j=1;
T2. the i byte data of fetch program upgrade file, and these data and variable W_CS are done sums and computing, income value is saved to variable W_CS;
T3. make data pointer j=j+1, it is complete whether determining program upgrade file reads, if go to T4, goes to if not T2;
T4. the numerical value of variable W_CS is the whole file verification data of whole program upgrade file.
Above single frames checking algorithm and whole file verification algorithm are the checking algorithms that is specially adapted for acquisition terminal program upgrade file that applicant draws through further going deep into practical studies, can further guarantee the safety and reliability of program upgrade file.
Preferably, the detailed process of second step is as follows:
A1. initialization: make frame pointer k=1, make frame re-transmission frequency n=0;
A2. main website sends k frame blocks of files to current upgrading terminals, and sends the single frames checking data drawing through single frames checking algorithm corresponding with k frame blocks of files;
A3. current upgrading terminals is calculated the single frames checking data of k frame blocks of files by described single frames checking algorithm, and judges whether to conform to the single frames checking data of receiving; If the current upgrading terminals that conforms to is returned to successfully message to main website, main website records current upgrading terminals and has downloaded k frame blocks of files, goes to A4; If the current upgrading terminals that do not conform to is returned to re-send request may to main website, main website makes frame re-transmission frequency n=n+1, and judges whether n is greater than predetermined value, if main website records the verification of current upgrading terminals k frame blocks of files extremely and goes to the 4th step, goes to if not A2;
A4. make frame pointer k=k+1, the whether all frame blocks of files of main station judging are sent, if go to the 3rd step, go to if not A2.
Above-mentioned optimal technical scheme is that applicant draws through further going deep into practical studies, can effectively guarantee the security of each frame blocks of files, can feed back in time the abnormal acquisition terminal of upgrading, be convenient to overhaul in time targetedly, can also record acquisition terminal downloading process, be convenient to realize breakpoint transmission when communication condition is poor.
Preferably, the detailed process of the 3rd step is as follows:
B1. main website sends the whole file verification data that through whole file verification algorithm draw corresponding with whole program upgrade file to current upgrading terminals;
B2. current upgrading terminals is calculated the whole file verification data of whole program upgrade file by described whole file verification algorithm, and judges whether to conform to the whole file verification data of receiving; If conform to, go to B3; If do not conform to, main website does not record the whole file verification of current upgrading terminals extremely and goes to the 4th step;
B3. current upgrading terminals is carried out to reset and is restarted action, and program upgrade file is transferred to formal application area from temporary storage area, then by described whole file verification algorithm, calculate the whole file verification data of whole program upgrade file, and judge whether to conform to the whole file verification data of receiving; If conform to, main website records current upgrading terminals and upgrades successfully, and goes to the 4th step; If do not conform to, main website does not record current upgrading terminals file transfer extremely and goes to the 4th step.
Above-mentioned optimal technical scheme is that applicant draws through further going deep into practical studies, can effectively guarantee the security of whole program upgrade file, can feed back in time the abnormal acquisition terminal of upgrading, be convenient to overhaul in time targetedly.
Preferably, also comprise and be positioned at first step main website preparation process before, the detailed process of described main website preparation process is as follows:
C1. inquire about acquisition terminal program version, list the acquisition terminal of needs upgrading in upgrading terminals inventory;
C2. option program upgrade file, draws whole file verification data by described whole file verification algorithm; By program upgrade file division, be some frame blocks of files, and by described single frames checking algorithm, draw the single frames checking data of each frame blocks of files;
C3. the acquisition terminal communication channel in upgrading terminals inventory is switched to update channel; Go to the first step;
The detailed process of the described first step is: it is current upgrading terminals that an acquisition terminal is selected in upgrading terminals inventory by main website;
Also comprise and be positioned at the 4th step main website subsequent processing steps afterwards, the detailed process of described main website subsequent processing steps is as follows: each acquisition terminal program version in inquiry upgrading terminals inventory, and contrast with the version of this program upgrade file, it is that upgrade status is abnormal that version is contrasted to inconsistent acquisition terminal state recording, version is contrasted to consistent acquisition terminal communication channel and switch to information acquisition channel.
Above-mentioned optimal technical scheme is that applicant draws through further going deep into practical studies, can make whole remote upgrade procedure robotization, procedure process, thereby further significantly reduce equipment operation maintenance personnel's workload, improve the work efficiency of acquisition terminal remote upgrade.
Accompanying drawing explanation
Fig. 1 is the main process schematic diagram of the embodiment of the present invention.
Embodiment
With reference to the accompanying drawings and in conjunction with the embodiments the present invention is described in further detail.But the invention is not restricted to given example.
Embodiment
As shown in Figure 1, the user power utilization information acquisition terminal remote upgrade method of the present embodiment, comprises the following steps:
Main website preparation process:
C1. inquire about acquisition terminal program version, list the acquisition terminal of needs upgrading in upgrading terminals inventory;
C2. option program upgrade file, draws whole file verification data by described whole file verification algorithm; By program upgrade file division, be some frame blocks of files, and by described single frames checking algorithm, draw the single frames checking data of each frame blocks of files;
C3. the acquisition terminal communication channel in upgrading terminals inventory is switched to update channel; Go to the first step.
It is current upgrading terminals that an acquisition terminal is selected in upgrading terminals inventory by the first step, main website.
Second step, main website send each frame blocks of files and the single frames checking data that through single frames checking algorithm draw corresponding with each frame blocks of files being formed by whole program upgrade file division in advance frame by frame to current upgrading terminals; Current upgrading terminals is by each frame blocks of files of described single frames checking algorithm verification;
Detailed process is as follows:
A1. initialization: make frame pointer k=1, make frame re-transmission frequency n=0;
A2. main website sends k frame blocks of files to current upgrading terminals, and sends the single frames checking data drawing through single frames checking algorithm corresponding with k frame blocks of files;
A3. current upgrading terminals is calculated the single frames checking data of k frame blocks of files by described single frames checking algorithm, and judges whether to conform to the single frames checking data of receiving; If the current upgrading terminals that conforms to is returned to successfully message to main website, main website records current upgrading terminals and has downloaded k frame blocks of files, goes to A4; If the current upgrading terminals that do not conform to is returned to re-send request may to main website, main website makes frame re-transmission frequency n=n+1, and judges whether n is greater than predetermined value, if main website records the verification of current upgrading terminals k frame blocks of files extremely and goes to the 4th step, goes to if not A2;
A4. make frame pointer k=k+1, the whether all frame blocks of files of main station judging are sent, if go to the 3rd step, go to if not A2.
San Bu, main website sends the whole file verification data that through whole file verification algorithm draw corresponding with whole program upgrade file to current upgrading terminals; Current upgrading terminals is by the whole program upgrade file of described whole file verification algorithm verification;
Detailed process is as follows:
B1. main website sends the whole file verification data that through whole file verification algorithm draw corresponding with whole program upgrade file to current upgrading terminals;
B2. current upgrading terminals is calculated the whole file verification data of whole program upgrade file by described whole file verification algorithm, and judges whether to conform to the whole file verification data of receiving; If conform to, go to B3; If do not conform to, main website does not record the whole file verification of current upgrading terminals extremely and goes to the 4th step;
B3. current upgrading terminals is carried out to reset and is restarted action, and program upgrade file is transferred to formal application area from temporary storage area, then by described whole file verification algorithm, calculate the whole file verification data of whole program upgrade file, and judge whether to conform to the whole file verification data of receiving; If conform to, main website records current upgrading terminals and upgrades successfully, and goes to the 4th step; If do not conform to, main website does not record current upgrading terminals file transfer extremely and goes to the 4th step.
The 4th step, current upgrading terminals upgrading processing finish; The whether all acquisition terminal upgrading processing of main station judging finish, and to select if not next acquisition terminal be current upgrading terminals and go to second step, if remote upgrade finishes.
Main website subsequent processing steps: each acquisition terminal program version in inquiry upgrading terminals inventory, and contrast with the version of this program upgrade file, it is that upgrade status is abnormal that version is contrasted to inconsistent acquisition terminal state recording, version is contrasted to consistent acquisition terminal communication channel and switch to information acquisition channel.
Wherein, in second step, as follows for the single frames checking algorithm detailed process of each frame blocks of files:
S1. initialization: making variable W_CRC is 16 bits, each bit value is zero; Make data pointer i=1;
S2. get 8, the left side of variable W_CRC and be saved to variable W_CRC1; Get 8, the right of variable W_CRC and be saved to variable W_CRC2;
S3. read the i byte data of present frame blocks of files, and these data and variable W_CRC2 are carried out to XOR, income value is N;
S4. the numerical value of the N order in password table and variable W_CRC1 are carried out to XOR, income value is saved to variable W_CRC; Password table by least 256 >=0x0 and≤the sexadecimal numerical value predetermined order of 0xffff forms; The initial order of password table is numbered zero;
S5. make data pointer i=i+1, judge whether present frame blocks of files reads complete, if go to S6, go to if not S2;
S6. the numerical value negate to variable W_CRC, obtains the single frames checking data of present frame blocks of files.
For ease of understanding single frames checking algorithm, lift an application example:
Certain frame blocks of files is containing two byte datas, and the 1st byte data is that 10110011, the 2 byte datas are 01011010.Move to left as logical shift left, move to right as logical shift right.
Password table is as shown in the table, contains 256 sexadecimal numerical value, and order is also with sexadecimal numeric representation:
Order | 00 | 01 | 02 | 03 | 04 | 05 | 06 | 07 | 08 | 09 |
Numerical value | 0x0000 | 0x365e | 0x6cbc | 0x5ae2 | 0xd978 | 0xef26 | 0xb5c4 | 0x839a | 0xff89 | 0xc9d7 |
Order | 0A | 0B | 0C | 0D | 0E | 0F | 10 | 11 | 12 | 13 |
Numerical value | 0x9335 | 0xa56b | 0x26f1 | 0x10af | 0x4a4d | 0x7c13 | 0xb26b | 0x8435 | 0xded7 | 0xe889 |
Order | 14 | 15 | 16 | 17 | 18 | 19 | 1A | 1B | 1C | 1D |
Numerical value | 0x6b13 | 0x5d4d | 0x07af | 0x31f1 | 0x4de2 | 0x7bbc | 0x215e | 0x1700 | 0x949a | 0xa2c4 |
Order | 1E | 1F | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 |
Numerical value | 0xf826 | 0xce78 | 0x29af | 0x1ff1 | 0x4513 | 0x734d | 0xf0d7 | 0xc689 | 0x9c6b | 0xaa35 |
Order | 28 | 29 | 2A | 2B | 2C | 2D | 2E | 2F | 30 | 31 |
Numerical value | 0xd626 | 0xe078 | 0xba9a | 0x8cc4 | 0x0f5e | 0x3900 | 0x63e2 | 0x55bc | 0x9bc4 | 0xad9a |
Order | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 3A | 3B |
Numerical value | 0xf778 | 0xc126 | 0x42bc | 0x74e2 | 0x2e00 | 0x185e | 0x644d | 0x5213 | 0x08f1 | 0x3eaf |
Order | 3C | 3D | 3E | 3F | 40 | 41 | 42 | 43 | 44 | 45 |
Numerical value | 0xbd35 | 0x8b6b | 0xd189 | 0xe7d7 | 0x535e | 0x6500 | 0x3fe2 | 0x09bc | 0x8a26 | 0xbc78 |
Order | 46 | 47 | 48 | 49 | 4A | 4B | 4C | 4D | 4E | 4F |
Numerical value | 0xe69a | 0xd0c4 | 0xacd7 | 0x9a89 | 0xc06b | 0xf635 | 0x75af | 0x43f1 | 0x1913 | 0x2f4d |
Order | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 |
Numerical value | 0xe135 | 0xd76b | 0x8d89 | 0xbbd7 | 0x384d | 0x0e13 | 0x54f1 | 0x62af | 0x1ebc | 0x28e2 |
Order | 5A | 5B | 5C | 5D | 5E | 5F | 60 | 61 | 62 | 63 |
Numerical value | 0x7200 | 0x445e | 0xc7c4 | 0xf19a | 0xab78 | 0x9d26 | 0x7af1 | 0x4caf | 0x164d | 0x2013 |
Order | 64 | 65 | 66 | 67 | 68 | 69 | 6A | 6B | 6C | 6D |
Numerical value | 0xa389 | 0x95d7 | 0xcf35 | 0xf96b | 0x8578 | 0xb326 | 0xe9c4 | 0xdf9a | 0x5c00 | 0x6a5e |
Order | 6E | 6F | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 |
Numerical value | 0x30bc | 0x06e2 | 0xc89a | 0xfec4 | 0xa426 | 0x9278 | 0x11e2 | 0x27bc | 0x7d5e | 0x4b00 |
Order | 78 | 79 | 7A | 7B | 7C | 7D | 7E | 7F | 80 | 81 |
Numerical value | 0x3713 | 0x014d | 0x5baf | 0x6df1 | 0xee6b | 0xd835 | 0x82d7 | 0xb489 | 0xa6bc | 0x90e2 |
Order | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 8A | 8B |
Numerical value | 0xca00 | 0xfc5e | 0x7fc4 | 0x499a | 0x1378 | 0x2526 | 0x5935 | 0x6f6b | 0x3589 | 0x03d7 |
Order | 8C | 8D | 8E | 8F | 90 | 91 | 92 | 93 | 94 | 95 |
Numerical value | 0x804d | 0xb613 | 0xecf1 | 0xdaaf | 0x14d7 | 0x2289 | 0x786b | 0x4e35 | 0xcdaf | 0xfbf1 |
Order | 96 | 97 | 98 | 99 | 9A | 9B | 9C | 9D | 9E | 9F |
Numerical value | 0xa113 | 0x974d | 0xeb5e | 0xdd00 | 0x87e2 | 0xb1bc | 0x3226 | 0x0478 | 0x5e9a | 0x68c4 |
Order | A0 | A1 | A2 | A3 | A4 | A5 | A6 | A7 | A8 | A9 |
Numerical value | 0x8f13 | 0xb94d | 0xe3af | 0xd5f1 | 0x566b | 0x6035 | 0x3ad7 | 0x0c89 | 0x709a | 0x46c4 |
Order | AA | AB | AC | AD | AE | AF | B0 | B1 | B2 | B3 |
Numerical value | 0x1c26 | 0x2a78 | 0xa9e2 | 0x9fbc | 0xc55e | 0xf300 | 0x3d78 | 0x0b26 | 0x51c4 | 0x679a |
Order | B4 | B5 | B6 | B7 | B8 | B9 | BA | BB | BC | BD |
Numerical value | 0xe400 | 0xd25e | 0x88bc | 0xbee2 | 0xc2f1 | 0xf4af | 0xae4d | 0x9813 | 0x1b89 | 0x2dd7 |
Order | BE | BF | C0 | C1 | C2 | C3 | C4 | C5 | C6 | C7 |
Numerical value | 0x7735 | 0x416b | 0xf5e2 | 0xc3bc | 0x995e | 0xaf00 | 0x2c9a | 0x1ac4 | 0x4026 | 0x7678 |
Order | C8 | C9 | CA | CB | CC | CD | CE | CF | D0 | D1 |
Numerical value | 0x0a6b | 0x3c35 | 0x66d7 | 0x5089 | 0xd313 | 0xe54d | 0xbfaf | 0x89f1 | 0x4789 | 0x71d7 |
Order | D2 | D3 | D4 | D5 | D6 | D7 | D8 | D9 | DA | DB |
Numerical value | 0x2b35 | 0x1d6b | 0x9ef1 | 0xa8af | 0xf24d | 0xc413 | 0xb800 | 0x8e5e | 0xd4bc | 0xe2e2 |
Order | DC | DD | DE | DF | E0 | E1 | E2 | E3 | E4 | E5 |
Numerical value | 0x6178 | 0x5726 | 0x0dc4 | 0x3b9a | 0xdc4d | 0xea13 | 0xb0f1 | 0x86af | 0x0535 | 0x336b |
Order | E6 | E7 | E8 | E9 | EA | EB | EC | ED | EE | EF |
Numerical value | 0x6989 | 0x5fd7 | 0x23c4 | 0x159a | 0x4f78 | 0x7926 | 0xfabc | 0xcce2 | 0x9600 | 0xa05e |
Order | F0 | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 |
Numerical value | 0x6e26 | 0x5878 | 0x029a | 0x34c4 | 0xb75e | 0x8100 | 0xdbe2 | 0xedbc | 0x91af | 0xa7f1 |
Order | FA | FB | FC | FD | FE | FF | ? | ? | ? | ? |
Numerical value | 0xfd13 | 0xcb4d | 0x48d7 | 0x7e89 | 0x246b | 0x1235 | ? | ? | ? | ? |
The single frames checking data computation process of this frame blocks of files is as follows:
(1) carry out S1. variable W_CR=00000000 00000000; I=1;
(2) carry out S2. variable W_CRC1=00000000 00000000, variable W_CRC2=0000000000000000;
(3) carry out the 1st byte data=10110011 of S3. present frame blocks of files, 0000000010110011, these data and variable W_CRC2 are carried out to XOR, income value N=0000000010110011=0x00B3;
(4) in execution S4. password table, the numerical value of 0x00B3 order is 0x679a=0110011110011010, and this numerical value and variable W_CRC1 are carried out to XOR, and income value=0110011110011010, preserves, and variable W_CRC=01100111 10011010;
(5) carry out S5.i=i+1=2, present frame blocks of files not yet reads complete, goes to S2;
(6) carry out S2. variable W_CRC1=00000000 01100111 (0x0067), variable W_CRC2=00000000 10011010 (0x009a);
(7) carry out the 2nd byte data=01011010 of S3. present frame blocks of files, 0000000001011010, these data and variable W_CRC2 are carried out to XOR, income value N=0000000011000000=0x00C0;
(8) in execution S4. password table, the numerical value of 0x00C0 order is 0xf5e2=1111010111100010, and this numerical value and variable W_CRC1 are carried out to XOR, and income value=1111010110000101, preserve, and variable W_CRC=11110101 10000101;
(9) carry out S5.i=i+1=3, present frame blocks of files has read complete, goes to S6;
(10) carry out the numerical value negate of S6. to variable W_CRC, obtain single frames checking data=00,001,010 01111010 of present frame blocks of files.
In addition, in the 3rd step, as follows for the whole file verification algorithm detailed process of whole program upgrade file:
T1. initialization: making variable W_CS is 32 bits, each bit value is zero; Make data pointer j=1;
T2. the i byte data of fetch program upgrade file, and these data and variable W_CS are done sums and computing, income value is saved to variable W_CS;
T3. make data pointer j=j+1, it is complete whether determining program upgrade file reads, if go to T4, goes to if not T2;
T4. the numerical value of variable W_CS is the whole file verification data of whole program upgrade file.
The present embodiment can be applicable in user power utilization information acquisition system, utilize the power communication network having built up in system, on existing power information acquisition system function basis, automatically realize the remote upgrade maintenance work to on-site terminal equipment, make on-site terminal equipment realize long-range increase function, optimization system design, solve the user's request of constantly updating, thoroughly overcome the defect of traditional upgrade method, save a large amount of manpower and materials.
In addition to the implementation, the present invention can also have other embodiments.All employings are equal to the technical scheme of replacement or equivalent transformation formation, all drop on the protection domain of requirement of the present invention.
Claims (6)
1. a user power utilization information acquisition terminal remote upgrade method, is characterized in that, comprises the following steps:
It is current upgrading terminals that an acquisition terminal is selected by the first step, main website;
Second step, main website send each frame blocks of files and the single frames checking data that through single frames checking algorithm draw corresponding with each frame blocks of files being formed by whole program upgrade file division in advance frame by frame to current upgrading terminals; Current upgrading terminals is by each frame blocks of files of described single frames checking algorithm verification;
San Bu, main website sends the whole file verification data that through whole file verification algorithm draw corresponding with whole program upgrade file to current upgrading terminals; Current upgrading terminals is by the whole program upgrade file of described whole file verification algorithm verification;
The 4th step, current upgrading terminals upgrading processing finish; The whether all acquisition terminal upgrading processing of main station judging finish, and to select if not next acquisition terminal be current upgrading terminals and go to second step, if remote upgrade finishes.
2. user power utilization information acquisition terminal remote upgrade method according to claim 1, is characterized in that, in second step, as follows for the single frames checking algorithm detailed process of each frame blocks of files:
S1. initialization: making variable W_CRC is 16 bits, each bit value is zero; Make data pointer i=1;
S2. get 8, the left side of variable W_CRC and be saved to variable W_CRC1; Get 8, the right of variable W_CRC and be saved to variable W_CRC2;
S3. read the i byte data of present frame blocks of files, and these data and variable W_CRC2 are carried out to XOR, income value is N;
S4. the numerical value of the N order in password table and variable W_CRC1 are carried out to XOR, income value is saved to variable W_CRC; Described password table by least 256 >=0x0 and≤the sexadecimal numerical value predetermined order of 0xffff forms; The initial order of described password table is numbered zero;
S5. make data pointer i=i+1, judge whether present frame blocks of files reads complete, if go to S6, go to if not S2;
S6. the numerical value negate to variable W_CRC, obtains the single frames checking data of present frame blocks of files.
3. user power utilization information acquisition terminal remote upgrade method according to claim 2, is characterized in that, in the 3rd step, as follows for the whole file verification algorithm detailed process of whole program upgrade file:
T1. initialization: making variable W_CS is 32 bits, each bit value is zero; Make data pointer j=1;
T2. the i byte data of fetch program upgrade file, and these data and variable W_CS are done sums and computing, income value is saved to variable W_CS;
T3. make data pointer j=j+1, it is complete whether determining program upgrade file reads, if go to T4, goes to if not T2;
T4. the numerical value of variable W_CS is the whole file verification data of whole program upgrade file.
4. according to user power utilization information acquisition terminal remote upgrade method described in claim 1 or 2 or 3, it is characterized in that, the detailed process of second step is as follows:
A1. initialization: make frame pointer k=1, make frame re-transmission frequency n=0;
A2. main website sends k frame blocks of files to current upgrading terminals, and sends the single frames checking data drawing through single frames checking algorithm corresponding with k frame blocks of files;
A3. current upgrading terminals is calculated the single frames checking data of k frame blocks of files by described single frames checking algorithm, and judges whether to conform to the single frames checking data of receiving; If the current upgrading terminals that conforms to is returned to successfully message to main website, main website records current upgrading terminals and has downloaded k frame blocks of files, goes to A4; If the current upgrading terminals that do not conform to is returned to re-send request may to main website, main website makes frame re-transmission frequency n=n+1, and judges whether n is greater than predetermined value, if main website records the verification of current upgrading terminals k frame blocks of files extremely and goes to the 4th step, goes to if not A2;
A4. make frame pointer k=k+1, the whether all frame blocks of files of main station judging are sent, if go to the 3rd step, go to if not A2.
5. user power utilization information acquisition terminal remote upgrade method according to claim 4, is characterized in that, the detailed process of the 3rd step is as follows:
B1. main website sends the whole file verification data that through whole file verification algorithm draw corresponding with whole program upgrade file to current upgrading terminals;
B2. current upgrading terminals is calculated the whole file verification data of whole program upgrade file by described whole file verification algorithm, and judges whether to conform to the whole file verification data of receiving; If conform to, go to B3; If do not conform to, main website does not record the whole file verification of current upgrading terminals extremely and goes to the 4th step;
B3. current upgrading terminals is carried out to reset and is restarted action, and program upgrade file is transferred to formal application area from temporary storage area, then by described whole file verification algorithm, calculate the whole file verification data of whole program upgrade file, and judge whether to conform to the whole file verification data of receiving; If conform to, main website records current upgrading terminals and upgrades successfully, and goes to the 4th step; If do not conform to, main website does not record current upgrading terminals file transfer extremely and goes to the 4th step.
6. user power utilization information acquisition terminal remote upgrade method according to claim 5, is characterized in that, also comprises the main website preparation process being positioned at before the first step, and the detailed process of described main website preparation process is as follows:
C1. inquire about acquisition terminal program version, list the acquisition terminal of needs upgrading in upgrading terminals inventory;
C2. option program upgrade file, draws whole file verification data by described whole file verification algorithm; By program upgrade file division, be some frame blocks of files, and by described single frames checking algorithm, draw the single frames checking data of each frame blocks of files;
C3. the acquisition terminal communication channel in upgrading terminals inventory is switched to update channel; Go to the first step;
The detailed process of the described first step is: it is current upgrading terminals that an acquisition terminal is selected in upgrading terminals inventory by main website;
Also comprise and be positioned at the 4th step main website subsequent processing steps afterwards, the detailed process of described main website subsequent processing steps is as follows: each acquisition terminal program version in inquiry upgrading terminals inventory, and contrast with the version of this program upgrade file, it is that upgrade status is abnormal that version is contrasted to inconsistent acquisition terminal state recording, version is contrasted to consistent acquisition terminal communication channel and switch to information acquisition channel.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310471577.6A CN103530153B (en) | 2013-10-11 | 2013-10-11 | User power utilization information acquisition terminal remote upgrade method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310471577.6A CN103530153B (en) | 2013-10-11 | 2013-10-11 | User power utilization information acquisition terminal remote upgrade method |
Publications (2)
Publication Number | Publication Date |
---|---|
CN103530153A true CN103530153A (en) | 2014-01-22 |
CN103530153B CN103530153B (en) | 2016-08-17 |
Family
ID=49932193
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201310471577.6A Active CN103530153B (en) | 2013-10-11 | 2013-10-11 | User power utilization information acquisition terminal remote upgrade method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN103530153B (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104049996A (en) * | 2014-05-29 | 2014-09-17 | 湖北三江航天红峰控制有限公司 | Method for carrying out software updating of missile-borne computer based on serial port |
CN106453642A (en) * | 2016-11-28 | 2017-02-22 | 国网四川省电力公司眉山供电公司 | Linux dynamic link library-based method of rapidly upgrading electric energy data acquire terminal |
CN109032644A (en) * | 2018-07-27 | 2018-12-18 | 蔚来汽车有限公司 | The upgrade method and device, controller and medium of charging pile, the pile group that charges |
CN112491954A (en) * | 2020-10-22 | 2021-03-12 | 浙江晨泰科技股份有限公司 | Intelligent ammeter upgrading method |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN201345041Y (en) * | 2008-09-11 | 2009-11-11 | 周庆民 | Field data acquisition terminal capable of upgrading programs remotely |
CN102541604A (en) * | 2011-12-29 | 2012-07-04 | 深圳市共进电子股份有限公司 | Remote upgrading method, remote upgrading terminal equipment and remote upgrading system |
CN202404574U (en) * | 2011-12-20 | 2012-08-29 | 郑州伊海电气设备有限公司 | Electric energy collecting terminal with remote upgrade function |
CN102857380A (en) * | 2012-09-18 | 2013-01-02 | 珠海中慧微电子有限公司 | Remote upgrading method for power line carrier communication routing |
CN202838671U (en) * | 2012-09-10 | 2013-03-27 | 江阴长仪集团有限公司 | Centralized meter reading terminal supporting remote upgrade and information two-way transmission |
-
2013
- 2013-10-11 CN CN201310471577.6A patent/CN103530153B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN201345041Y (en) * | 2008-09-11 | 2009-11-11 | 周庆民 | Field data acquisition terminal capable of upgrading programs remotely |
CN202404574U (en) * | 2011-12-20 | 2012-08-29 | 郑州伊海电气设备有限公司 | Electric energy collecting terminal with remote upgrade function |
CN102541604A (en) * | 2011-12-29 | 2012-07-04 | 深圳市共进电子股份有限公司 | Remote upgrading method, remote upgrading terminal equipment and remote upgrading system |
CN202838671U (en) * | 2012-09-10 | 2013-03-27 | 江阴长仪集团有限公司 | Centralized meter reading terminal supporting remote upgrade and information two-way transmission |
CN102857380A (en) * | 2012-09-18 | 2013-01-02 | 珠海中慧微电子有限公司 | Remote upgrading method for power line carrier communication routing |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104049996A (en) * | 2014-05-29 | 2014-09-17 | 湖北三江航天红峰控制有限公司 | Method for carrying out software updating of missile-borne computer based on serial port |
CN106453642A (en) * | 2016-11-28 | 2017-02-22 | 国网四川省电力公司眉山供电公司 | Linux dynamic link library-based method of rapidly upgrading electric energy data acquire terminal |
CN109032644A (en) * | 2018-07-27 | 2018-12-18 | 蔚来汽车有限公司 | The upgrade method and device, controller and medium of charging pile, the pile group that charges |
CN112491954A (en) * | 2020-10-22 | 2021-03-12 | 浙江晨泰科技股份有限公司 | Intelligent ammeter upgrading method |
Also Published As
Publication number | Publication date |
---|---|
CN103530153B (en) | 2016-08-17 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN102982141B (en) | A kind of method and device realizing distributed data base agency | |
CN103218398B (en) | Intelligent substation SCL (substation configuration description language) file difference comparison method | |
CN106447236A (en) | Electric energy meter file management method and system of power utilization information acquisition system | |
CN103530153A (en) | Remote updating method of user electricity utilization information collecting terminals | |
CN105224351A (en) | Rapid configuration implementation method and rapid configuration server | |
CN103605020B (en) | The treatment process of a kind of power quality data and device | |
CN112650520B (en) | Ammeter upgrading method and system, intelligent ammeter and storage medium | |
CN107332688B (en) | Graph database-based modeling method and device for electric power information communication system | |
CN103516529A (en) | Management method, device and system of configuration files | |
CN102800033A (en) | Distribution production and marketing business integration system | |
EP2897401B1 (en) | Method and device for guaranteeing consistency of planning data | |
CN108228740A (en) | Electric power full-service uniform data centre data analysis domain comparing tool | |
CN103997523A (en) | Smart city service system based on cloud services and implementation method thereof | |
CN104754629A (en) | Self-recovery implementing method and device for base station device | |
CN105186690A (en) | Remote operation method for constant value of relay protection device | |
CN105472412A (en) | Big data processing method capable of distinguishing state of intelligent television | |
CN104581690A (en) | Network access implementing method of intelligent card, wireless card-writing platform and intelligent card | |
CN101860535A (en) | Method and system for managing digital certificates of home gateways | |
CN108011870B (en) | A kind of remote software online upgrading information automatic identification management method | |
CN101702211A (en) | Supporting verification method for account table data of electric transmission and transformation equipment | |
CN102523620B (en) | Method, device and system for data synchronism | |
CN105260401A (en) | Method and device for querying and storing electric data | |
CN112468317A (en) | Cluster topology updating method, system, equipment and computer storage medium | |
CN105872013A (en) | Cloud computing system | |
CN103929763A (en) | Method for comparison and reconstruction of geographic redundancy database |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant | ||
PP01 | Preservation of patent right | ||
PP01 | Preservation of patent right |
Effective date of registration: 20240204 Granted publication date: 20160817 |