@@ -4440,7 +4440,7 @@ RECORD HPWHLINK "HPWHLink" *SUBSTRUCT // Ecotope's HPWH tank and heater
44404440*declare "double hw_GetCHDHWTSupply() const;"
44414441*declare "RC hw_DoHour( float& tSetpoint, float targetSoC);"
44424442*declare "RC hw_DoSubhrStart( float tEx, float tASHPSrc=-999.f);"
4443- *declare "RC hw_DoSubhrTick( DHWTICK& tk, float tInlet, float scaleWH=1.f, float tMix=-1., float tMains=-1.f, float* pTOutNoMix=NULL, int drStatus=0);"
4443+ *declare "RC hw_DoSubhrTick( DHWTICK& tk, int servesWhat, float tInlet, float scaleWH=1.f, float tMix=-1., float tMains=-1.f, float* pTOutNoMix=NULL, int drStatus=0);"
44444444*declare "RC hw_DoSubhrTick( int iTk, float draw, float tInlet, float qTX, float* pTOut, float scaleWH=1.f);"
44454445*declare "RC hw_DoSubhrEnd( float mult, ZNR* pZn, ZNR* pZnASHPSrc);"
44464446
@@ -4511,7 +4511,11 @@ RECORD HPWHLINK "HPWHLink" *SUBSTRUCT // Ecotope's HPWH tank and heater
45114511RECORD DHWHEATER "DHWHeater" *RAT // input / runtime DHW heater
45124512 *prefix wh_
45134513
4514- *exdes // *declare "~DHWHEATER;"
4514+ *excon // explicit constructor
4515+ *exdes // explicit ~DHWHEATER()
4516+ *ovrcopy // overide Copy()
4517+ *declare "virtual DHWHEATER& CopyFrom( const record* pSrc, int copyName=1, int dupPtrs=0);"
4518+
45154519 *declare "RC wh_CkF();"
45164520 *declare "virtual RC RunDup( const record* pSrc, int options=0);"
45174521 *declare "RC wh_Init();"
@@ -4530,13 +4534,12 @@ RECORD DHWHEATER "DHWHeater" *RAT // input / runtime DHW heater
45304534 *declare "bool wh_IsSameType( const DHWHEATER& wh) const;"
45314535#endif
45324536 *declare "bool wh_CanHaveLoopReturn() const { return wh_IsHPWHModel(); }"
4533- *declare "bool wh_CanHaveDHWLOOPHEATER() const { return wh_GetFunction()==whfcnPRIMARY && wh_IsHPWHModel(); }"
4537+ *declare "bool wh_CanHaveDHWLOOPHEATER() const { return wh_IsPrimary() && wh_IsHPWHModel(); }"
45344538 *declare "bool wh_IsInstUEFModel() const { return wh_type==C_WHTYPECH_INSTUEF; }"
45354539 *declare "bool wh_IsSubhrModel() const { return wh_IsHPWHModel() || wh_IsInstUEFModel(); }"
45364540 *declare "bool wh_UsesTSetpoint() const { return wh_IsHPWHModel(); }"
45374541 *declare "float wh_CalcLDEF( float arl, int options=0);"
4538- *declare "RC wh_CanSupplyCHDHW() const;"
4539- *declare "bool wh_SuppliesCHDHW() const;"
4542+ *declare "RC wh_SetupAsCHDHWSource();"
45404543 *declare "RC wh_DoHour();"
45414544 *declare "RC wh_DoSubhrStart();"
45424545 *declare "RC wh_DoSubhrTick( struct DHWTICK& tk, float scaleWH);"
@@ -4567,10 +4570,11 @@ RECORD DHWHEATER "DHWHeater" *RAT // input / runtime DHW heater
45674570 *i ANAME wh_desc; // probe-able description text
45684571 *declare "virtual const char* GetDescription( int options=0) { options; return wh_desc; }"
45694572 *r INT wh_fcn; // function of this DHWHEATER per whfcnXXX enum
4570- *declare "enum { whfcnUNKNOWN=0, whfcnPRIMARY, whfcnLOOPHEATER, whfcnCOUNT=whfcnLOOPHEATER, whfcnLASTHEATER=0x100 };"
4571- *declare "int wh_GetFunction() const { return wh_fcn & 0xff; }"
4573+ *declare "enum { whfcnUNKNOWN=0, whfcnPRIMARY, whfcnLOOPHEATER, whfcnSUPPLIESCHDHW=0x10, whfcnSUPPLIESLOOP=0x20, whfcnSUPPLIESLOAD=0x40 };"
45724574 *declare "int wh_SetFunction();"
4573- *declare "bool wh_IsLastHeater() const { return (wh_fcn & whfcnLASTHEATER) != 0; }"
4575+ *declare "bool wh_IsPrimary() const { return (wh_fcn & whfcnPRIMARY) != 0; };"
4576+ *declare "bool wh_IsLoopHeater() const { return (wh_fcn & whfcnLOOPHEATER) != 0; };"
4577+
45744578 *i WHASHPTYCH wh_ashpTy; // air source heat pump (HPWH) type, required iff wh_heatSrc=ASHPX, else ignored
45754579 // C_WHASHPTYCH_xxx, etc
45764580 *i WHRESTYCH wh_resTy; // resistance heater type, used iff wh_heatSrc=_ELRESX, else ignored
0 commit comments