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.

TMS320F28023: share pin between ADC and comparator

Other Parts Discussed in Thread: TMS320F28023

I'm starting a new project to drive 2 half-bridges, measure 2 currents and 2 temperatures.

In case of overcurrent, I'd like to stop ePWM outputs inmediately, without ADC. TMS320F28023 has 2 comparators which share pins with ADC inputs. Is the comparator able to stop ePWM while the ADC is measuring the same pin?, is it able to do it asynchronously?, do I have to use 2 different pins for the same signal (one for comparator and another one for ADC)?, or do I need external comparators with outputs connected to TZx (trip-zone) inputs?.

Thank you in advance

  • My understanding after looking at the blocks is that comparator function and ADC measurement can be done simultaneously although I haven't utilized this function yet. One shouldn't need to use two channels to measure and to protect one signal. The comparator function happens asynchronously and yes the comparator output can initiate TZ to turn off PWM outputs. Definitely one shouldn't need external comparator to implement fault management - at least that's my understanding. I am sure I will be corrected in case I didn't understand the features properly [:D]

  • What Arefeen has said is correct.  You will only need one ADC input pin to measure your current/allow for overcurrent protection.

    Thank you,
    Brett

  • Thank you Arefeen

    Thank You Brett

  • All posted is correct, but I want to throw out some advisements with this configuration:

    1)When sampling with the ADC it is always advisable to have a good drive on the pin so that the sampled voltage is consistent with the voltage on the pin.  In this configuration(ADC and COMP) this is important for another reason in that if the impedance to too high the ADC sample and hold capacitor will dominate the circuit during switch on and glitch the voltage on the pin.  This will in turn effect what the comparator sees, and depending on your threshold on the inverting COMP input cause a false decision.

    2)From the DS the comparator has ~35mV of input hysteresis, this is achieved with a feedback path from the non-inverting input to the comparator output.  The resultant of this is a 100kOhm impedance from the input to the output of the comparator.  Depending on the state of the output of the comparator(1 or 0) this can source/sink current across the 100kOhm, and effect your voltage on the pin. 

    Since you are using as ADC as well; my assumption is that the source impedance will be << 100kOhm so this will likely not be a problem.

     

    Best,

    Matthew

  • Matt - thanks for the tips. In most cases with motor drive and power applications the trip will be utilized with current measurements which usually comes with an op-amp stage and therefore I think your concern will automatically be addressed as far as driving ADC pin goes. In case of voltage trips the response time may not be that critical and therefore one should be okay with a "reasonable" sensing circuitry.