The use of sensor networks should keep developing, mainly in such fields as scientific, logistic, military or healthcare applications. However, sensor size represents a significant limitation mainly in terms of energy autonomy and therefore of life period, for the batteries have to be too tiny. This is the reason why intensive research is being conducted nowadays on how to control sensor energy consumption within a network, taking communications into account as a priority. For this purpose we have proposed a method to calculate energy consumption within the wireless sensor networks, according to the number of information packets sent, the number of nodes. Furthermore, we have succeeded in reducing energy consumption within the sensor networks made up with nodes featuring differing data flow rates.