annotate src/pt1_common.h @ 177:1d6674183e76

Fix problem: If do not specify DLNA, will not call pthread_join(stream_thread,)
author Naoya OYAMA <naoya.oyama@gmail.com>
date Wed, 07 Nov 2012 22:54:19 +0900
parents 4f3640bf350d
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
165
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
1 /* pt1_common.h -- This file is part of recpt1.
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
2
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
3 Copyright 2012 Naoya OYAMA <naoya.oyama@gmail.com>
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
4
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
5 This program is free software: you can redistribute it and/or modify
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
6 it under the terms of the GNU General Public License as published by
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
7 the Free Software Foundation, either version 3 of the License, or
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
8 (at your option) any later version.
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
9
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
10 This program is distributed in the hope that it will be useful,
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
13 GNU General Public License for more details.
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
14
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
15 You should have received a copy of the GNU General Public License
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
16 along with this program. If not, see <http://www.gnu.org/licenses/>. */
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
17
168
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
18 #ifndef _RECPT1_COMMON_H_
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
19 #define _RECPT1_COMMON_H_
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
20
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
21 #include "pt1_dev.h"
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
22 #include "recpt1.h"
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
23
165
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
24 /* ipc message size */
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
25 #define MSGSZ 255
168
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
26 #define ISDB_T_NODE_LIMIT 24 // 32:ARIB limit 24:program maximum
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
27 #define ISDB_T_SLOT_LIMIT 8
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
28 #define MAX_RETRY (2)
165
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
29
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
30 typedef struct pt1_msgbuf {
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
31 long mtype;
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
32 char mtext[MSGSZ];
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
33 } pt1_message_buf;
3ffef0e5b80a Add pt1_common.h
Naoya OYAMA <naoya.oyama@gmail.com>
parents:
diff changeset
34
168
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
35 //prototaype
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
36 int tune(char *channel, thread_data *tdata, char *device);
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
37 int close_tuner(thread_data *tdata);
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
38 void show_channels(void);
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
39 ISDB_T_FREQ_CONV_TABLE *searchrecoff(char *channel);
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
40 void calc_cn(int fd, int type, boolean use_bell);
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
41 int tune(char *channel, thread_data *tdata, char *device);
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
42 int close_tuner(thread_data *tdata);
170
4f3640bf350d Change display name of DLNA.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 168
diff changeset
43 uint16_t get_device_id_by_name(char *device_name);
168
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
44
061ef2cd98f0 Code refactoring.
Naoya OYAMA <naoya.oyama@gmail.com>
parents: 165
diff changeset
45 #endif