A Nonlinear Magnetic Controller For Three-Axis Stability Of Nanosatellites