Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
F
FMC DEL 1ns 4cha
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
2
Issues
2
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
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
FMC DEL 1ns 4cha
Commits
a072a95e
Commit
a072a95e
authored
Apr 12, 2012
by
Tomasz Wlostowski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
software/lib: fix compilation error in fdelay_bus.c, disabled long tests by default
parent
66491288
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
10 deletions
+17
-10
Makefile
software/lib/Makefile
+5
-2
fdelay_bus.c
software/lib/fdelay_bus.c
+1
-1
fdelay_lib.c
software/lib/fdelay_lib.c
+11
-7
No files found.
software/lib/Makefile
View file @
a072a95e
CFLAGS
=
-I
../include
-g
-Imini_bone
-Ispll
-DPERFORM_LONG_TESTS
CFLAGS
=
-I
../include
-g
-Imini_bone
-Ispll
OBJS_LIB
=
fdelay_lib.o rr_io.o i2c_master.o onewire.o mini_bone/minibone_lib.o mini_bone/ptpd_netif.o spec_common.o
#uncomment for extra tests (DAC, output stage INL/DNL)
#CFLAGS += -DPERFORM_LONG_TESTS
OBJS_LIB
=
fdelay_lib.o fdelay_bus.o rr_io.o i2c_master.o onewire.o mini_bone/minibone_lib.o mini_bone/ptpd_netif.o spec_common.o
all
:
testprog lib testprog2 testprog3 testprog4
...
...
software/lib/fdelay_bus.c
View file @
a072a95e
...
...
@@ -39,7 +39,7 @@ return d;
fdelay_device_t
*
fdelay_create_rawrabbit
(
uint32_t
base_addr
)
{
fdelay_device_t
*
dev
=
malloc
(
sizeof
(
fdelay_device_t
));
rr_init
(
RR_DEVSEL_
NONE
,
RR_DEVSEL_NONE
);
rr_init
(
RR_DEVSEL_
UNUSED
,
RR_DEVSEL_UNUSED
);
dev
->
writel
=
my_rr_writel
;
dev
->
readl
=
my_rr_readl
;
dev
->
base_addr
=
base_addr
;
...
...
software/lib/fdelay_lib.c
View file @
a072a95e
...
...
@@ -661,11 +661,12 @@ static void measure_linearity(double *x, int n, double *inl, double *dnl)
its linearity, performing an indirect check of the delay lines' and TDC signal connections. */
#define MAX_DNL 20
#define MAX_INL
5
0
#define MAX_INL
6
0
static
int
test_delay_transfer_function
(
fdelay_device_t
*
dev
)
{
double
inl
,
dnl
;
int
lin_fail
=
0
;
fd_decl_private
(
dev
)
...
...
@@ -693,15 +694,18 @@ static int test_delay_transfer_function(fdelay_device_t *dev)
dbg
(
"Linearity: INL = %.1f ps, DNL = %.1f ps
\n
"
,
inl
,
dnl
);
if
(
inl
>
MAX_INL
||
dnl
>
MAX_DNL
)
{
dbg
(
"Linearity check failed.
\n
"
);
fail
(
TEST_DELAY_LINE
,
"Maximum INL/DNL exceeded, indicating a wrong connection of the delay chip and/or the TDC calibration signals"
);
return
-
1
;
}
lin_fail
=
1
;
}
if
(
lin_fail
)
{
dbg
(
"Linearity check failed.
\n
"
);
fail
(
TEST_DELAY_LINE
,
"Maximum INL/DNL exceeded, indicating a wrong connection of the delay chip and/or the TDC calibration signals"
);
return
-
1
;
}
return
0
;
/* FILE *f=fopen("t_func.dat","w");
...
...
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