Hi, I use TMDSHVMTRPFCKIT with F28335 Control card to drive a BLDC based on CCS4.
I studied the FOC Sensored example code.
The part of phase current ADC Process in that code is "clarke1.As =_IQ15toIQ((AdcResult.ADCRESULT0<<3)-_IQ15(0.50))<<1;"
But now I try to write my own code of FOC used in this kit.
In phase current ADC Function, I want to use this formula:
Phase Current Ia = CurrentScale * ( (Float)( ADCRESULT>>4 ) - Ia_Offset )
Because I use TMS320F28335, the ADCRESULT is needed to be right shifted before I use the value of ADCRESULT.
Next Step I let the ADCRESULT subtracts the phase current offset
and CurrentScale = (3/4096) * X, X means how many amperes per volt, 3 means 3V, 4096 means 12bits ADC.
However, from the guide or example code as I mentioned above, I can not get the X value.
I know I could get the value of X if this kit detects current by current sensors because there are some information about the value of X in the datasheets of the current sensors.
But this kit detects current by OP and RC circuit, I do not know how to get the value of X!
Is anyone could help me get the answer?? Thanks a lot!!!!!!