Skip to content

Commit a6e77f0

Browse files
committed
Fix tests
1 parent e98cfe1 commit a6e77f0

File tree

7 files changed

+9
-16
lines changed

7 files changed

+9
-16
lines changed

examples/lqr_pendulum.jl

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ joint_axis = [1.0;0.0;0.0]
99

1010
length1 = 1.0
1111
width, depth = 0.1, 0.1
12-
box = Box(width, depth, length1, length1)
1312

1413
p2 = [0.0;0.0;length1/2] # joint connection point
1514

@@ -18,7 +17,7 @@ p2 = [0.0;0.0;length1/2] # joint connection point
1817

1918
# Links
2019
origin = Origin{Float64}()
21-
link1 = Body(box)
20+
link1 = Box(width, depth, length1, length1)
2221

2322
# Constraints
2423
joint_between_origin_and_link1 = EqualityConstraint(Revolute(origin, link1, joint_axis; p2=p2))

examples/lqr_prismatic.jl

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,10 @@ joint_axis = [1.0;0.0;0.0]
99

1010
length1 = 1.0
1111
width, depth = 0.1, 0.1
12-
box = Box(width, depth, width, length1)
1312

1413
# Links
1514
origin = Origin{Float64}()
16-
link1 = Body(box)
15+
link1 = Box(width, depth, width, length1)
1716

1817
# Constraints
1918
joint_between_origin_and_link1 = EqualityConstraint(Prismatic(origin, link1, joint_axis))

examples/pid_doublependulum.jl

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ joint_axis = [1.0;0.0;0.0]
77

88
length1 = 1.0
99
width, depth = 0.1, 0.1
10-
box = Box(width, depth, length1, length1, color = RGBA(1., 1., 0.))
1110

1211
p2 = [0.0;0.0;length1 / 2] # joint connection point
1312

@@ -19,8 +18,8 @@ q2 = UnitQuaternion(RotX(ϕ2))
1918

2019
# Links
2120
origin = Origin{Float64}()
22-
link1 = Body(box)
23-
link2 = Body(box)
21+
link1 = Box(width, depth, length1, length1, color = RGBA(1., 1., 0.))
22+
link2 = deepcopy(link1)
2423

2524
# Constraints
2625
joint1 = EqualityConstraint(Revolute(origin, link1, joint_axis; p2=p2))

examples/pid_pendulum.jl

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ joint_axis = [1.0;0.0;0.0]
77

88
length1 = 1.0
99
width, depth = 0.1, 0.1
10-
box = Box(width, depth, length1, length1, color = RGBA(1., 1., 0.))
1110

1211
p2 = [0.0;0.0;length1 / 2] # joint connection point
1312

@@ -17,7 +16,7 @@ q1 = UnitQuaternion(RotX(ϕ1))
1716

1817
# Links
1918
origin = Origin{Float64}()
20-
link1 = Body(box)
19+
link1 = Box(width, depth, length1, length1, color = RGBA(1., 1., 0.))
2120

2221
# Constraints
2322
joint_between_origin_and_link1 = EqualityConstraint(Revolute(origin, link1, joint_axis; p2=p2))

test/examples/lqr_pendulum.jl

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ joint_axis = [1.0;0.0;0.0]
88

99
length1 = 1.0
1010
width, depth = 0.1, 0.1
11-
box = Box(width, depth, length1, length1)
1211

1312
p2 = [0.0;0.0;length1/2] # joint connection point
1413

@@ -17,7 +16,7 @@ p2 = [0.0;0.0;length1/2] # joint connection point
1716

1817
# Links
1918
origin = Origin{Float64}()
20-
link1 = Body(box)
19+
link1 = Box(width, depth, length1, length1)
2120

2221
# Constraints
2322
joint_between_origin_and_link1 = EqualityConstraint(Revolute(origin, link1, joint_axis; p2=p2))

test/examples/lqr_prismatic.jl

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,10 @@ joint_axis = [1.0;0.0;0.0]
88

99
length1 = 1.0
1010
width, depth = 0.1, 0.1
11-
box = Box(width, depth, width, length1)
1211

1312
# Links
1413
origin = Origin{Float64}()
15-
link1 = Body(box)
14+
link1 = Box(width, depth, width, length1)
1615

1716
# Constraints
1817
joint_between_origin_and_link1 = EqualityConstraint(Prismatic(origin, link1, joint_axis))

test/examples/pid_doublependulum.jl

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ joint_axis = [1.0;0.0;0.0]
66

77
length1 = 1.0
88
width, depth = 0.1, 0.1
9-
box = Box(width, depth, length1, length1, color = RGBA(1., 1., 0.))
109

1110
p2 = [0.0;0.0;length1 / 2] # joint connection point
1211

@@ -18,8 +17,8 @@ q2 = UnitQuaternion(RotX(ϕ2))
1817

1918
# Links
2019
origin = Origin{Float64}()
21-
link1 = Body(box)
22-
link2 = Body(box)
20+
link1 = Box(width, depth, length1, length1, color = RGBA(1., 1., 0.))
21+
link2 = deepcopy(link1)
2322

2423
# Constraints
2524
joint1 = EqualityConstraint(Revolute(origin, link1, joint_axis; p2=p2))

0 commit comments

Comments
 (0)