A self-consistent field calculation of the single-particle orbitals in the sd shell is presented. The calculation is based on a standard shell-model Hamiltonian employing a single-particle spin-orbit force and two-body Yukawa interaction with a Rosenfeld exchange mixture. Using these orbitals the low-lying rotational spectra of the sd shell nuclei are computed. The variational formula of Skyrme and the cranking model yield moments of inertia which compare well with the experimental data. The rotation-particle coupling interaction is diagonalized and good fits to the nuclear rotational spectra are obtained.