Gastrointestinal motility is controlled by the nerves and muscles within the gastrointestinal tract.
Although the patterns of contraction and relaxation are complex, all the programming necessary for proper digestion is self-contained in the bowel wall. The normal patterns of the nerves and muscles are influenced every day by many factors. Sleeping and waking changes motility, as does exercise. Emotional distress can also have profound effects on gastrointestinal motility. Even the food that you eat releases substances into the blood which influence motility.