The role of the auroral ionosphere in magnetospheric substorms