Spacecraft Attitude Determination: A Magnetometer Approach