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
2f50a3df
Commit
2f50a3df
authored
7 years ago
by
dawehr
Browse files
Options
Downloads
Patches
Plain Diff
Properly escaping % sign in log now.
parent
b3fafe96
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
quad/src/quad_app/log_data.c
+4
-5
4 additions, 5 deletions
quad/src/quad_app/log_data.c
with
4 additions
and
5 deletions
quad/src/quad_app/log_data.c
+
4
−
5
View file @
2f50a3df
...
@@ -112,14 +112,13 @@ void initialize_logging(log_t* log_struct, parameter_t* ps) {
...
@@ -112,14 +112,13 @@ void initialize_logging(log_t* log_struct, parameter_t* ps) {
addOutputToLog
(
log_struct
,
ps
->
vrpn_alt
,
CONST_VAL
,
m
);
addOutputToLog
(
log_struct
,
ps
->
vrpn_alt
,
CONST_VAL
,
m
);
addOutputToLog
(
log_struct
,
ps
->
vrpn_pitch
,
CONST_VAL
,
rad
);
addOutputToLog
(
log_struct
,
ps
->
vrpn_pitch
,
CONST_VAL
,
rad
);
addOutputToLog
(
log_struct
,
ps
->
vrpn_roll
,
CONST_VAL
,
rad
);
addOutputToLog
(
log_struct
,
ps
->
vrpn_roll
,
CONST_VAL
,
rad
);
addOutputToLog
(
log_struct
,
ps
->
x_set
,
CONST_VAL
,
m
);
addOutputToLog
(
log_struct
,
ps
->
y_set
,
CONST_VAL
,
m
);
addOutputToLog
(
log_struct
,
ps
->
alt_set
,
CONST_VAL
,
m
);
addOutputToLog
(
log_struct
,
ps
->
yaw_set
,
CONST_VAL
,
rad
);
addOutputToLog
(
log_struct
,
ps
->
mixer
,
MIXER_PWM0
,
pwm_val
);
addOutputToLog
(
log_struct
,
ps
->
mixer
,
MIXER_PWM0
,
pwm_val
);
addOutputToLog
(
log_struct
,
ps
->
mixer
,
MIXER_PWM1
,
pwm_val
);
addOutputToLog
(
log_struct
,
ps
->
mixer
,
MIXER_PWM1
,
pwm_val
);
addOutputToLog
(
log_struct
,
ps
->
mixer
,
MIXER_PWM2
,
pwm_val
);
addOutputToLog
(
log_struct
,
ps
->
mixer
,
MIXER_PWM2
,
pwm_val
);
addOutputToLog
(
log_struct
,
ps
->
mixer
,
MIXER_PWM3
,
pwm_val
);
addOutputToLog
(
log_struct
,
ps
->
mixer
,
MIXER_PWM3
,
pwm_val
);
addOutputToLog
(
log_struct
,
ps
->
rc_throttle
,
PID_CORRECTION
,
pwm_val
);
addOutputToLog
(
log_struct
,
ps
->
rc_pitch
,
PID_CORRECTION
,
pwm_val
);
addOutputToLog
(
log_struct
,
ps
->
rc_roll
,
PID_CORRECTION
,
pwm_val
);
// TODO: Make this not stupid. Adding 6 for IMU and 1 for timestamp
// TODO: Make this not stupid. Adding 6 for IMU and 1 for timestamp
row_size
=
n_outputs
+
n_params
+
6
+
1
;
row_size
=
n_outputs
+
n_params
+
6
+
1
;
...
@@ -185,7 +184,7 @@ void printLogging(hardware_t *hardware_struct, log_t* log_struct, parameter_t* p
...
@@ -185,7 +184,7 @@ void printLogging(hardware_t *hardware_struct, log_t* log_struct, parameter_t* p
// Comment header
// Comment header
safe_sprintf_cat
(
&
buf
,
"# MicroCART On-board Quad Log
\n
# Sample size: %d
\n
"
,
arrayIndex
);
safe_sprintf_cat
(
&
buf
,
"# MicroCART On-board Quad Log
\n
# Sample size: %d
\n
"
,
arrayIndex
);
// Header names for the pre-defined values
// Header names for the pre-defined values
safe_sprintf_cat
(
&
buf
,
"%Time
\t
accel_x
\t
accel_y
\t
accel_z
\t
gyro_x
\t
gyro_y
\t
gyro_z"
);
safe_sprintf_cat
(
&
buf
,
"%
%
Time
\t
accel_x
\t
accel_y
\t
accel_z
\t
gyro_x
\t
gyro_y
\t
gyro_z"
);
int
i
;
int
i
;
// Print all the recorded block parameters
// Print all the recorded block parameters
...
...
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