Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
Software for White Rabbit PTP Core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
32
Issues
32
List
Board
Labels
Milestones
Merge Requests
6
Merge Requests
6
CI / CD
CI / CD
Pipelines
Schedules
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
Software for White Rabbit PTP Core
Commits
d5d116fd
Commit
d5d116fd
authored
Dec 11, 2023
by
Tristan Gingold
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
libertm: fix warnings in aux_logger.c
parent
9f38928c
Pipeline
#5056
failed with stage
in 3 minutes and 46 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
7 deletions
+5
-7
aux_logger.c
libertm/aux_logger.c
+5
-7
No files found.
libertm/aux_logger.c
View file @
d5d116fd
...
...
@@ -194,8 +194,6 @@ void spll_readout_ertm14( struct ertm_status *handle, FILE* f_out, int undersamp
void
linspace
(
double
start
,
double
stop
,
int
n
,
double
*
out
)
{
double
step
=
(
stop
-
start
)
/
(
double
)(
n
-
1
);
int
i
;
for
(
i
=
0
;
i
<
n
;
i
++
)
{
...
...
@@ -231,7 +229,7 @@ int wait_wdiag_bits( struct ertm_status *handle, uint32_t mask, int timeout_secs
return
0
;
}
main
(
)
int
main
(
void
)
{
static
char
usb
[]
=
"/dev/ttyUSB2"
;
struct
ertm_status
*
handle
=
ertm_init
(
NULL
);
...
...
@@ -269,8 +267,8 @@ main()
for
(
pp
=
0
;
pp
<
n_kp_gains
;
pp
++
)
{
char
cmd
[
64
],
fname
[
64
];
printf
(
"Try kp=%
d,ki=%d
\n
"
,
-
kp_gains
[
pp
],
-
ki_gains
[
ii
]
);
sprintf
(
cmd
,
"pll gain 0 0 %
d %d
\n
"
,
-
kp_gains
[
pp
],
-
ki_gains
[
ii
]
);
printf
(
"Try kp=%
f,ki=%f
\n
"
,
-
kp_gains
[
pp
],
-
ki_gains
[
ii
]
);
sprintf
(
cmd
,
"pll gain 0 0 %
f %f
\n
"
,
-
kp_gains
[
pp
],
-
ki_gains
[
ii
]
);
ertm_execute_shell_command
(
handle
,
cmd
);
usleep
(
100000
);
ertm_execute_shell_command
(
handle
,
"pll init 4 0 0"
);
...
...
@@ -285,9 +283,9 @@ main()
}
total_samples
=
0
;
sprintf
(
fname
,
"spll-helper-kp-%
d-ki-%d
.dat"
,
kp_gains
[
pp
],
ki_gains
[
ii
]);
sprintf
(
fname
,
"spll-helper-kp-%
f-ki-%f
.dat"
,
kp_gains
[
pp
],
ki_gains
[
ii
]);
FILE
*
f_out
=
fopen
(
fname
,
"wb"
);
fprintf
(
f_out
,
"main kp=%
d ki=%d
\n
"
,
-
kp_gains
[
pp
],
-
ki_gains
[
ii
]);
fprintf
(
f_out
,
"main kp=%
f ki=%f
\n
"
,
-
kp_gains
[
pp
],
-
ki_gains
[
ii
]);
spll_readout_ertm14
(
handle
,
f_out
,
3
);
fclose
(
f_out
);
fflush
(
stdout
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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