/* * File: serial.h * Author: justin * * Created on 17 June 2013, 16:08 */ #ifndef SERIAL_H #define SERIAL_H extern char outbuff[]; char inbuff[]; void serial_init(void); bool msg_empty(void); void msg_write(const char *msg); void msg_writebyte(const char msg); void msg_sendnext(void); void msg_recvnext(void); bool msg_recvready(void); char msg_recv(void); void putch(char); /* TODO Connect serial interupt handlers * * if (PIE1bits.TXIE && PIR1bits.TXIF) * msg_sendnext(); * * if (PIE1bits.RCIE && PIR1bits.RCIF) * msg_recvnext(); * */ #endif /* SERIAL_H */