AnsweredAssumed Answered

Regarding LGx signal behaviour

Question asked by PRATIBHA SURABHI on Jul 1, 2020
Latest reply on Jul 29, 2020 by PRATIBHA SURABHI

Hi All,

 

This is regarding observing LGx signal behaviour during power up scenario.
Taking Hall sensor sample code(MC9S12ZVML128_BLDC_Hall) as reference, I am trying to observe LGx signals.
The MCU (MagniV S12 ZVML64) maskset is 3N95G.

FOPT register value is 0xFF


I am using RM V2.13

The initPMF() is as follows :
**********************************start***************************************
PMFCFG0_EDGEA = 1 /* Set Pair A PWM as edge aligned */
PMFCFG0_EDGEB = 1 /* Set Pair B PWM as edge aligned */
PMFCFG0_EDGEC = 1 /* Set Pair C PWM as edge aligned */
PMFCFG2_REV0 = 1 /* PWM generator A generates reload event */
PMFCFG2_REV1 = 0; /* PWM generator A generates reload event */
PMFOUTB = 0x2A; /* Low MOSFETs ON while SW control (Unipolar PWM) */
PMFCFG3_VLMODE = 1; /* Writing to value register zero also writes to value registers one to five */
PMFFQCA = 0; /* Reload every PWM, Half-cycle disabled, fcore / 1 */
PMFMODA = 2500; /* Apply PMF Modulo value */
PMFDTMA = 25; /* Set deadtime count */
PMFCFG2 |= 0x3F; /* Mask all PWM outputs */
PMFOUTC_OUTCTL = 0x3F; /* Set all outputs in Software mode */
PMFENCA_LDOKA = 1; /* Load prescalar A,modulus A and PMFVAL values into set of buffers */
PMFENCA_RSTRTA = 1; /* PWM will restart at commutation event */
PMFENCA_PWMENA = 1; /* Enable PWM Generator A */
PMFCFG1_ENCE = 1; /* Enable commutation event */
PMFENCA_GLDOKA = 1; /* External load OK replaces the function of LDOKA */
**********************************end**********************************************


I have observed these LGx signals for 4 combination of MCU<->PEMicro connection(Ribbon cable) and PEMicro<-> User System (Type a to Type B) connection status after flashing the firmware.
All these LGx signals are observed at power up.
I am attaching the table of combination and its result as reference.

1. Since the maskset is 3N95G, low side gate should be turned on, since at power up GSUF will be loaded with value in FOPT register. [GSUF bit will have value as 1] [Reference GDUF register description]
2. Also LGx will be turned off when initPMF() is executed, since the PWM are masked (PMFCFG2 = 0x3F).

So all things considered [ above two points], LGx should be turned on at power-up[FOPT value loaded] and will be turned off when initPMF is executed[mask PWM].

Q1. Request to confirm my understanding.

Q2. I have found some strange observation with respect #1 and #2 scenario as per the attached excel sheet
Request to inform why such different behaviour is observed for different combination of Ribbon cable(BDM interface) and USB cable connection status.
especially for #1 and #2
For #1, /RESET gradually rises while for others it rises sharply.

Also LGx signal behaviour is different.

More information in excel sheet.

 

Thanking in advance.

Attachments

Outcomes