Font Size: a A A

Research On Wireless Sensor Networks Reprogramming Method Based On Code Difference

Posted on:2015-05-18Degree:MasterType:Thesis
Country:ChinaCandidate:Z L WangFull Text:PDF
GTID:2308330479975970Subject:Computer Science and Technology
Abstract/Summary:PDF Full Text Request
Wireless Sensor Networks(WSNs) is widely employed in environmental monitoring, military field and industrial control. In real-world WSNs, hundreds of sensor nodes are usually deployed. With the passage of time and the change of environment, the running nodes may need to reprogram to realize version update for a variety of reasons—adding or closing some functions, fixing bugs. The traditional manually updating way is inefficient, and even it cannot update some nodes which are deployed in the harsh environment or the human unreachable area. Therefore, the remote way to update each node via wireless communications is introduced by researchers. But usually, the updated part between the new version of code and the old version of code is far less than the new version of code. Considered the sensor resource limitation, when sensors are updated through wireless way, the size of disseminated code should be reduced, to improve the efficiency of reprogramming and reduce energy usage. In this paper, the incremental WSNs reprogramming are researched based on MeshSPAIS system, and the WSNs reprogramming method(Re PCCDT)and overall architecture are proposed based on code clone detection technology. Main works include:Firstly, two parts of WSNs reprogramming are studied in the code distribution protocol and the reprogramming way. And several kinds of typical reprogramming ways are analyzed emphatically, such as Deluge, Zephyr/Hermes, Elon, R2, to point out their some deficiency in the size of disseminated code and energy usage.Secondly, for a problem of the incremental WSNs reprogramming, the protection of the old and new version of the program code similarity, the BGIR method is proposed. The method deals with the effects of the change from four aspects of branch, global variables, indirect addresses and relative jumps, respectively, to increase the similarity of the old and new version of program. It prepares for the next patch generation algorithm to generate smaller difference patch(delta). And through theoretical analysis and case analysis, the method is proved that it can increase the similarity of the old and new version of program to reduce the size of delta.Thirdly, aiming at another problem of the incremental WSNs reprogramming, difference patch generation algorithm are proposed based on code clone detection technology(CCDTDiff). The code clone detection technology based on Token is introduced to delta generation algorithm. Then, find common segments of the new and old version of program code, generate the smallest patch used the design of differences patch calculation algorithms in this paper. The performance of the algorithm is analyzed from the execution efficiency and the size of delta two aspects.Finally, the overall architecture of the way based on code clone detection technology of WSNs reprogramming and Bootloader are designed. The overall architecture mainly includes three modules: delta generation, code distribution, rebuilding program image. The default Bootloader is improved to run the updated program via software restart. TOSSIM simulation experiment proves the feasibility of the architecture, delta generation module can generate the smallest patch to reduce the time of downloading codes and energy consumption in the process of reprogramming.
Keywords/Search Tags:WSNs, reprogramming, code clone detection, differential patch(delta)
PDF Full Text Request
Related items