diff --git a/dpsim-models/include/dpsim-models/Components.h b/dpsim-models/include/dpsim-models/Components.h index 29a4f0bd5..0c53e76fc 100644 --- a/dpsim-models/include/dpsim-models/Components.h +++ b/dpsim-models/include/dpsim-models/Components.h @@ -92,10 +92,14 @@ #include #include #include +#include #include #include #include #include +#include +#include +#include #include #include #include @@ -108,9 +112,6 @@ #include #include #include -#include -#include -#include #ifdef WITH_SUNDIALS #include #endif diff --git a/dpsim/src/pybind/EMTComponents.cpp b/dpsim/src/pybind/EMTComponents.cpp index edb5b06fa..9dcd43217 100644 --- a/dpsim/src/pybind/EMTComponents.cpp +++ b/dpsim/src/pybind/EMTComponents.cpp @@ -133,6 +133,20 @@ void addEMTPh3Components(py::module_ mEMTPh3) { .def_property("f_src", createAttributeGetter("f_src"), createAttributeSetter("f_src")); + py::class_, + CPS::SimPowerComp>(mEMTPh3, "ControlledVoltageSource", + py::multiple_inheritance()) + .def(py::init()) + .def(py::init()) + .def("set_parameters", + py::overload_cast( + &CPS::EMT::Ph3::VoltageSource::setParameters), + "V_ref"_a) + .def("connect", &CPS::EMT::Ph3::VoltageSource::connect) + .def_property("V_ref", createAttributeGetter("V_ref"), + createAttributeSetter("V_ref")); + py::class_, CPS::SimPowerComp>(mEMTPh3, "CurrentSource", @@ -197,13 +211,9 @@ void addEMTPh3Components(py::module_ mEMTPh3) { "parallel_conductance"_a = zeroMatrix(3)) .def("connect", &CPS::EMT::Ph3::PiLine::connect); - py::class_, - CPS::SimPowerComp>(mEMTPh3, "RXLoad", - py::multiple_inheritance()) - .def(py::init(), "name"_a, - "loglevel"_a = CPS::Logger::Level::off) - .def("set_parameters", &CPS::EMT::Ph3::RXLoad::setParameters, - "active_power"_a, "reactive_power"_a, "volt"_a) + py::class_, CPS::SimPowerComp>(mEMTPh3, "RXLoad", py::multiple_inheritance()) + .def(py::init(), "name"_a, "loglevel"_a = CPS::Logger::Level::off) + .def("set_parameters", &CPS::EMT::Ph3::RXLoad::setParameters, "active_power"_a, "reactive_power"_a, "volt"_a, "reactance_in_series"_a) .def("connect", &CPS::EMT::Ph3::RXLoad::connect); py::class_,