Power Assignment Method for Wireless Sensor Networks