文件名称:FIFO-C
介绍说明--下载内容均来自于网络,请自行研究使用
FIFO的C语言实现。buffer指向存放数据的缓冲区,size是缓冲区的大小,in是写指针下标,out是读指针下标,在len和(fifo->size - fifo->in + fifo->out)之间取一个较小的值赋给len。注意,当(fifo->in == fifo->out+fifo->size)时,表示缓冲区已满,此时得到的较小值一定是0,后面实际写入的字节数也全为0。-FIFO the C language. buffer point to the storage of data buffer size is the size of the buffer, in a write pointer subscr ipt, out the subscr ipt of the read pointer, len and (fifo-> size- fifo-> in+ fifo-> out) take a smaller value assigned to len. Note when (fifo-> in == fifo-> out+fifo-> size), indicating that the buffer is full, the smaller value obtained must be behind the actual number of bytes written all.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
FIFO C.doc