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.

EMETER library for UCD3138PFCEVM_026 and TIDA-00707 source code

Other Parts Discussed in Thread: TIDA-00707, UCD3138PFCEVM-026, UCD3138

Hello,

I am working with UCD3138PFCEVM_026 and testing the firmware, but the EMETER library seems to be missing completely. There are functions declared in file ipm.h, but these are not defined anywhere (or at least I didn't find them). The firmware I downloaded is file SLUC609.ZIP

Also, is it possible to have the source code for TIDA-00707? (I requested it yesterday through the website, but have no idea how long it will take)

Thank you

Marco

  • In the webpage to request the TIDA-00707 sofware, it says 

    "Your request will be reviewed - If you are approved, in a few days you will receive an email from TI. If you need to reach us, please contact hpcs_software@list.ti.com"

    But writing to the specified email address is of no use, I got an automatic response

    "The message you sent to the mailing list 'hpcs_software', with the subject line:   TIDA-00707 - source code 

    was not sent to the list subscribers because you do not have permission to send messages to this mailing list."

    Is there a way to obtain it? Is the email address provided wrong? 

    thank you

  • Ok, I understand that the EMETER is now a .lib library.

    Can anybody help me on setting it up on UCD3138PFCEVM-026? I am trying to implement the calibration steps as per SLUA744 and using the xls file "e-metering 4-point calibration.xlsx", but there is no current reading in the variables (for example iv.iin_filtered_reporting).

    Is it possible there is an error regarding the ADC channels? SLUA744 mentions Line measured on AD_00 and neutral on AD_04 (while the EVM is configured instead for channels 7 and 8 respectively). If I am right, this is also reflected on standard_interrupt.c, at the line
    "AdcRegs.ADCSEQSEL0.all = 0x02041003;"

    But if that is the case, I changed it to "AdcRegs.ADCSEQSEL0.all = 0x02081703;" and I still get no readings.
    I tried to add a call to e_meter() in main.c, but still nothing.

    I tried to set EMETER_EN = ON in the project Predefined symbols, but then the output voltage is not regulated and the EVM shuts down shortly after that.

    In short, what are the steps to enable EMETERING on the UCD3138PFCEVM-026?

    Thank you
    Marco
  • Hi Marco,

    Let me take a look at it, I will get back to you soon.

    Regards,
    Bosheng
  • Hi Macro,

    The emeter function was developed after UCD3138PFCEVM-026 released. To get best accuracy, we used a ADC dual sample and hold feature in UCD3138, this requests specific ADC channels to be used for emeter as described in SLUA744. You need to modify the UCD3138PFCEVM-026 if you want to test emeter function. You need to disconnect Vac_line, Iin, Vac_neutral from their original connection and connect to AD00, AD02, AD04, respectively, you also need to modify the firmware to accommodate these changes.

    Regards,
    Bosheng
  • Bosheng, it does look like the code modification is in there if you select emeter_en:

    #if ((EMETER_EN==ON)&&(PFC_TYPE == SINGLE_PHASE))

    PMBusRegs.PMBCTRL3.bit.IBIAS_A_EN = 0;//disable current source

    PMBusRegs.PMBCTRL3.bit.IBIAS_B_EN = 0;

    //for IPM board#1 (modified)

    AdcRegs.ADCSEQSEL0.bit.SEQ0 = 3; //Vbus

    AdcRegs.ADCSEQSEL0.bit.SEQ1 = 0; //Vac_L

    AdcRegs.ADCSEQSEL0.bit.SEQ2 = 4; //Vac_N

    AdcRegs.ADCSEQSEL0.bit.SEQ3 = 2; //Iac

    AdcRegs.ADCCTRL.bit.SINGLE_SWEEP = 1; //single sweep conversion

    AdcRegs.ADCCTRL.bit.BYPASS_EN = 3; //bypass adc02

    AdcRegs.ADCSEQSEL0.bit.SEQ2_SH = 1;//Vac_N dual sampling with Iac

    AdcRegs.ADCSEQSEL0.bit.SEQ1_SH = 0;//Vac_L not dual sampling with Iac

    AdcRegs.ADCAVGCTRL.bit.AVG0_CONFIG = 0; //4x averaging for vout

    AdcRegs.ADCAVGCTRL.bit.AVG0_EN = 1; //enable averaging

    #else

    AdcRegs.ADCCTRL.bit.SINGLE_SWEEP = 0; // set it up for continous mode

    AdcRegs.ADCSEQSEL0.bit.SEQ0 = 3; //Vbus

    AdcRegs.ADCSEQSEL0.bit.SEQ1 = 7; //Vac_L

    AdcRegs.ADCSEQSEL0.bit.SEQ2 = 8; //Vac_N

    AdcRegs.ADCAVGCTRL.bit.AVG0_CONFIG = 0; //4x averaging for vout

    AdcRegs.ADCAVGCTRL.bit.AVG1_CONFIG = 0; //4x averaging for vin

    AdcRegs.ADCAVGCTRL.bit.AVG2_CONFIG = 0; //4x averaging for vin

    AdcRegs.ADCAVGCTRL.bit.AVG0_EN = 1; //enable averaging

    AdcRegs.ADCAVGCTRL.bit.AVG1_EN = 1; //enable averaging

    AdcRegs.ADCAVGCTRL.bit.AVG2_EN = 1; //enable averaging

    #endif

  • This is great, then only the EVM hardware change is needed.

    Regards,
    Bosheng
  • Bosheng and Ian,

    Thank you. That is what I suspected but I didn't know if the sofware was outdated or the hardware

    In summary:

    - mod the hardware

    - run the original downloaded firmware simply setting EMETER_EN = ON in the Predefined symbols?

    I'll give it a try and get back to you if I am still having problems

    thank you

  • I have modified the board as following
    - line connected to AD00
    - neutral to AD04
    - CT_1 to AD07 (was AD04)
    - IPM? It was connected to AD00, I am unclear what it is used for and I have not connected anywhere
    I am facing some issues:
    - rms current measurement jumps around, I cannot identify exact measurement
    - power measurement also not sure if it is meaningful or not. Even iv.pin_slow_filtered is not constant at all

    I have tried to add calibration data, but I am not sure of the effect since:
    - the numbers I am reading from memory debugger bounce around a lot (orders of magnitude), and never stabilize
    - when using the procedure from SLUA744 to send calibration data through SMBUS
    - - the data is sent (how many bytes to send? SLUA744 page 8 shows 32 bytes in the screenshot)
    - - I get return value 01 when I read location D1, meaning I did not send the correct number of bytes.
    - - The file "e-metering 4-point calibration.xlsx" does not have 32 bytes to copy and paste, only 27. The code in pmbus_topology.c is looking for 29 bytes.

    1) do I need to reconnect and reconfigure the signal IPM that was originally connected to AD00?
    2) why is power and current readings bouncing around so much?
    3) Can you give some more details about the calibration process?

    Thank you