Skip to Main Content
Supporting remote dynamic update on wireless sensor networks (WSNs) allows software of sensor nodes to be dynamically updated or enhanced to adapt to changed environmental conditions or application requirements. Many researches use diff-based approaches to transmit only the code difference to sensor nodes for updating. For the resource-limited WSNs, we have proposed a new diff-based approach named Two-Stage Diff to dynamically update software components effectively in sensor nodes. By using some carefully designed methods to increase the similarities between the old and the new program images, our mechanism can obtain much smaller code difference than traditional diff-based approaches. Besides, flash memory characteristics in erasing and writing data are considered in designing the file format of transmitted update data. Thus, the transmission size of the updated data can be greatly reduced. Especially, our sensor nodes only need to perform simple work instead of complicated dynamic linking in updating program image. As a result, our mechanism can incur less resource consumption and be more suitable for operating in resource-limited WSNs. Experiments with Tiny OS show that our Two-Stage Diff can effectively reduce the size of transmitted update data and the update processing time can be significantly reduced as well.