A switching circuit includes a first switch and a second switch respectively connecting a first terminal and a second terminal of an electrical coil to a positive terminal of a voltage source, a third switch and a fourth switch respectively connecting the first terminal and the second terminal of the electrical coil to a negative terminal of the voltage source, and a controller to control the switching circuit in a current control mode to alternate a voltage polarity of the voltage source to thereby control a magnitude and direction of the electrical current of the electrical coil, and to control the switching circuit in a current hold mode to disconnect the electrical coil from the voltage source and to short-circuit the electrical coil to maintain the magnitude and direction of the electrical current at the transition time when the switching circuit switched to the current hold mode.Circuit de commutation comprenant un premier commutateur et un deuxième commutateur connectant respectivement une première borne et une seconde borne d'une bobine électrique à une borne positive d'une source de tension, un troisième commutateur et un quatrième commutateur connectant respectivement la première borne et la seconde borne de la bobine électrique à une borne négative de la source de tension, et un dispositif de commande pour commander le circuit de commutation dans un mode commande de courant pour alterner une polarité de tension de la source de tension afin de commander une amplitude et une direction du courant électrique de la bobine électrique, et pour commander le circuit de commutation dans un mode maintien de courant afin de déconnecter la bobine électrique de la source de tension et de court-circuiter la bobine électrique dans le but de maintenir l'amplitude et la direction du courant électrique au moment de la transition lorsque le circuit de commutation passe au mode maintien de courant.