## 9 Conclusions  
In this work, two new methods to obtain a more precise clock skew based on temperature for synchronization protocols in WSNs have been proposed. Oscillators are highly influenced by temperature changes. The influence of temperature variations in synchronization protocols has been demonstrated using the Flooding Time Synchronization Protocol (FTSP). The obtained results clearly show the influence of temperature and reveal the necessity of creating new synchronization approaches based on temperature. Taking into account temperature variations in the clock skew estimation, two new FTSP-based approaches have been developed and tested: AT-FTSP and A2T-FTSP. Both approaches use the tuning-fork equation to determine the real frequency of the oscillator according to the ambient temperature. With this information, the clock skew estimation is improved to obtain a more precise value, minimizing the effects due to temperature. Several tests have been carried out to determine the performance under different temperature variations. The experimental results with the new proposals reveal a great improvement in terms of average synchronization error. The following lines summarize the results of the tests:* Taking into account the temperature in the computation of the clock skew minimizes the error due to frequency variations. This work has shown the reliability of the new proposed temperature methods for a large range of temperatures (from \(9\,^{\circ}\)C to \(40\,^{\circ}\)C). * Using the new temperature-based methods in the range of temperature from \(9\,^{\circ}\)C to \(22\,^{\circ}\)C permit one to improve the average synchronization error. AT-FTSP provides an average synchronization error of \(1.558\)\(\mu\)s and A2T-FTSP gets about \(1.459\)\(\mu\)s. These results mean an improvement between \(104.17\)% and \(118\)%. * For the temperature interval, \(22\,^{\circ}\)C-\(32^{\circ}\)C, the behavior differences between the new proposals are minimal. This is mainly due to the thermal interval used, which is really close to the nominal frequency of the _CMR200T_ oscillator (\(25\,^{\circ}\)C). As a consequence, the frequency variations are minimal, obtaining similar results between the new methods. For the above-mentioned interval, AT-FTSP and A2T-FTSP improve about \(55.60\%\) (\(2.302\)\(\mu\)s) and \(109.22\%\) (\(1.706\)\(\mu\)s) compared to FTSP (\(3.582\)\(\mu\)s). * High temperatures ranges largely penalize the good behavior of the synchronization mechanisms. This is a direct consequence of the big influence of heat. Once again, AT-FTSP and A2T-FTSP improve the average synchronization error, obtaining \(159.40\%\) (\(2.685\)\(\mu\)s) and \(184.86\%\) (\(1.349\)\(\mu\)s) with respect to FTSP (\(7.432\)\(\mu\)s). The new methods improve other proposals based on temperature. In order to compare to other temperature-based proposals (EACS and TCTS), results in terms of tics and ppm for \(<\)95\(\%\) of the errors have been obtained. In tics, AT-FTSP and AT2-FTSP offer similar results (\(\pm 6.74\) and \(\pm 4.16\) tics, respectively) to the TCTS proposal (\(\pm 4.16\)). Besides, the results in ppm show a clear improvement of AT-FTSP and AT2-FTSP (\(0.31\) and \(0.19\) ppm, respectively) _versus_ EACS (\(8\) ppm) and TCTS (\(0.37\) ppm). The new methods have fewer computational costs and a better performance, which make them a suitable option to be used in WSNs. Furthermore, it is worth noting that all the obtained results come from real-world experiments and not from simulations. To summarize the above lines, the main contributions of this article are below:  
* The proposed methods can be applied in any synchronization protocol based on the clock skew concept. * The average synchronization error can be improved, taking into account the temperature. The increase of source code lines is minimal compared to the benefits obtained in terms of synchronization.