routing algorithm for shared sensor networks