2D magnetic field of a device used in the micropump of capsule endoscope is analyzed and calculated. Magnetic torque is simulated when the coils and permanent magnet are in different relative positions. The torque is calculated too when strength of external rotational magnetic field is changed. Corresponding results provide theoretical guide to the design and development of device.