123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
-
-
- #ifndef serial_h_
- #define serial_h_
-
-
- #define RX_BUFFER_SIZE 32
- #define TX_BUFFER_SIZE 32
-
-
- #define UART_BAUD_SELECT(baudRate,xtalCpu) ((xtalCpu)/((baudRate)*16l)-1)
-
- #define ODD 2
- #define EVEN 1
- #define NONE 0
-
- uint8_t serialInit(uint16_t baud, uint8_t databits, uint8_t parity, uint8_t stopbits);
-
- uint8_t serialHasChar(void);
- uint8_t serialGet(void);
-
-
- uint8_t serialBufferSpaceRemaining(void);
- void serialWrite(uint8_t data);
- void serialWriteString(char *data);
-
- void serialClose(void);
-
- #endif
|