Tilt Sensor BS2 code