Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
A
adc-lib
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
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
adc-lib
Commits
97531247
Commit
97531247
authored
Aug 11, 2020
by
Federico Vaga
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lib: adc100m software trigger interface changed
Signed-off-by:
Federico Vaga
<
federico.vaga@cern.ch
>
parent
4c99d46f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
4 deletions
+18
-4
fmc-adc-100m14b4cha.c
lib/fmc-adc-100m14b4cha.c
+18
-4
No files found.
lib/fmc-adc-100m14b4cha.c
View file @
97531247
...
...
@@ -871,10 +871,24 @@ static int adc_100m14b4cha_retrieve_config(struct adc_dev *dev,
*/
static
int
adc_100m14b4cha_trigger_fire
(
struct
adc_dev
*
dev
)
{
int
value
=
1
;
return
adc_set_param
(
dev
,
"cset0/trigger/sw-trg-fire"
,
NULL
,
&
value
);
struct
__adc_dev_zio
*
fa
=
to_dev_zio
(
dev
);
char
pathname
[
128
];
int
fd
,
ret
;
snprintf
(
pathname
,
sizeof
(
pathname
),
"/sys/kernel/debug/adc-100m14b-%04x/trigger_software"
,
fa
->
dev_id
);
fd
=
open
(
pathname
,
O_WRONLY
);
if
(
fd
<
0
)
return
-
1
;
ret
=
write
(
fd
,
"1"
,
1
);
close
(
fd
);
if
(
ret
<
0
)
return
-
1
;
if
(
ret
==
1
)
return
0
;
errno
=
EIO
;
return
-
1
;
}
static
int
adc_100m14b4cha_buffer_get_sample
(
struct
adc_buffer
*
buf
,
...
...
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