Some more code for range sensor support, needs more work