diff options
author | couriersud <couriersud@gmx.org> | 2020-01-29 18:53:06 +0100 |
---|---|---|
committer | couriersud <couriersud@gmx.org> | 2020-01-29 18:53:06 +0100 |
commit | d7fd89afe1a384e268cb8a9fbd0f6c4c994e195d (patch) | |
tree | e10ad631090b03b0660b148a86b784926d794bde /src/lib/netlist/analog/nlid_twoterm.cpp | |
parent | 2742727a0beabaf5b8ae82ff9ee8596cce91b7f4 (diff) |
netlist: fix parameter update recalculation. (nw)
Diffstat (limited to 'src/lib/netlist/analog/nlid_twoterm.cpp')
-rw-r--r-- | src/lib/netlist/analog/nlid_twoterm.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/lib/netlist/analog/nlid_twoterm.cpp b/src/lib/netlist/analog/nlid_twoterm.cpp index e06a9cf275a..5aa312bc64a 100644 --- a/src/lib/netlist/analog/nlid_twoterm.cpp +++ b/src/lib/netlist/analog/nlid_twoterm.cpp @@ -66,6 +66,7 @@ namespace analog NETLIB_UPDATE_PARAM(POT) { + // FIXME: We only need to update the net first if this is a time stepping net m_R1.solve_now(); m_R2.solve_now(); @@ -76,6 +77,8 @@ namespace analog v = nlconst::one() - v; m_R1.set_R(std::max(m_R() * v, exec().gmin())); m_R2.set_R(std::max(m_R() * (nlconst::one() - v), exec().gmin())); + m_R1.solve_later(); + m_R2.solve_later(); } @@ -97,6 +100,7 @@ namespace analog NETLIB_UPDATE_PARAM(POT2) { + // FIXME: We only need to update the net first if this is a time stepping net m_R1.solve_now(); nl_fptype v = m_Dial(); @@ -106,6 +110,7 @@ namespace analog if (m_Reverse()) v = nlconst::one() - v; m_R1.set_R(std::max(m_R() * v, exec().gmin())); + m_R1.solve_later(); } // ---------------------------------------------------------------------------------------- |