ARM9教程DSP教程FPGA教程CPLD教程12A软硬件设计0229
// field and initialize the head, tail and busy fields to 0 typedef struct {
char * buffer; int buffer_size; int head; int tail;
} srl0_receive_buffer_t;
typedef struct {
char * buffer; int buffer_size; int head; int tail; int busy;
} srl0_transmit_buffer_t;
//.............................................................................. // Send byte - send immediately if possible, otherwise queue in buffer and // send in interrupt handler
void srl0_send_byte ( unsigned int base, unsigned char val, srl0_transmit_buffer_t *buffer );
//.............................................................................. // Receive byte - will return // 0 if no value in buf, // 1 if value in buf.
// Buffer is populated by interrupt handler
int srl0_receive_byte(srl0_receive_buffer_t *buffer, char *buf);
//..............................................................................
百度搜索“77cn”或“免费范文网”即可找到本站免费阅读全部范文。收藏本站方便下次阅读,免费范文网,提供经典小说教育文库ARM9教程DSP教程FPGA教程CPLD教程12A软硬件设计0229(6)在线全文阅读。
相关推荐: