annotate src/condat/com/include/cl_ribu.h @ 4:6e457872f745

src/condat: hybrid import from Magnetite
author Mychaela Falconia <falcon@freecalypso.org>
date Sun, 15 Jul 2018 08:01:56 +0000
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
4
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
1 /*
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
2 +-----------------------------------------------------------------------------
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
3 | Project : COMLIB
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
4 | Modul : cl_ribu
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
5 +-----------------------------------------------------------------------------
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
6 | Copyright 2002 Texas Instruments Berlin, AG
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
7 | All rights reserved.
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
8 |
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
9 | This file is confidential and a trade secret of Texas
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
10 | Instruments Berlin, AG
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
11 | The receipt of or possession of this file does not convey
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
12 | any rights to reproduce or disclose its contents or to
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
13 | manufacture, use, or sell anything it may describe, in
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
14 | whole, or in part, without the specific written consent of
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
15 | Texas Instruments Berlin, AG.
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
16 +-----------------------------------------------------------------------------
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
17 | Purpose : Definitions of global types used by common library functions
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
18 | and the prototypes of those functions.
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
19 +-----------------------------------------------------------------------------
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
20 */
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
21 /*
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
22 * Version 1.0
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
23 */
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
24
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
25 /**********************************************************************************/
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
26
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
27 #ifndef CL_RIBU_H
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
28 #define CL_RIBU_H
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
29
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
30 /**********************************************************************************/
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
31
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
32 typedef struct
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
33 {
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
34 U8 ri; /* ring buffer read index */
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
35 U8 wi; /* ring buffer write index */
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
36 U8 depth; /* ring buffer depth */
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
37 U8 filled; /* ring buffer filled flag */
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
38 } T_RIBU;
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
39
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
40 typedef struct
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
41 {
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
42 U8 type;
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
43 U8 status;
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
44 U8 len; /* buffer length */
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
45 U8 *buf; /* buffer start address */
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
46 } T_FD; /* frame descriptor */
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
47
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
48 typedef struct
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
49 {
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
50 T_RIBU idx;
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
51 T_FD **pFDv; /* frame descriptor vector */
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
52 } T_RIBU_FD;
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
53
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
54 /**********************************************************************************/
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
55
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
56 EXTERN void cl_ribu_create(T_RIBU_FD **ribu, const U8 buflen, const U8 depth);
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
57 EXTERN void cl_ribu_release(T_RIBU_FD **ribu);
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
58
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
59 EXTERN void cl_ribu_put(const T_FD fd, T_RIBU_FD *ribu);
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
60 EXTERN T_FD *cl_ribu_get(T_RIBU_FD *ribu);
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
61 EXTERN T_FD *cl_ribu_get_new_frame_desc(T_RIBU_FD *ribu);
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
62
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
63 EXTERN void cl_ribu_init(T_RIBU *ribu, const U8 depth);
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
64 EXTERN U8 cl_ribu_read_index(T_RIBU *ribu);
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
65 EXTERN U8 cl_ribu_write_index(T_RIBU *ribu);
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
66 EXTERN BOOL cl_ribu_data_avail(const T_RIBU_FD *ribu);
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
67
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
68 EXTERN void cl_set_frame_desc(T_FRAME_DESC *frame_desc, U8 *A0, U16 L0, U8 *A1, U16 L1);
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
69 EXTERN void cl_set_frame_desc_0(T_FRAME_DESC *frame_desc, U8 *A0, U16 L0);
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
70
6e457872f745 src/condat: hybrid import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
71 #endif /* CL_RIBU_H */