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.

TMDSSOLARUINVKIT: TMDSSOLARUINVKIT Protection Mechanisms

Part Number: TMDSSOLARUINVKIT

Hi TI Team.

I have aquestion about protection mechanisms in the TMDSSOLARUINVKIT project which I would like to understand better.

1. How TZ1, TZ2, TZ3 signals are configured in the GPIO settings. Especially TZ2 which is used as a fault signal in ePWM1 and ePWM2 module.

SolarMicroInv-Main.c fie:

	EPwm1Regs.TZSEL.bit.OSHT2   = 0x1;
	EPwm2Regs.TZSEL.bit.OSHT2   = 0x1;

but in the SolarMicroInv-DevInit_F2803x.c I have found:

   // GPIO-16 - PIN FUNCTION = TZ2
   GpioCtrlRegs.GPAMUX2.bit.GPIO16  = 3;	    // 0=GPIO,  1=SPISIMO-A,  2=Resv,  3=TZ2

2. ePWM3 module which controls DC-DC flyback inverter have a configuration of OST whose source is the COMP3. I have a question about the COMP3. How signal from ADC is connected to it? IS it connected directly? I mean COMP3A is one the same GPIO as ADC6 which represents PV current.

  • Hi WW,

    1. GPIO16 is connected to TZ2, which then one-shot trips PWM1/2. Grid current sense is window compared to upper/lower limits using external comparator and the comparator output is connected to GPIO16. More details of this connection can be found in the TRM section "Figure 3-37. Trip-Zone Submodule Mode Control Logic"

    2. The PV current sense signal is connected directly to both the ADC as well as the comparator input. See Figure 8-25. AIOx Pin Multiplexing in datasheet

    Thanks and regards, Pawan

  • Hi . Thank you for clarification. This is what I needed.

  • The PV current sense signal is connected directly to both the ADC as well as the comparator input. See Figure 8-25. AIOx Pin Multiplexing in datasheet

    Hi
    According to what you said about comparators muxed with ADC, if I have the following One-Shot Trip for over current of the flyback (which is controlled by PWM3) configuration:

    	// Adding one shot trip for over current of the flyback stage but avoid the <1% duty condition using blanking
    
    	// First enable the COMP3
    	Comp3Regs.COMPCTL.bit.COMPDACEN  =0x1;
    	Comp3Regs.COMPCTL.bit.SYNCSEL    =0x0;	// asynchronous version of the COMP signal is passed to the EPWM/GPIO module
    	Comp3Regs.COMPCTL.bit.CMPINV     =0x0;	// Output of the comparator is passed directly
    	Comp3Regs.COMPCTL.bit.COMPSOURCE =0x0;	// inverting input of the comparator is connected to the internal DAC
    	Comp3Regs.DACVAL.bit.DACVAL		 =700;	// set DAC input to peak trip point ~10 Amps, full scale is 15Amps
    	AdcRegs.COMPHYSTCTL.bit.COMP1_HYST_DISABLE = 0x1;
    
    	//Select COMP3 as one shot trip
    	EPwm3Regs.DCTRIPSEL.bit.DCAHCOMPSEL=DC_COMP3OUT ;
    	EPwm3Regs.TZDCSEL.bit.DCAEVT1=TZ_DCAH_HI;
    	EPwm3Regs.DCACTL.bit.EVT1SRCSEL = DC_EVT_FLT ;
    	EPwm3Regs.DCACTL.bit.EVT1FRCSYNCSEL=DC_EVT_ASYNC;
    	EPwm3Regs.TZSEL.bit.DCAEVT1=0x1;

    Then to have another One-Shot Trip for over current of the second flyback (which is controlled by PWM4), my configuration should looks like this:

    	// Adding one shot trip for over current of the flyback stage but avoid the <1% duty condition using blanking
    
    	// First enable the COMP1
    	Comp1Regs.COMPCTL.bit.COMPDACEN  =0x1;
    	Comp1Regs.COMPCTL.bit.SYNCSEL    =0x0;	// asynchronous version of the COMP signal is passed to the EPWM/GPIO module
    	Comp1Regs.COMPCTL.bit.CMPINV     =0x0;	// Output of the comparator is passed directly
    	Comp1Regs.COMPCTL.bit.COMPSOURCE =0x0;	// inverting input of the comparator is connected to the internal DAC
    	Comp1Regs.DACVAL.bit.DACVAL		 =700;	// set DAC input to peak trip point ~10 Amps, full scale is 15Amps
    	AdcRegs.COMPHYSTCTL.bit.COMP1_HYST_DISABLE = 0x1;
    
    	//Select COMP1 as one shot trip
    	EPwm4Regs.DCTRIPSEL.bit.DCAHCOMPSEL=DC_COMP1OUT ;
    	EPwm4Regs.TZDCSEL.bit.DCAEVT1=TZ_DCAH_HI;
    	EPwm4Regs.DCACTL.bit.EVT1SRCSEL = DC_EVT_FLT ;
    	EPwm4Regs.DCACTL.bit.EVT1FRCSYNCSEL=DC_EVT_ASYNC;
    	EPwm4Regs.TZSEL.bit.DCAEVT1=0x1;

    AND as I used COMP1 which is muxed with ADCINA2 this is the GPIO pin I should connect to second PV current sense signal. Correct me if I wrong.

  • Pin-61 of the HSEC connector is connected to both ADCINA2 and COMP1A. You can use it for both sensing signal through ADC and comparison at the same time.

    Thanks and regards, Pawan

  • OK, this is clear for me, and pin 14 is connected to ADCINA4 and COMP2A.

    Summing up:

    Pin 12 - ADCINA6 and COMP3A
    Pin 14 - ADCINA4 and COMP2A
    Pin 16 - ADCINA2 and COMP1A

    And as I want to have shot trip for over current of the DC-DC flybacks stage which are connected to the PWM I need to use comparators which are connected to the PV current sense signal ADC - in other words, to have PV panel current measurements and One-Shot Trip for over current of the DC-DC flyback I need use one of the three above.

    But how about COMP1B, COMP2B, COMP3B? Is it possible to use them like the ones above?

    In the TMDSSOLARUINVKIT software there are onle three Comp1Regs, Comp2Regs, Comp3Regs comparators definied.

  • The pins you mentioned are with respect to the IC [Figure 6-3. 2803x 80-Pin PN LQFP (Top View)] of the datasheet. On the HSEC connecter these would be routed onto different pins which you could find through the reference design HSEC connector.

    The reference DAC is connected only on the negative of the comparator. So, you would either have to choose COMPB or DAC through the mux. Figure below for reference.

    Recommend using our latest parts from C2000 real-time microcontrollers | TI.com based on memory and MIPs requirement. The newer parts have more flexibility, more comparators, PWMs and muxing options.

    Thanks and regards, Pawan