Skip to content

Commit

Permalink
fixed bugs in examples
Browse files Browse the repository at this point in the history
  • Loading branch information
alx87grd committed Aug 2, 2019
1 parent 0e063d3 commit 2c94091
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 8 deletions.
12 changes: 7 additions & 5 deletions examples/simple_pendulum/simple_pendulum_with_pid.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,19 @@
import numpy as np
###############################################################################
from pyro.dynamic import pendulum
from pyro.control import linear
from pyro.control import robotcontrollers
from pyro.analysis import simulation
###############################################################################

sys = pendulum.SinglePendulum()

kp = 200 # 2,4
kd = 100 # 1
ki = 0
dof = 1

ctl = linear.JointPID(sys, kp , ki, kd)
kp = 2 # 2,4
kd = 1 # 1
ki = 1

ctl = robotcontrollers.JointPID( dof, kp , ki, kd)

# Set Point
q_target = np.array([3.14])
Expand Down
6 changes: 3 additions & 3 deletions examples/test_all_examples.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

_all_examples = [
"./bicycle/bicycle.py",
#"./bicycle/bicycle_exploration_with_rrt.py", # Broken, seems to run forever
"./bicycle/bicycle_exploration_with_rrt.py",
"./bicycle/bicycle_parallel_parking_with_rrt.py",
"./cartpole/cartpole_natural_behavior.py",
"./cartpole/cartpole_with_computed_torque.py",
Expand All @@ -39,7 +39,7 @@
"./double_pendulum/double_pendulum.py",
"./double_pendulum/double_pendulum_with_computed_torque.py",
"./double_pendulum/double_pendulum_with_rrt.py",
#"./double_pendulum/double_pendulum_with_rrt_and_computed_torque.py", # Missing class
"./double_pendulum/double_pendulum_with_rrt_and_computed_torque.py",
"./double_pendulum/double_pendulum_with_sliding_mode.py",
"./double_pendulum/double_pendulum_with_trajectory_following_computed_torque.py",
"./double_pendulum/double_pendulum_with_trajectory_following_open_loop_controller.py",
Expand All @@ -64,7 +64,7 @@
"./simple_pendulum/custom_simple_pendulum.py",
"./simple_pendulum/simple_pendulum_with_computed_torque.py",
"./simple_pendulum/simple_pendulum_with_open_loop_controller.py",
#"./simple_pendulum/simple_pendulum_with_pid.py", # Missing class
"./simple_pendulum/simple_pendulum_with_pid.py",
"./simple_pendulum/simple_pendulum_with_rrt.py",
"./simple_pendulum/simple_pendulum_with_sliding_mode_controller.py",
"./simple_pendulum/simple_pendulum_with_trajectory_following_computed_torque.py",
Expand Down

0 comments on commit 2c94091

Please sign in to comment.