Hello everyone,
I used a SYSFNC Subroutine in my Python subroutine script, for reading some system state values. The usage are showed below:
`USER({m_mp_dth.idstring},{m_mw_dth.idstring})`
def CNFSUB(id, time, par, npar, loci, ni, locj, nj, gap, gapdot, gapdotdot, dflag, iflag):
ipar = [0]*3
ipar[0] = int(par[0])
ipar[1] = int(par[1])
ipar[2] = int(par[1])
[dw, err] = py_sysfnc("DY", ipar) # mP_dth, mW_dth, mW_dth [70000094, 70000093, 70000093]
py_errmes(err, "Error calling SYSFNC for DY, dw", id, "STOP")
print("DY -- dw=%r, err=%r" % (dw, err))
…
return …
I made a print for debugging, and all the print is:
DY -- dw=0.0, err=0
Seems the sysfnc returns 0 correctly. But i also made a output for the same system state:
DY({m_mp_dth.idstring},{m_mw_dth.idstring},{m_mw_dth.idstring})
The output curve in HyperGraph do has a value, shows below:
Why did SYSFNC not read those data? Is the problem in my scripting or defining the input parameters for USER()?
Could anyone help me out on this?
Sincere gratitude,
Garand