code for orientation