예제 #1
0
파일: main.py 프로젝트: mfr13/pymoskito
    register_simulation_module(Controller, LinearStateFeedback)
    register_simulation_module(Controller, LinearStateFeedbackParLin)
    register_simulation_module(Controller, LjapunovController)
    register_simulation_module(Controller, SwingUpController)

    register_visualizer(TwoPendulumVisualizer)

    register_processing_module(PostProcessingModule, TwoPendulum)

    # create an Application instance (needed)
    app = QApplication([])

    if 1:
        # create Simulator
        sim = Simulator()

        # load default config
        sim.load_regimes_from_file("default.sreg")

        # apply a regime
        sim.apply_regime_by_name("test")

        # remotely start a simulation
        # sim.start_simulation()

        sim.show()
    else:
        post = PostProcessor()
        post.show()
예제 #2
0
파일: main.py 프로젝트: cklb/pymoskito
    register_simulation_module(Controller, LinearStateFeedback)
    register_simulation_module(Controller, LinearStateFeedbackParLin)
    register_simulation_module(Controller, LjapunovController)
    register_simulation_module(Controller, SwingUpController)

    register_visualizer(TwoPendulumVisualizer)

    register_processing_module(PostProcessingModule, TwoPendulum)

    # create an Application instance (needed)
    app = QApplication([])

    if 1:
        # create Simulator
        sim = Simulator()

        # load default config
        sim.load_regimes_from_file("default.sreg")

        # apply a regime
        sim.apply_regime_by_name("test")

        # remotely start a simulation
        # sim.start_simulation()

        sim.show()
    else:
        post = PostProcessor()
        post.show()
예제 #3
0
파일: main.py 프로젝트: mfr13/pymoskito
__author__ = 'stefan'

if __name__ == '__main__':
    # register own modules
    register_simulation_module(Model, BallBeamModel)
    register_simulation_module(Controller, FController)
    register_processing_module(PostProcessingModule, EvalA1)
    register_visualizer(BallBeamVisualizer)

    # create an Application instance (needed)
    app = QtGui.QApplication([])

    if 0:
        # create simulator
        sim = Simulator()

        # load default config
        sim.load_regimes_from_file("default.sreg")
        sim.apply_regime_by_name("test-nonlinear")
        sim.start_simulation()

        sim.show()
        QtGui.QApplication.instance().exec_()

    else:
        post = PostProcessor()
        post.show()

    app.exec_()