Added wall threshold and motor speed offsets.