Commit f4ef9337 authored by David Brandt's avatar David Brandt
Browse files

Hardware factors and fixes for MCCarolo r4 PCB

parent d9037413
......@@ -37,17 +37,29 @@
#define M1_I_PH_NOM FRAC16(0.20875)
#define M1_U_PH_NOM FRAC16(0.661157024793)*/
#define M1_I_MAX (12.0) // 3V -> 12A
#define M1_U_DCB_MAX (60.87)
// scaling factors:
// voltage:
// 4.7k / (4.7k + 82k) = 0.054209919
// full scale: 55.340425799 V
//
// current:
// 0.003R shunt, 50 V/V INA213
// 0.15 V / A
// full scale: 20 A
#define M1_U_DCB_MAX (55.340425799)
#define M1_U_DCB_UNDERVOLTAGE FRAC16(0.144559784) // 8V
#define M1_U_DCB_OVERVOLTAGE FRAC16(0.36139946) // 20V
#define M1_U_DCB_TRIP FRAC16(0.36139946) // 20V
#define M1_U_PH_NOM FRAC16(0.216839676) // 12V
#define M1_I_MAX (20.0)
#define M1_I_DCB_OVERCURRENT FRAC16(0.4) // 8A
#define M1_I_DCB_LIMIT FRAC16(0.25) // 5A
#define M1_I_PH_NOM FRAC16(0.05) // 1A
#define M1_N_MAX (5000.0)
#define M1_I_DCB_OVERCURRENT FRAC16(0.8) // 10A / 12A
#define M1_U_DCB_UNDERVOLTAGE FRAC16(0.015) // 1V / 60.87V
#define M1_U_DCB_OVERVOLTAGE FRAC16(0.2464) // 15V / 60.87V
#define M1_I_DCB_LIMIT FRAC16(0.25) // 3A / 12A
#define M1_U_DCB_TRIP FRAC16(0.2464) // 15V / 60.87V
#define M1_N_NOM FRAC16(0.8) /* Max Speed 0.8 ??? */
#define M1_I_PH_NOM FRAC16(0.08) // 2A / 12A
#define M1_U_PH_NOM FRAC16(0.197) // 12V / 60.87V
// Mechanical Alignemnt
//#define M1_ALIGN_CURRENT FRAC16(0.1875)
......
......@@ -297,7 +297,7 @@ bool_t MCDRV_CurrDcBusGet(mcdrv_adc12_t *this)
s_statusPass = TRUE;
*this->pf16IDcBus =
(frac16_t)((int16_t)this->pui32AdcBaseAdd->RSLT[this->ui16RsltNumIdcb] - this->ui16OffsetDcCurr);
MLIB_Mul_F16((frac16_t)((int16_t)this->pui32AdcBaseAdd->RSLT[this->ui16RsltNumIdcb] - this->ui16OffsetDcCurr), FRAC16(-1.0));
return (s_statusPass);
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment