This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Measuring bandwidth of a current loop.

Hi all,

I've got a current loop set up within my microcontroller, which works by measuring the current through a motor using the ADC, and then comparing this to a desired current (setpoint), and then minimising this difference.

I would like to meausure the bandwidth of my current loop, using a network analyser. I was informed this is most often done with the use of a tracking generator within a network analyser, which e.g. generates a frequency of 0-100kHz, which acts as a setpoint towards my current loop. This is then measured by the network analyser, which is therefore able to determine my -3dB cutoff point, thus determining the bandwidth of my current loop.

I have a few questions regarding this.

  1. Is this the only manner to measure bandwidth? If not, what else can I use to do these types of measurements?
  2. How does one go about getting the tracking generators output as a setpoint for my current loop? Is this simply setting up a GPIO input pin within the  microcontroller, and passing whatever is on the output of my tracking generator as an input to this GPIO pin?

Many thanks!

  • Step response might be more useful.

    Also small signal and large signal responses are likely to be quite different, depending on the motor you will likely see torque start to saturate (or worse) at some point.

    Robert
  • Cheers for the quick reply.

    By a step reponse, are you implying that my analyser generates a step reponse, or I generate a step response within my microcontroller, by going from e.g. 0A to 1A, and keeping it at 1A.

    It's not so much to test the motor, it's more to test my amplifier, and the tests will be repeated with the final load. These early tests will be done to get an idea of what to expect.

    Any thoughts on the second set of questions?
  • Once again (like many, here) - you've defined a design objective (measuring bandwidth) but not really justified its need.

    Your motor does not provide a pure, resistive electrical load - the "L & C" reactive components likely generate harmonic currents - which must be noted.

    And is not your motor subject to inertia - which increases with the amount of load - applied to your motor?   Might this operate against any (sudden) change in current?

    The classical, "Response to a step input" - voiced by Robert - proves a very good method to bring most motors under "reasonable" command & control.

  • I'm suggesting you use a storage 'scope and measure the response to a step input command. Probably both large and small steps at various offsets (if you do this with an active motor you will likely not want to run very large step responses, I've used stator carcasses for this kind of current testing in the past).

    Motors are highly inductive (with a few rare exceptions for high speed motors). As such the response speed is dependent on the tuned PID filters and not really determinable separate from a comparable inductor.

    You can test with a resistive load but the performance is likely to be quite different.

    Robert
  • @cb1. I know my motor isn't an ideal load, however I mentioned in one of my replies this will be replaced later on with a different, final load. These measurements are simply an indication of what my amplifier is capable of doing, so that in the future, when some one chooses this final load, they have an idea of what the amplifier is capable of. In regards to the harmonic currents, these have already been noted.

    The motor has no load attached to it, it will just be spinning freely, if this is your worry in regards to inertia.

    @Robert. I'll have a look into providing a step input command and observing it with my 'scope, and compare this to what I measure using my analyser.

    In the end it might provide more useful to use a resistive load, however I was just looking for a load which was capable of taking a good amount of current, which happened to be a motor I had lying around!