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.

Piccolo F28069 control card and DRV8312 Evaluation Board Current Feedback

Other Parts Discussed in Thread: DRV8312, CONTROLSUITE

The DRV8312 Evaluation board provides the three current feedback channels to the control card interface on two seperate ADC pins totaling 6 channels, but the InstaSpin firmware sets up the ADC to only convert one of the two pairs of inputs for a total of 3 channels actually used. What is the reason for providing two identical channels if they are not used?


I ask this because in duplicating the design, we would like to do away with the duplicated channels so we can use the ADC channels that are freed up for other system analog. As long as we keep the channels that are needed by the InstaSpin code can we safely remove the duplicated channels?

  • You sure about that? I don't see that on the schematic.

     

    anwyas, you can see which ADC chs are used in drv.c

    // configure the SOCs for drv8312kit_revD
      // sample the first sample twice due to errata sprz342f
      ADC_setSocChanNumber(obj->adcHandle,ADC_SocNumber_0,ADC_SocChanNumber_A1);
      ADC_setSocTrigSrc(obj->adcHandle,ADC_SocNumber_0,ADC_SocTrigSrc_EPWM1_ADCSOCA);
      ADC_setSocSampleDelay(obj->adcHandle,ADC_SocNumber_0,ADC_SocSampleDelay_9_cycles);

      ADC_setSocChanNumber(obj->adcHandle,ADC_SocNumber_1,ADC_SocChanNumber_A1);
      ADC_setSocTrigSrc(obj->adcHandle,ADC_SocNumber_1,ADC_SocTrigSrc_EPWM1_ADCSOCA);
      ADC_setSocSampleDelay(obj->adcHandle,ADC_SocNumber_1,ADC_SocSampleDelay_9_cycles);

      ADC_setSocChanNumber(obj->adcHandle,ADC_SocNumber_2,ADC_SocChanNumber_B5);
      ADC_setSocTrigSrc(obj->adcHandle,ADC_SocNumber_2,ADC_SocTrigSrc_EPWM1_ADCSOCA);
      ADC_setSocSampleDelay(obj->adcHandle,ADC_SocNumber_2,ADC_SocSampleDelay_9_cycles);

      ADC_setSocChanNumber(obj->adcHandle,ADC_SocNumber_3,ADC_SocChanNumber_A5);
      ADC_setSocTrigSrc(obj->adcHandle,ADC_SocNumber_3,ADC_SocTrigSrc_EPWM1_ADCSOCA);
      ADC_setSocSampleDelay(obj->adcHandle,ADC_SocNumber_3,ADC_SocSampleDelay_9_cycles);

      ADC_setSocChanNumber(obj->adcHandle,ADC_SocNumber_4,ADC_SocChanNumber_B7);
      ADC_setSocTrigSrc(obj->adcHandle,ADC_SocNumber_4,ADC_SocTrigSrc_EPWM1_ADCSOCA);
      ADC_setSocSampleDelay(obj->adcHandle,ADC_SocNumber_4,ADC_SocSampleDelay_9_cycles);

      ADC_setSocChanNumber(obj->adcHandle,ADC_SocNumber_5,ADC_SocChanNumber_A7);
      ADC_setSocTrigSrc(obj->adcHandle,ADC_SocNumber_5,ADC_SocTrigSrc_EPWM1_ADCSOCA);
      ADC_setSocSampleDelay(obj->adcHandle,ADC_SocNumber_5,ADC_SocSampleDelay_9_cycles);

      ADC_setSocChanNumber(obj->adcHandle,ADC_SocNumber_6,ADC_SocChanNumber_B4);
      ADC_setSocTrigSrc(obj->adcHandle,ADC_SocNumber_6,ADC_SocTrigSrc_EPWM1_ADCSOCA);
      ADC_setSocSampleDelay(obj->adcHandle,ADC_SocNumber_6,ADC_SocSampleDelay_9_cycles);

      ADC_setSocChanNumber(obj->adcHandle,ADC_SocNumber_7,ADC_SocChanNumber_B2);
      ADC_setSocTrigSrc(obj->adcHandle,ADC_SocNumber_7,ADC_SocTrigSrc_EPWM1_ADCSOCA);
      ADC_setSocSampleDelay(obj->adcHandle,ADC_SocNumber_7,ADC_SocSampleDelay_9_cycles);

  • Chris,

    To clarify, the documentation that we have, "DRV8312EVM_RevD.PDF", shows that the signal IA-FB is on pins 59 (ADC-A1) and 13 (ADC-B3) , IB-FB is on pins 9 (ADC-B1) and 17 (ADC-B5), and IC-FB is on pins 63 (ADC-A3) and 67 (ADC-A5) of J1, the control card connector. The code you posted confirms our findings and shows that IA-FB is sampled only on ADC-A1 and not ADC-B3. IB-FB is sampled only on ADC-B5 and not ADC-B1. IC-FB is sampled only on ADC-A5 and not ADC-A3. So it is assumed that since the code does not use them that we could in fact re-purpose them without losing compatibility with the InstaSpin drivers. Our customer is just looking for reassurance that removing them won't cause an issue with any updates to InstaSpin in the future.

  • Ah, yes. I see. 

    We routed those so that we could do simultaneous sampling on A/B-1, A/B-3, and A/B-5 if we wanted. This would allow you to have all three pairs of any two.

    It's not necessary, and with the -FOC and -MOTION solutions we are just doing sequential sampling.  

  • Chris,

    One more question to satisfy our customer. Was there ever an algorithm implemented that actually used the simultaneous sampling of the current channels? Do you have a white paper to reference the theory/benefit of such an algorithm?

    Thank you again Chris for all the help.

  • Mark,

    The sensorless (SMO) FOC projects in controlSUITE uses the dual sample & hold feature of the ADC.  Most of these solutions only sample two currents anyways, so we just always sample Iu and Iv together.  It saves you a few clocks and makes sure they are synchronized values.  The problem is when you get to modulation regions where Iu or Iv samples are not possible due to having the low side switch not on long enough.  In these regions you may want to add Iw samples, but where do you add it?  Due to the dual S/H features of the ADC you need one channel on the A side and one on the B.  One way to solve this would be to have Iw on two channels, one on A and one on B. This way you could always sample Iw with Iu or Iw with Iv. But then you need logic to decide how to change your sampling channels.

    Another way is to just always take all the combinations of samples, and then use logic in your control algorithm to use the correct pairings at the correct time.

    Besides the documents in controlSUITE, here is a white paper:

    http://www.ti.com/lit/sprt528

     

     

  • Chris,

    Thank you for such a fast reply. I think your answer with satisfy them. Great Job!