Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Stack Of Tasks
sot-torque-control
Commits
e81344ae
Commit
e81344ae
authored
Dec 18, 2017
by
andreadelprete
Browse files
Add test of madgwick
parent
5b56f260
Changes
1
Hide whitespace changes
Inline
Side-by-side
python/dynamic_graph/sot/torque_control/tests/test_magdwick.py
0 → 100644
View file @
e81344ae
# -*- coding: utf-8 -*-
"""
Created on Tue Oct 3 14:01:08 2017
@author: adelpret
"""
from
dynamic_graph.sot.torque_control.madgwickahrs
import
MadgwickAHRS
dt
=
0.001
;
imu_filter
=
MadgwickAHRS
(
'imu_filter'
);
imu_filter
.
init
(
dt
);
imu_filter
.
setBeta
(
0.0
)
for
i
in
range
(
10
):
imu_filter
.
accelerometer
.
value
=
(
0.0
,
0.0
,
9.8
)
imu_filter
.
gyroscope
.
value
=
(
0.001
,
-
1e-3
,
1e-4
)
imu_filter
.
imu_quat
.
recompute
(
i
);
print
imu_filter
.
imu_quat
.
value
\ No newline at end of file
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment