Deorbiting, or returning to Earth, is pretty much the opposite of Orbit Insertion. You prepare your Shuttle by stowing all the mission-related items like the RMS, OBSS, KU Band Antenna, etc, and of course you have to close the payload bay doors. These are preparations to bring the vehicle safely back to Earth. Depending where on Earth you have to land, the Shuttle must reduce its velocity at a pre-calculated point in orbit. This reduction depends on the orbit parameters but is often around 200 ft/sec. For this maneuver the shuttle is turned into an attitude with the OMS nozzles pointing into the direction of the velocity which is virtually backwards. Because you are above the upper Earth`s atmosphere i.e. in space, there is no air friction and the rudder and elevons have no effect, so The Shuttle must perform a burn to change its orbit so that the Perigee is inside the Earth's Atmosphere.
The next milestone is descending through 400,000 ft, which is called “Entry Interface” (EI). This is the altitude where the first signs of the atmosphere will affect the flight path. From then on the "Angle Of Attack" (AOA or α) is kept at 40°. This attitude allows the speed to be reduced by drag (caused by the friction with the air). The same friction also generates a lot of heat. The black thermic tiles (the heat shield) on the Shuttle's underside are designed to absorb this heat and protect the vehicle. and the high AOA allows the more sensitive upper side to be “hidden” from the heat.
As the Shuttle descends through the Ionosphere at a very high velocity, its friction with the denser air generates enormous amounts of heat and the air becomes plasma. The electrons popping in and out of their orbits around the atom nucleus is what produces the distinct orange glow of the heat shield during re-entry of the Shuttle.
At some point down on the flightpath Shuttle starts to produce lift, the velocity is so high that just the angle of the shuttle is enough to produce a noticeable amount of lift. To prevent ditching and to manage the energy state the Shuttle is banked to one side quite steeply, but without reducing the AOA, it's a combined movement around all axes. Banking the Shuttle prevents the lift line from pointing up (and decreasing the sink rate) instead the lift is pointed sideways. The bank leads to a very slow course deviation. This allows the flight path to be lengthened in order to manage energy (the longer flight time allows more speed can be depleted by the high drag). Unfortunately, This causes the Shuttle to move off course and that needs to be corrected at some point, and this leads to a “roll reversal” - the Shuttle banks to the other side. Depending on the energy that is left there will be a few more rolls. Due to the shape of the generated flight path, these repeated turns/rolls are also known as “S turns”. Throughout the Entry the onboard computers keep track and constantly update the flight path and the required maneuvers are executed by the Digital Auto Pilot (DAP). The Commander or the Pilot usually leave the task to the computers but can take control if needed. The screenshot below shows the shuttle during a right “roll” and the arrows show the vectors of lift and velocity (movement). The angle α between the x-axis and the movement is the Angle of Attack. In reality it is not exactly the x-axis but for our understanding it is good enough. It should be clear now that the direction where the nose points to and the direction of movement are different things.
During Re-entry, the attitude is controlled by the rear RCSs first and, as the atmospheric pressure builds up, the aerodynamic surfaces join the attitude control. First the ailerons (for roll control) then elevators (Pitch) (Space Shuttle's ailerons and elevators are linked in what it is called “elevons”) and last is the rudder (yaw). Finally the air is dense enough to allow full aerodynamic control and the RCSs are inhibited. The Shuttle has now changed from a spaceship into a very heavy, fast flying glider.
Next is the TAEM flight phase.