Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc
Commits
6c12d019
Commit
6c12d019
authored
Mar 30, 2011
by
Ilkka Ollakka
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dvb: return value from decode_BCD
parent
3c4fc2f3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
11 deletions
+7
-11
modules/access/dvb/scan.c
modules/access/dvb/scan.c
+7
-11
No files found.
modules/access/dvb/scan.c
View file @
6c12d019
...
...
@@ -148,15 +148,15 @@ static void scan_service_Delete( scan_service_t *p_srv )
free
(
p_srv
);
}
static
int
decode_BCD
(
uint32_t
input
,
uint32_t
*
out
put
)
static
uint32_t
decode_BCD
(
uint32_t
in
put
)
{
*
output
=
0
;
uint32_t
output
=
0
;
for
(
short
index
=
28
;
index
>=
0
;
index
-=
4
)
{
*
output
*=
10
;
*
output
+=
((
input
>>
index
)
&
0x0f
);
output
*=
10
;
output
+=
((
input
>>
index
)
&
0x0f
);
};
return
VLC_SUCCESS
;
return
output
;
}
static
int
scan_service_type
(
int
service_type
)
...
...
@@ -890,13 +890,9 @@ static void NITCallBack( scan_session_t *p_session, dvbpsi_nit_t *p_nit )
dvbpsi_cable_deliv_sys_dr_t
*
p_t
=
dvbpsi_DecodeCableDelivSysDr
(
p_dsc
);
msg_Dbg
(
p_obj
,
" * Cable delivery system"
);
if
(
decode_BCD
(
p_t
->
i_frequency
,
&
p_cfg
->
i_frequency
)
<
0
)
return
;
p_cfg
->
i_frequency
*=
100
;
pcfg
->
i_freqency
=
decode_BCD
(
p_t
->
i_frequency
)
*
100
;
msg_Dbg
(
p_obj
,
" * frequency %d"
,
p_cfg
->
i_frequency
);
if
(
decode_BCD
(
p_t
->
i_symbol_rate
,
&
p_cfg
->
i_symbolrate
)
<
0
)
return
;
p_cfg
->
i_symbolrate
*=
100
;
p_cfg
->
i_symbolrate
=
decode_BCD
(
p_t
->
i_symbol_rate
)
*
100
;
msg_Dbg
(
p_obj
,
" * symbolrate %u"
,
p_cfg
->
i_symbolrate
);
p_cfg
->
i_modulation
=
(
8
<<
p_t
->
i_modulation
);
msg_Dbg
(
p_obj
,
" * modulation %u"
,
p_cfg
->
i_modulation
);
...
...
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