![](/media/cache/profiles/98c39996bf1543e974747a2549b3107c.50x50_q85.png)
For BU9480F D-A Conv.
Diff: _bitio.h
- Revision:
- 0:805cffac956b
- Child:
- 1:02bfb013660c
diff -r 000000000000 -r 805cffac956b _bitio.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/_bitio.h Thu Aug 26 12:48:50 2010 +0000 @@ -0,0 +1,32 @@ +#ifndef ___BITIO_H__ +#define ___BITIO_H__ + +#define TRUE 1 +#define FALSE 0 +#define rightbits(n, x) ((x) & ((1U << (n)) - 1U)) + +#define OVERRUN 0xffff +#define k 0x0b // k:0x09 to 0x0b? + +typedef unsigned int Uint; +typedef unsigned char Uchar; + +extern FILE *infp, *outfp; +extern int getcount, putcount; +extern Uint bitbuf; + +/* Rice Golomb en-decoding */ +extern void decode(void); +extern void encode(long int n); + + +void init_bit_o(void); +void init_bit_i(void); +Uint getbit(void); +Uint getbits(int n); +void putbit(Uint bit); +void putbits(int n, Uint x); + + + +#endif \ No newline at end of file