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
d2adf8cd
Commit
d2adf8cd
authored
Jun 05, 2012
by
Tomasz Wlostowski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
software/lib: added function to choose between native and raw readout modes
parent
e624534a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
1 deletion
+12
-1
fdelay_lib.h
software/include/fdelay_lib.h
+4
-0
fdelay_lib.c
software/lib/fdelay_lib.c
+8
-1
No files found.
software/include/fdelay_lib.h
View file @
d2adf8cd
...
@@ -76,6 +76,10 @@ fdelay_device_t *fdelay_create_minibone(char *iface, char *mac_addr, uint32_t ba
...
@@ -76,6 +76,10 @@ fdelay_device_t *fdelay_create_minibone(char *iface, char *mac_addr, uint32_t ba
fdelay_time_t
fdelay_from_picos
(
const
uint64_t
ps
);
fdelay_time_t
fdelay_from_picos
(
const
uint64_t
ps
);
int64_t
fdelay_to_picos
(
const
fdelay_time_t
t
);
int64_t
fdelay_to_picos
(
const
fdelay_time_t
t
);
/* Enables/disables raw timestamp readout mode (debugging only) */
int
fdelay_raw_readout
(
fdelay_device_t
*
dev
,
int
raw_moide
);
/* Initializes and calibrates the device. 0 = success, negative = error */
/* Initializes and calibrates the device. 0 = success, negative = error */
int
fdelay_init
(
fdelay_device_t
*
dev
);
int
fdelay_init
(
fdelay_device_t
*
dev
);
...
...
software/lib/fdelay_lib.c
View file @
d2adf8cd
...
@@ -869,7 +869,7 @@ int fdelay_init(fdelay_device_t *dev)
...
@@ -869,7 +869,7 @@ int fdelay_init(fdelay_device_t *dev)
dev
->
priv_fd
=
(
void
*
)
hw
;
dev
->
priv_fd
=
(
void
*
)
hw
;
hw
->
raw_mode
=
1
;
hw
->
raw_mode
=
0
;
hw
->
base_addr
=
dev
->
base_addr
;
hw
->
base_addr
=
dev
->
base_addr
;
hw
->
base_i2c
=
0x100
;
hw
->
base_i2c
=
0x100
;
hw
->
base_onewire
=
dev
->
base_addr
+
0x500
;
hw
->
base_onewire
=
dev
->
base_addr
+
0x500
;
...
@@ -1129,6 +1129,13 @@ static int poll_rbuf(fdelay_device_t *dev, uint32_t *o_tsbcr)
...
@@ -1129,6 +1129,13 @@ static int poll_rbuf(fdelay_device_t *dev, uint32_t *o_tsbcr)
return
0
;
return
0
;
}
}
int
fdelay_raw_readout
(
fdelay_device_t
*
dev
,
int
raw_mode
)
{
fd_decl_private
(
dev
)
hw
->
raw_mode
=
raw_mode
;
return
0
;
}
/* TODO: chan_mask */
/* TODO: chan_mask */
int
fdelay_configure_readout
(
fdelay_device_t
*
dev
,
int
enable
)
int
fdelay_configure_readout
(
fdelay_device_t
*
dev
,
int
enable
)
{
{
...
...
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