Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
MicroCART
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor 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
Distributed Autonomous Networked Control Lab
MicroCART
Commits
395b1a62
Commit
395b1a62
authored
7 years ago
by
ucart
Browse files
Options
Downloads
Patches
Plain Diff
added plots for of
parent
48d0f23d
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
controls/DataAnalysisTool/Tool/simplePlots.m
+23
-0
23 additions, 0 deletions
controls/DataAnalysisTool/Tool/simplePlots.m
with
23 additions
and
0 deletions
controls/DataAnalysisTool/Tool/simplePlots.m
+
23
−
0
View file @
395b1a62
...
...
@@ -225,6 +225,24 @@ ax2 = subplot(2, 1, 2);
plot
(
expData
.
Time
.
data
,
expData
.
Altitude_PID_Correction
.
data
);
linkaxes
([
ax1
,
ax2
],
'x'
);
%% Sonar
filtered_sonar
=
[];
last_sonar
=
expData
.
Flow_Distance_Constant
.
data
(
1
);
for
i
=
[
1
:
length
(
expData
.
Flow_Distance_Constant
.
data
)]
this_sonar
=
expData
.
Flow_Distance_Constant
.
data
(
i
);
if
(
abs
(
this_sonar
-
last_sonar
)
<
0.4
)
filtered_sonar
(
i
)
=
this_sonar
;
last_sonar
=
this_sonar
;
else
filtered_sonar
(
i
)
=
last_sonar
;
end
end
alt_offset
=
-
0.04
;
plot
(
expData
.
Time
.
data
,
-
expData
.
Flow_Distance_Constant
.
data
+
alt_offset
);
hold
on
;
plot
(
expData
.
Time
.
data
,
expData
.
VRPN_Alt_Constant
.
data
);
plot
(
expData
.
Time
.
data
,
-
filtered_sonar
+
alt_offset
);
legend
(
'sonar'
,
'vrpn'
,
'dumb filter'
);
%%
figure
;
ax1
=
subplot
(
2
,
1
,
1
);
...
...
@@ -245,3 +263,8 @@ hold off;
linkaxes
([
ax1
,
ax2
]);
%% Integarted gyro yaw
figure
;
plot
(
expData
.
Time
.
data
,
cumtrapz
(
expData
.
gyro_z
.
data
+
0.0088
));
hold
on
;
plot
(
expData
.
Time
.
data
,
expData
.
Yaw_Constant
.
data
);
hold
on
;
legend
(
'Integrated gyro z'
,
'actual yaw'
);
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