Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
R3ABM Artem
DigestPlay
Commits
322f562f
Commit
322f562f
authored
May 26, 2017
by
Artem Prilutskiy
Browse files
..
parent
14fe868d
Changes
2
Hide whitespace changes
Inline
Side-by-side
DigestPlay.c
View file @
322f562f
...
...
@@ -54,7 +54,7 @@ int main(int argc, char* argv[])
{
"client-number"
,
required_argument
,
NULL
,
'c'
},
{
"server-address"
,
required_argument
,
NULL
,
's'
},
{
"server-port"
,
required_argument
,
NULL
,
'p'
},
{
"source-id"
,
required_argument
,
NULL
,
'
i
'
},
{
"source-id"
,
required_argument
,
NULL
,
'
u
'
},
{
"group-id"
,
required_argument
,
NULL
,
'g'
},
{
"talker-alias"
,
required_argument
,
NULL
,
't'
},
{
NULL
,
0
,
NULL
,
0
}
...
...
@@ -64,7 +64,7 @@ int main(int argc, char* argv[])
int
control
=
0
;
int
selection
=
0
;
while
((
selection
=
getopt_long
(
argc
,
argv
,
"w:c:s:p:
i
:g:t:"
,
options
,
NULL
))
!=
EOF
)
while
((
selection
=
getopt_long
(
argc
,
argv
,
"w:c:s:p:
u
:g:t:"
,
options
,
NULL
))
!=
EOF
)
switch
(
selection
)
{
case
'w'
:
...
...
@@ -86,7 +86,7 @@ int main(int argc, char* argv[])
control
|=
0
b00100
;
break
;
case
'
i
'
:
case
'
u
'
:
value
=
strtol
(
optarg
,
NULL
,
10
);
if
(
value
>
0
)
{
...
...
@@ -187,18 +187,22 @@ int main(int argc, char* argv[])
uint64_t
mark
;
size_t
count
=
0
;
uint8_t
*
pointer
;
uint8_t
*
limit
=
buffer
+
3
*
DSD_AMBE_CHUNK_SIZE
;
// Wait for timer event (60 milliseconds)
while
(
read
(
handle
,
&
mark
,
sizeof
(
uint64_t
))
>
0
)
{
// Read AMBE chunks
of
DSD format
// Read AMBE chunks
in
DSD format
ssize_t
length1
=
read
(
STDIN_FILENO
,
buffer
+
0
*
DSD_AMBE_CHUNK_SIZE
,
DSD_AMBE_CHUNK_SIZE
);
ssize_t
length2
=
read
(
STDIN_FILENO
,
buffer
+
1
*
DSD_AMBE_CHUNK_SIZE
,
DSD_AMBE_CHUNK_SIZE
);
ssize_t
length3
=
read
(
STDIN_FILENO
,
buffer
+
2
*
DSD_AMBE_CHUNK_SIZE
,
DSD_AMBE_CHUNK_SIZE
);
pointer
=
buffer
;
while
((
pointer
<
limit
)
&&
(
read
(
STDIN_FILENO
,
pointer
,
DSD_AMBE_CHUNK_SIZE
)
==
DSD_AMBE_CHUNK_SIZE
))
{
pointer
+=
DSD_AMBE_CHUNK_SIZE
;
}
if
((
length1
!=
DSD_AMBE_CHUNK_SIZE
)
||
(
length2
!=
DSD_AMBE_CHUNK_SIZE
)
||
(
length3
!=
DSD_AMBE_CHUNK_SIZE
))
if
(
pointer
<
limit
)
{
printf
(
"Input data stream stopped
\n
"
);
break
;
...
...
RewindClient.c
View file @
322f562f
...
...
@@ -109,7 +109,7 @@ struct RewindContext* CreateRewindContext(uint32_t number, const char* verion)
return
NULL
;
}
// Create suppl
i
mentary data
// Create suppl
e
mentary data
uname
(
&
name
);
...
...
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