Abstract:
A control circuit for a reluctance machine having two mutually movable parts and at least one inductive phase winding adapted for a certain maximum drive current value. The method includes detecting when a phase winding is in a non-drive mode; causing a test current, having a second maximum value lower than said certain maximum value, to flow through the phase winding and through a current sensor when the winding is in the non-drive mode; and establishing a mutual position in dependence of the output of said current sensor.

Description:
FIELD OF THE INVENTION 
     The present invention relates to a control circuit for a reluctance machine and to a method of operating such a control circuit. 
     RELEVANT ART 
     Reluctance machines have two parts, which are movable in relation to each other, commonly called the “stator” and the “rotor”, respectively. The most common types of reluctance machines have a rotor that is suspended so that it can rotate inside a stator. The machine is provided with coils, which can be provided with electrical current so as to produce a magnetic flow. The rotor in combination with the stator form a magnetic circuit through which the magnetic field produced by the coils flows. 
     When the mutual position between the rotor and the stator changes then the reluctance in the magnetic circuit changes. 
     In order to drive a reluctance motor with a number of windings the current is connected to the windings in a way which depends upon the mutual position of the rotor and the stator. 
     A known way of providing this control of the current includes sensing the position of the rotor with the help of separate position sensors coupled to the rotor, whereby the position sensors produce an output signal which depends on the position of the rotor. 
     Another known way of achieving control of phase currents uses the fact that the inductance of a phase varies depending on the position of the rotor in relation to the stator. 
     The U.S. Pat. No. 5,043,643 describes a method of determining the position of the rotor for a reluctance machine starting from the equation 
     
       
         ( J−Ri )= d/dt ( Li ), 
       
     
     where i is the current through the phase windings, where U is the voltage across a series connection of the phase winding, a transistor valve and a current sensor resistor, and where R is a predetermined constant corresponding to the sum of the resistances in a phase winding, an activated transistor and a current measuring resistor. 
     SUMMARY OF THE INVENTION 
     The momentary inductance of a winding can be determined by providing a voltage pulse having a certain amplitude to a winding and measuring the current-time response. Hence, an inductance value can, for example, be calculated by measuring the amplitude of the current at a certain time after switching on the pulse. Alternatively an inductance value can be calculated by measuring the amount of time until a certain current amplitude has been reached. In both cases, however, the measurement involves the provision of voltage pulses to the winding. The provision of such voltage pulses with a certain repetition frequency may cause noise to be generated by vibrations in the components. 
     The present invention relates to the problem of improving the performance of a control circuit for a reluctance machine. 
     This problem is solved by a control circuit for a reluctance machine having two mutually movable parts and at least one inductive phase winding, the inductance of which depends on the mutual position of the parts; the control circuit comprising: 
     a first terminal and a second terminal for connection to a power source; 
     valve means for setting the winding in a drive mode so as to cause a drive current to flow through the winding, the drive current having a certain maximum value; and 
     means for establishing said mutual position in dependence of a measured current value and/or time value. According to an embodiment of the invention, the control circuit includes a current sensor for measurement of a test current when the winding is in a non-drive mode, the current sensor being adapted for measurement of test currents having a second maximum value lower than said certain maximum value; wherein 
     said position establishing means is adapted to establish said mutual position in dependence of said test current. 
     This solution advantageously enables position measurements using lower current amplitudes. The lower current amplitudes advantageously leads to reduced noise from the reluctance machine, since the noise level is closely connected with the current amplitudes. 
     Additionally the above solution enables more frequent current measurements, thereby improving the versatility of the control circuit. Since the position and the inductance value, using the above described control circuit, can be established with a lower current top value, the repetition frequency can also be increased. This is due to the fact that a lower top current value through the winding at the end of a voltage pulse corresponds to a lower amount of stored energy in the winding. Hence, the stored energy in the winding can be drained faster and a new measurement cycle can be initiated that much earlier. Thus the inductance measurement procedure can be used at a higher machine speed. According to referred embodiments the current measurement can have a repetition frequency of more than one kilo-hertz. Preferably the current measurement repetition frequency is higher than 1,5 kHz. 
     With a more frequent current measurement the inaccuracy of the resulting inductance determinations is also reduced, leading to more accurate position determination for a reluctance machine in motion. This positive effect is obtained since the shortened duration of the current measurement procedure, when the reluctance machine is in motion, leads to smaller movement of the rotor during the measurement procedure. Since the inductance is position dependent, the reduced rotor movement leads to reduced inductance change due to movement during the current measurement procedure. 
     Since the present current measurement solution makes it possible to perform the inductance-measurement using separate current sensors S 3   A , S 3   B , S 3   C  it is possible to use lower current values during the measurement for establishing the momentary inductance value of the winding. In other words the ratio between the maximum drive current and the maximum test current is increased. An increase of this ratio is advantageous since the test current may produce a negative torque when the test current flows through a winding which is in a non-drive mode. Hence, a high ratio between the maximum drive current and the maximum test current reduces the impact of any negative torque produced by the test current In effect, an increased ratio between the maximum drive current and the maximum test current renders improved performance of the reluctance machine. 
     According to an embodiment the control circuit operates to control the valves to prevent currents exceeding said second maximum value from flowing through the current sensor. The second maximum value may be 5 percent of the drive current maximum value. 
     The control circuit further comprises means for establishing a rate of change for the test current in response to said time value and said current value; said rate of change being indicative of the momentary inductance of the winding. The position establishing means is adapted to establish said mutual position in dependence of said rate of change. 
    
    
     BRIEF DESCRIPTION OF THE FIGURES 
     FIG. 1A is a schematical principle sketch of an electrical machine with two mutually movable parts and phase windings. 
     FIG. 1B illustrates a magnetic flow in the machine according to FIG.  1 A. 
     FIG. 2A illustrates that the inductance in a winding in a machine according to FIG. 1A varies, depending on the mutual position between the movable parts. 
     FIG. 2B illustrates the positional dependence of the torque which can be obtained by activating of a phase winding. 
     FIG. 3 illustrates a control apparatus with valve bridges connected to the phase windings in the motor according to FIG.  1 A. 
     FIG. 4A is an equivalent circuit diagram for one of the valve bridges of FIG.  3 . 
     FIG. 4B is an equivalent circuit diagram for another embodiment a valve bridge. 
     FIG. 5 is a flow chart illustrating an embodiment of a measurement procedure. 
     FIG. 6 is an equivalent circuit diagram for an alternative embodiment of a valve bridge. 
    
    
     DESCRIPTION OF PREFERRED EMBODIMENTS 
     For the sake of simplicity, the invention will be described in the following with reference to rotating machines. The invention is, however, not limited to rotating machines but that which is described is also applicable to other machines, such as e.g. linear machines where a moving part made of a soft magnetic material is linearly displaceable along a straight linear stator with a number of stator windings. The invention is applicable to a control circuit for a reluctance machine operating as a motor, but also to a control circuit for a reluctance machine operating as a generator 
     FIG. 1A is a schematic view illustrating an embodiment of a reluctance machine  10  with a stator  20  and a rotor  30  rotatable inside the stator. 
     The stator  20  is provided with three separate windings W A , W B  and W C , respectively. 
     According to one embodiment the rotor is manufactured from a soft magnetic material comprising a number of projections  40  as illustrated in FIG.  1 A. The soft magnetic material is a ferromagnetic material which, when it has been magnitized once, can very easily be demagnitized, i.e. only a small coercive power is required for removal of the magnetism which arose when the material was magnitized. According to one version of the invention the rotor comprises soft magnetic iron. According to one embodiment also the stator includes a soft magnetic material, such as e.g. soft magnetic iron. 
     When the rotor is turned around a central shaft, its position changes, which is illustrated by means of the angular position θ in FIG.  1 A. As illustrated in FIG. 1, an imaginary co-ordination system has its origin at the central shaft of the motor, with two mutually orthogonal axes x resp. y. The position of the rotor can then be defined as the angular position θ of a rotor projection  40  in relation to the x-axis. 
     When current is driven through a winding, e.g. winding W A , a magnetic flow which flows from the stator via the rotor and back to the stator is produced, and thereby a magnetic circuit is produced. FIG. 1B illustrates an example of such a magnetic circuit for a three-phase reluctance motor in the case that current would be driven through the winding W A  when the projection of the rotor is directed towards the parts of the stator where the magnetic field-producing windings W A  is placed. It should be noted that FIG. 1B only illustrates the principle for the magnetic flow and should not be interpreted such that the current necessarily must be driven through a winding when the rotor is in the position shown in FIG.  1 B. 
     The current to the phase windings of the motor should be controlled so that the current is supplied when the position of the rotor in relation to the stator is such that the torque of the motor is optimized. 
     FIGS. 1A and 1B illustrate a machine with three windings, the rotor of which has eight projections and the stator of which has twelve projections. According to a preferred embodiment the rotor, however, has four projections, so-called salient poles, and the stator has six projections. 
     FIG. 2A illustrates how the inductance varies in the winding W A  depending on the position θ of the rotor. 
     FIG. 2B illustrates the torque which can be obtained, in rotor position θ, by activation of a phase winding. By comparison of the curve illustrating the inductance L WA  for winding W A  with the curve illustrating the torque T WA  achieved by activation of the winding W A  (the solid lines in FIG.  2 A and FIG. 2B, respectively), it can be seen that a positive torque is obtained from the winding W A  if this winding is excited when the inductance has a positive derivative. 
     This means that during certain drive conditions, when a maximum torque is required in the forward direction, it is preferable to excite winding W A  such that a current flows through the winding while in rotor positions where T WA  has a positive value. In rotor positions where T WA  has a negative value winding W A  should preferably be unexcited, i.e. no drive current should flow through the winding at such positions. Likewise, windings W B  and W C  should be controlled to be excited or unexcited in the corresponding manner in respect of optimum torque T WB  and T WC , respectively. 
     An Embodiment of a Control Apparatus 
     FIG. 3 illustrates a control apparatus  60  connected to the three phase windings W A , W B  and W C . The control apparatus  60  comprises a power source  70  which supplies a DC-voltage with an amplitude of +U d  to a connection  80 . The phase winding W A  is coupled between the ground connection  90  of the voltage source and the plus pole  80  via a bridge circuit  85 A. 
     The bridge circuit  85 A comprises a first power transistor T 1   A  for coupling connection  80  to one end of the winding W A , and a second power transistor T 2   A  in series with a current sensor S 2   A  coupled between the other end of the winding and ground connection  90 , as shown in FIG. 3. A diode D 1   A , in series with a current sensor S 1   A , is connected between the ground connection  90  and the emitter of the transistor T 2A  such that the cathode of the diode is coupled to the emitter of the transistor T 1   A . A diode D 2   A  is connected so that its cathode is connected to the collector of the power transistor T 1   A  and its anode is coupled to the collector of the power transistor T 2   A . Additionally bridge  85 A comprises a series connection of a third transistor valve T 3   A  and a third current sensor S 3   A . The third transistor valve T 3   A  and the third current sensor S 3   A  are coupled in parallel with the second power transistor T 2   A  and second current sensor S 2   A . 
     Although described with reference to power transistors, an active valve T 1   A , T 2   A , T 3   A  may be constituted for example a bipolar transistor, a thyristor, an IGBT or a MOSFET. The passive valves D 1   A , D 2   A  may be constituted by diodes, such as e.g. SCHOTTKY-diodes. 
     The other phase windings W B  and W C , respectively, are coupled to bridge circuits  85 B and  85 C, respectively, in the same manner as the first winding W A . 
     A control unit  100  comprising a microprocessor is arranged to control the transistor valves. The control unit  100  has nine outputs which are connected each via its own amplifier  110  to the base of its own of the six transistor valves. The controller  100  may be embodied as a Digital Signal Processor (DSP) having a timer for so as to enable time measurements. 
     The current sensors S 1   A , S 2   A  and S 3   A  are, according to one embodiment, Hall sensors which supply measured current values to the control unit  100 . According to a preferred embodiment, however, the current sensors S 1   A , S 2   A  and S 3   A  comprise shunt resistors, and the current is measured as a voltage drop over the respective resistor. 
     The sensed signal, indicative of the current through the sensor S 2   A , is delivered to the control unit via a multiplexer  115 . Sensed signals from sensors S 1   A , and S 3   A  are delivered to respective inputs of the control unit  100  via the multiplexer in the same manner. The multiplexer operates to take samples of the measured currents from the three windings W A , W B , W C  in a controlled manner such that the control unit  100  can operate as if it had access to continuous measurement values. The multiplexer is controlled and synchronized by the control unit  100  to achieve this. 
     In the same way the measured current values for the windings W B  and W C  are supplied to the control unit  100 . 
     A sensor unit  120  is connected so that it senses the voltage U d  between the positive pole  80  and the ground connection  90 . The sensor unit  120  supplies a measured voltage value U dm  to the control unit  100 . The sensor unit  120  includes, according to one embodiment, a voltage divider with resistors R X  and R Y , which are connected between the positive voltage connection  80  and the ground connection  90 . As is illustrated in FIG. 3, the output of the sensor unit  120  is connected to a point  140  between the resistors R X  and R Y  so that the output signal U dm  of the sensor is proportional to the drive voltage U d . 
     Whereas sensors S 1   A , S 1   B , S 1   C  and sensors S 2   A , S 2   B , S 2   C  are primarily used for establishing whether or not any current flows through the relevant leg of the circuit, the sensors S 3   A , S 3   B , S 3   C  are used for establishing a momentary inductance in the relevant winding W A , W B , W C (cf FIG.  4 A). FIG. 4A is a circuit diagram illustrating the valve bridge  85 A for winding W A  in FIG.  3 . 
     With reference to FIG. 4B there is shown an alternative embodiment of a valve bridge. In that embodiment the drive currents may be measured with a Hall sensor S WA  connected in series with the winding W A . The Hall sensor thus replaces the current sensors S 1  and S 2  shown in FIG.  4 A. 
     Since the present current measurement solution makes it possible to perform the inductance-measurement using separate current sensors S 3   A , S 3   B , S 3   C  it will be possible to use lower current values during the measurement for establishing the momentary inductance value of the winding. In other words the ratio between the maximum drive current i Wmax  and the maximum test current i test     —     max  is increased. An increase of this ratio is advantageous since the test current may produce a negative torque (cf FIG. 2B) when the test current flows through a winding which is in a non-drive mode. Hence, the lower the test current in relation to the drive current, the better it is. 
     According to preferred embodiments of the invention the ratio between the maximum drive current i Wmax  and the maximum test current i test     —     max  is higher than 20. According to an embodiment of the invention the ratio between the maximum drive current i max  and the maximum test current i test     —     max  is 40 or higher. According to some embodiments the ratio is higher than 100. According to most preferred embodiments the ratio is 120 or higher. 
     The control apparatus  60  can be adapted for different working conditions and for different reluctance machines. The below first example relates to a control apparatus adapted for driving a reluctance machine with a high drive voltage Ud and a low motor power. 
     EXAMPLE 1A 
     Ud=300 Volts 
     i Wmax =3,0 Ampere 
     Inductance in windings W A , W B , W C  is position dependent within the approximate range 0,16 Henry to 1,6 Henry. 
     Resistance in sensors S 2   A , S 2   B , S 2   C  and in sensors S 1   A , S 1   B , S 1   C  is 50 milliOhms. 
     Resistance in current sensors S 3   A , S 3   B , S 3   C  is 100 Ohms. 
     Maximum test current through S 3   A , S 3   B , S 3   C  is 25 milliamperes. 
     The ratio between the maximum drive current i Wmax  and the maximum test current i test     —     max  is in this example: i Wmax /i test =120 
     Using this maximum test current the measurement procedure described with reference to FIG. 5 below can be repeated up to 3750 times per second (a repetition frequency of 3,75 kHz). 
     EXAMPLE 1B 
     Ud=300 Volts 
     i Wmax =3,0 Ampere 
     Inductance in windings W A , W B , W C  is position dependent within the approximate range 0,16 Henry to 1,6 Henry. 
     Resistance in sensors S 2   A , S 2   B , S 2   C  and in sensors S 1   A , S 1   B , S 1   C  is 50 milliOhms. 
     Resistance in current sensors S 3   A , S 3   B , S 3   C  is 100 Ohms. 
     Maximum test current through S 3   A , S 3   B , S 3   C  is 5 milliamperes. 
     The ratio between the maximum drive current i Wmax  and the maximum test current i test     —     max  is in this example: i Wmax /i test =600 
     Using this maximum test current, the measurement procedure described with reference to FIG. 5 below can be repeated up to 18750 times per second (a repetition frequency of 18,75 kHz). 
     EXAMPLE 2 
     An example of a control apparatus adapted for driving a reluctance machine with a low drive voltage Ud and a medium motor power has the following parameter values: 
     Ud=24 Volts 
     i Wmax =200 Amperes 
     Inductance in windings W A , W B , W C  is position dependent within the approximate range 1/12 milliHenry to 1 milliHenry. 
     A Hall sensor (FIG. 4B) adapted to enable measurement of currents up to 200 Amperes is used. 
     Resistance in current sensors S 3   A , S 3   B , S 3   C  is 1,0 Ohm. 
     Maximum test current through S 3   A , S 3   B , S 3   C  is 2 Amperes. Using this maximum test current, the measurement procedure described with reference to FIG. 5 below can be repeated more than 2500 times per second (a repetition frequency of more than 2500 Hz). According to a preferred embodiment the repetition frequency is about 6000 Hz). 
     The ratio between the maximum drive current i Wmax  and the maximum test current i test      —     max  is in this example: i Wmax /i test =100. 
     With reference to Example 2 it is to be noted that if a 1 Ohm shunt sensor were used instead of the Hall sensor the maximum drive current would be limited to 24 Amperes, and consequently it would not work. If, on the other hand, the Hall sensor (adapted to enable measurement of currents up to 200 A) were used for producing the measurement values for establishing the momentary inductance instead of using the sensor S 3 , the measurement current i test  would have to be larger, or the Hall sensor output would have to be amplified. A larger measurement current would lead to larger negative torque, having negative implications as discussed above. Amplification of a low output signal involves an amplifier having a number of components whose inaccuracy adds to the measurement signal. Hence, the measurement would be less accurate, than that disclosed in Example 2. 
     EXAMPLE 3 
     Another example of a control apparatus adapted for driving a reluctance machine has the following parameter values: 
     Ud=300 Volts 
     i Wmax =2,0 Amperes 
     Inductance in windings W A , W B , W C  is position dependent within the approximate range 0,22 Henry to 1,8 Henry. 
     Resistance in current sensors S 3   A , S 3   B , S 3   C  is 10 Ohms. 
     Maximum test current through S 3   A , S 3   B , S 3   C  is 50 milliamperes. Using this maximum test current, the measurement procedure described with reference to FIG. 5 below can be repeated up to 1670 times per second (a repetition frequency of 1,67 kHz). 
     The ratio between the maximum drive current i Wmax  and the maximum test current i test     —     max  is in this example: i Wmax /i test =40. 
     With reference to FIG. 4A it can be seen that four alternative excited working states, also referred to as drive states, can occur for a winding depending on which of the valves T 3   A , T 2   A  and/or T 1   A  are closed or open respectively. Although the following is described for winding W A , the same working states are available for the other windings. 
     WSI. A First Working State 
     In a first working state WSI both the valve T 2   A  and the valve T 1   A  are conducting, and valve T 3   A  is non-conducting. In this state a drive current will flow from the plus pole  80  through valve T 1   A  via the winding, valve T 2   A  and current sensor S 2   A  to ground  90 . 
     WSII A Second Working State 
     In a second working state (WSII) the active valves T 1   A  resp. T 2   A  are blocked so that they are non-conducting, and a current flows in the winding from the ground connection  90  to the positive connection  80 . T 3   A  is also blocked in this working state. 
     WSIII A Third Working State 
     In a third working state (WSIII) only one of the valves, T 1   A , is conducting, and when the winding still contains energy so as to drive a current, that current flows in the circuit defined by D 2   A , T 1   A  and the winding. 
     WSIV A Fourth Working State 
     In a fourth working state (WSIV) only one of the valves, T 2   A , is conducting, and when the winding still contains energy so as to drive a current, that current flows in the circuit defined by T 2   A , S 2   A , S 1   A , D 1   A  and the winding. 
     The above four states WSI-WSIV are considered as drive states, since they may involve currents of a drive magnitude through the winding, i.e. currents of importance for the generation of significant torque, as discussed in connection with FIG. 2 above. Currents of a magnitude less than 5 percent of maximum drive current, may be considered not to be of drive magnitude. The provision of the third current sensor S 3   A  advantageously enables current measurement with a reduced measuring inaccuracy, as will be described in further detail below. 
     WSIV A Fifth Working State 
     In the fifth working state WSV the valve T 3   A  and the valve T 1   A  are conducting, and valve T 2   A  is non-conducting. In this state a test current i t  will flow from the plus pole  80  through valve T 1   A  via the winding, valve T 3   A  and current sensor S 3   A  to ground  90 . 
     WSVI A Sixth Working State 
     In a sixth working state only one of the valves, T 3   A , is conducting, and when the winding contains energy so as to cause a current to flow, that current flows in the circuit defined by T 3   A , S 3   A , S 1   A , D 1   A  and the winding. 
     The fifth and the sixth working states may be used in combination for determining the momentary inductance of the winding in an advantageous manner. This will be described in further detail below. 
     An Embodiment of a Current Measurement Method 
     The control unit  100  determines the actual working state for the winding W A  with the help of the input signals from the current sensors S 1   A , S 2   A , S 3   A  and the output signals from the amplifiers  110   1A ,  110   2A  and  110   3A . By combining the logical values for these signals the actual working state can be deduced. 
     The reluctance machine may be controlled to run by means of switching the drive valves T 1   A  and T 2   A , respectively, so as to provide the desired torque by use of selected combinations of the above described drive states WSI-WSIV. The control method for running the machine may involve any of a plurality of known methods wherein valve T 3   A  is kept in a non-conducting state during the drive excitation of the winding. According to an embodiment of the invention the reluctance machine, is controlled in a manner similar to the method described in U.S. Pat. No. 4,868,478 the content of which is hereby incorporated by reference. In accordance with the invention, however, the current measurements used for establishment of the momentary inductance in a non-energized phase winding are performed by means of the current sensors S 3 . 
     FIG. 5 illustrates an embodiment of a method according to the invention. In a step S 110  there is performed a test for establishing whether the phase winding is in a measurement mode or in a drive mode. This is determined in dependence on whether the relevant winding e.g W A  is in a position to provide a positive torque. When, for example, winding W A  is in a position to provide positive torque and there is a current exceeding a certain magnitude flowing through winding W A , then that phase winding is in a drive mode. If winding W A  is in a position to provide negative torque, then that phase winding is in a measurement mode, according to one embodiment The final determination of operational mode is made by the controller  100 , and hence it depends on whether the controller wishes the winding to produce torque (positive or negative) or to provide measurement data for inductance estimations. If the winding is not in a measurement mode it will be in a drive mode, as illustrated by step S 115  in FIG.  5 . In drive mode the controller  100  will control the current to the phase by using some or all of the working states WSI-WSIV. 
     If the winding is in a measurement mode, the next step (S 120 ) is to test whether the winding is inactive, i.e. whether the current I WA  has reached zero. This test may involve measurements of voltage levels at both ends of the winding W A  using a high impedance resistor network connected to ground and to +U d  for providing defined voltage levels at both ends of the winding even when no current flows through the winding. With reference to FIG. 4A, the current I WA  through the winding can be established to be zero when the voltage level at the left end of the winding is equal to the voltage level at the right end of the winding. 
     If the test step S 120  establishes that the winding current is not zero, the controller will set the bridge in state WSII so as to discharge the energy of the winding in a quick manner (step S 130 ). The controller will also monitor the winding current by means of the above mentioned voltage measurements so as to keep the bridge in state WSII until the current reaches zero. 
     When the current has been established to be zero, step S 140  will be performed. In step S 140  the controller  100  switches to the fifth working state WSV so as to provide a voltage pulse with amplitude +U d  across the winding using valves T 3   A  and T 1   A . In this state a current will flow from the plus pole  80  through valve T 1  via the winding, valve T 3  and current sensor S 3  to ground  90 . Synchronously with the switching of the bridge to state WSV, a timer is started by the controller  100  for measuring the amount of time it takes for the current to reach a predetermined level. The amount of time depends on the instantaneous inductance in the winding. 
     The time is measured by monitoring the current (S 150 ) so as to detect (S 160 ) when the current reaches the predetermined level. When the predetermined current level is detected timer value is read (S 170 ), and the time-value is delivered (S 180 ) to a process for inductance estimation. Step S 180  is followed by a repetition of step S 110 . 
     The current measurement according to steps S 150 , S 160  is made using current sensor S 3   A . According to a preferred embodiment sensor S 3   A  comprises a resistor having a well defined resistance, and a comparator for sensing the voltage across the resistor. The comparator delivers an indicator signal to the controller  100  (See FIG. 3) when the detected voltage reaches the predetermined level. On reception of the indicator signal the controller reads the timer value. This embodiment is preferred because an accurate timer is easily integrated in the computer operated controller, and the comparator component quickly reacts on detection of the predetermined voltage level. 
     Hence, it is evident from the above that the controller  100  can control the switches T 1   A , T 2   A , T 3   A  to prevent the drive current from flowing through the current sensor S 3   A  during the drive states. In effect, the controller  100  controls the switches T 1   A , T 2   A , T 3   A  to prevent currents exceeding 5 percent of maximum drive current from flowing through the current sensor S 3   A . The fact that the current sensor S 3   A  does not need withstand currents of drive magnitude makes it possible to use a current sensor having a very small inaccuracy in the measurement range up to about 5 percent of the maximum drive current. 
     The test current sensor S 3   A  may be selected to have a resistance of about the same magnitude as the resistance of the winding W A . According to an embodiment of the invention the resistance R S3A  in test current sensor S 3   A  is selected to any value higher than about half of the resistance R WA  of the corresponding winding W A : 
     
       
           R   S3A   /R   WA &gt;1/2 
       
     
     According to another embodiment the resistance in test current sensor S 3   A  is selected such that the ratio between the resistance R S3A  in test current sensor and the resistance R WA  in corresponding winding W A  is higher than 1/1. 
       R   S3A   /R   WA &gt;1/1 
     According to some embodiments the ratio R S3A /R WA  is higher than 5/1. 
     
       
           R   S3A   /R   WA &gt;5/1 
       
     
     When the test current sensor comprises a test resistor S 3   A  having a well defined resistance and a comparator  200  (See FIG. 6) for sensing the voltage across the test resistor it is possible to use a test resistor having a relatively high resistance and a small inaccuracy. 
     The method has been described with reference winding W A  but the same method may advantageously be implemented for the other windings of the electrical machine to be controlled. 
     The above measurement method results in current and time values which can be used for establishing the instantaneous inductance of the winding. 
     The torque T WA , which is obtained by activating the winding W A , is a function of the current through the winding and the position θ of the rotor. 
     
       
           T   WA   =f   1 ( i   WA , θ)  (1) 
       
     
     The rotor position θ can be calculated from the magnetic flow ψ which flows through the corresponding magnetic circuit and the phase current i WA : 
     
       
         θ= f   2 ( i   WA , ψ A )  (2) 
       
     
     This means that the torque T WA  can be expressed as a function of the magnetic flow ψ A  which flows through the corresponding magnetic circuit and the phase current i WA : 
       T   WA   =f   3 ( i   WA , ψ A )  (3) 
     As mentioned above, the current i WA  through a phase winding is controlled so that a desired torque T W  is obtained from the activated phase winding, as shown in FIG.  2 B. The torque obtained is a function partly of the winding current i WA  and partly of the magnetic flow. The magnetic flow ψ depends in turn on the inductance L WA  and the current i WA . Consequently, T WA  is dependent on i WA  and L WA : 
     
       
           T   WA   =f   4 ( i   WA   , L   WA )  (4) 
       
     
     The inductance L WA  can be determined by integration over time, as described in U.S. Pat. No. 5,043,643:                  L   A          (     t   1     )       =       1   /     i        (     t   1     )         *       ∫   t0   t1            (       U   WA     -       i   WA          R   WA         )             t                   (   5   )                                
     where: 
     t 0  is the point of time when valve T 3 A is set to conduct so as to supply a voltage across the winding. 
     t 1  is the point of time when the measurement current has reached the predetermined value. 
     For certain control conditions the inductance L WA  can be determined by a simplified version of equation (5). In fact the momentary inductance L WA  can be calculated as: 
     
       
           L   A ( t   1 )=1 /i ( t   1 )* U   WA *( t   1   −t   0 )  (6) 
       
     
     A good estimation of the rotor position θ and of the available torque can be calculated from this inductance value L A (t 1 ) and the phase current i WA . 
     A Second Embodiment of a Current Measurement Method 
     According to another embodiment the inductance (and the position) can be determined by measuring the amount of time it takes for the current to sink from a certain start value down to a certain stop value. Such a measurement may be performed using the above described sixth working state. The certain stop value for the test current may be zero, or a suitable level deviating from zero. 
     FIG. 6 is an alternative embodiment of a valve bridge. The FIG. 6 embodiment corresponds essentially to the FIG. 4A embodiment. In the FIG. 6 embodiment, however, the circuitry is simplified by using comparators for indicating when certain limit values are obtained. As illustrated in FIG. 6, a comparator  200  compares the voltage over sensor S 3A  with a reference value obtained by a voltage divider  210 . A voltage divider  215  provides a defined voltage amplitude to the winding even if all valves are non-conducting, and a comparator  220  is arranged to detect the amplitude. A comparator  230  indicates whether sensor S 1A  or S 2A  detects the highest current A plurality of valve bridges according to FIG. 6 can be coupled to a controller  100  as described in connection with FIG.  3 .