Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Q
quadruped-reactive-walking
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Gepetto
quadruped-reactive-walking
Commits
f1948995
Commit
f1948995
authored
2 years ago
by
Fanny Risbourg
Browse files
Options
Downloads
Patches
Plain Diff
use the measured q and v
parent
4486e653
No related branches found
No related tags found
No related merge requests found
Pipeline
#20766
failed
2 years ago
Stage: test
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
python/quadruped_reactive_walking/Controller.py
+4
-4
4 additions, 4 deletions
python/quadruped_reactive_walking/Controller.py
with
4 additions
and
4 deletions
python/quadruped_reactive_walking/Controller.py
+
4
−
4
View file @
f1948995
...
@@ -163,7 +163,7 @@ class Controller:
...
@@ -163,7 +163,7 @@ class Controller:
if
self
.
params
.
interpolate_mpc
:
if
self
.
params
.
interpolate_mpc
:
q
,
v
=
self
.
interpolate_x
(
self
.
cnt_wbc
*
self
.
pd
.
dt_wbc
)
q
,
v
=
self
.
interpolate_x
(
self
.
cnt_wbc
*
self
.
pd
.
dt_wbc
)
else
:
else
:
q
,
v
=
self
.
integrate_x
()
q
,
v
=
self
.
integrate_x
(
m
)
self
.
q
[
3
:
6
]
=
q
self
.
q
[
3
:
6
]
=
q
self
.
v
[
3
:
6
]
=
v
self
.
v
[
3
:
6
]
=
v
...
@@ -323,13 +323,13 @@ class Controller:
...
@@ -323,13 +323,13 @@ class Controller:
return
q_t
,
v_t
return
q_t
,
v_t
def
integrate_x
(
self
):
def
integrate_x
(
self
,
m
):
"""
"""
Integrate the position and velocity using the acceleration computed from the
Integrate the position and velocity using the acceleration computed from the
feedforward torque
feedforward torque
"""
"""
q0
=
self
.
result
.
q_des
[
3
:
6
]
q0
=
m
[
"
qj_m
"
]
[
3
:
6
]
v0
=
self
.
result
.
v_des
[
3
:
6
]
v0
=
m
[
"
vj_m
"
]
[
3
:
6
]
a
=
pin
.
aba
(
self
.
pd
.
model
,
self
.
pd
.
rdata
,
q0
,
v0
,
self
.
result
.
tau_ff
[
3
:
6
])
a
=
pin
.
aba
(
self
.
pd
.
model
,
self
.
pd
.
rdata
,
q0
,
v0
,
self
.
result
.
tau_ff
[
3
:
6
])
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment