File tree Expand file tree Collapse file tree 2 files changed +29
-0
lines changed Expand file tree Collapse file tree 2 files changed +29
-0
lines changed Original file line number Diff line number Diff line change
1
+ import roboticstoolbox as rtb
2
+
3
+ # load a model with inertial parameters
4
+ p560 = rtb .models .DH .Puma560 ()
5
+
6
+ # remove Coulomb friction
7
+ p560 = p560 .nofriction ()
8
+
9
+ # print the kinematic & dynamic parameters
10
+ p560 .printdyn ()
11
+
12
+ # simulate motion over 5s with zero torque input
13
+ d = p560 .fdyn (5 , p560 .qr , dt = 0.05 )
14
+
15
+ # show the joint angle trajectory
16
+ rtb .tools .trajectory .qplot (d .q )
17
+
18
+ # animate it
19
+ p560 .plot (d .q .T ) # movie='falling_puma.gif')
Original file line number Diff line number Diff line change
1
+ import roboticstoolbox as rtb
2
+ from spatialmath import *
3
+
4
+
5
+ p560 = rtb .models .DH .Puma560 ()
6
+ print (p560 )
7
+ tw , T0 = p560 .twists (p560 .qn )
8
+ print (tw )
9
+ qt = rtb .tools .trajectory .jtraj (p560 .qr , p560 .qz , 50 )
10
+ p560 .plot (qt .q .T , dt = 100 , movie = 'puma_sitting.gif' )
You can’t perform that action at this time.
0 commit comments