Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
elphel-apps-camogm
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Elphel
elphel-apps-camogm
Commits
ec1f0c4e
Commit
ec1f0c4e
authored
Dec 05, 2016
by
Mikhail Karpenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Select port only from the list of active ports
parent
48e8d081
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
0 deletions
+8
-0
camogm.c
src/camogm.c
+8
-0
No files found.
src/camogm.c
View file @
ec1f0c4e
...
@@ -1755,6 +1755,14 @@ unsigned int select_port(camogm_state *state)
...
@@ -1755,6 +1755,14 @@ unsigned int select_port(camogm_state *state)
off_t
file_pos
;
off_t
file_pos
;
off_t
min_sz
=
-
1
;
off_t
min_sz
=
-
1
;
// define first active channel in case not all of them are active
for
(
int
i
=
0
;
i
<
SENSOR_PORTS
;
i
++
)
{
if
(
is_chn_active
(
state
,
i
))
{
chn
=
i
;
break
;
}
}
if
(
state
->
prog_state
==
STATE_STARTING
||
state
->
prog_state
==
STATE_RUNNING
)
if
(
state
->
prog_state
==
STATE_STARTING
||
state
->
prog_state
==
STATE_RUNNING
)
D6
(
fprintf
(
debug_file
,
"Selecting sensor port, buffer free size: "
));
D6
(
fprintf
(
debug_file
,
"Selecting sensor port, buffer free size: "
));
for
(
int
i
=
0
;
i
<
SENSOR_PORTS
;
i
++
)
{
for
(
int
i
=
0
;
i
<
SENSOR_PORTS
;
i
++
)
{
...
...
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