Energy-efficient and lifetime aware routing in WSNs