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
4
Merge Requests
4
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
38e74040
Commit
38e74040
authored
Jan 08, 2015
by
Maciej Lipinski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
added commented out stuff that was tested (for the record)
parent
d1881e01
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
2 deletions
+9
-2
spll_main.c
softpll/spll_main.c
+9
-2
No files found.
softpll/spll_main.c
View file @
38e74040
...
...
@@ -168,7 +168,7 @@ int mpll_update(struct spll_main_state *s, int tag, int source)
avg_update
((
spll_avg_t
*
)
&
s
->
avg_err_short
,
err
);
avg_update
((
spll_avg_t
*
)
&
s
->
avg_err_long
,
err
);
err
=
err
+
s
->
err_slow_drift_corr
;
/// used for testing
/// used for testing
to slow more the error faking -> not good
/// if(phase_adjust_wait==0)
/// {
/// if(s->err_slow_drift_corr > 0) s->err_slow_drift_corr--;
...
...
@@ -337,8 +337,15 @@ int mpll_switchover(struct spll_main_state *mpll, struct spll_backup_state *bpll
// mpll->delock_count = bpll->delock_count;
// mpll->dac_index = bpll->dac_index;
mpll
->
enabled
=
1
;
//bpll->enabled;
//////////////////////////////////////////////////////////////////////////////////////
//this idea turned out to be bad (we get oscillations): -bpll->err_d + mpll->err_d
//mpll->err_slow_drift_corr = -bpll->err_d+mpll->err_d;
//////////////////////////////////////////////////////////////////////////////////////
mpll
->
err_d
=
bpll
->
err_d
;
mpll
->
err_slow_drift_corr
=
-
bpll
->
err_d
;
mpll
->
err_slow_drift_corr
=
-
bpll
->
err_d
;
// this might cause in some cases oscillations as well, need to simuulate
mpll
->
ld
.
lock_cnt
=
mpll
->
ld
.
lock_samples
;
mpll
->
hw_status_d
=
1
;
//up
mpll
->
holdover
=
0
;
...
...
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