aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/platforms/STM32/uart_lld.h
diff options
context:
space:
mode:
authorgdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2010-07-27 10:31:19 +0000
committergdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2010-07-27 10:31:19 +0000
commit79b97b0f60aa6d99667a6bb4d402c420cb6d856e (patch)
tree4943d621333fe3ec88d921d90deb4925bd362be9 /os/hal/platforms/STM32/uart_lld.h
parentb91f48eb105c753ef877752f8dde2c6bbbfea36e (diff)
downloadChibiOS-79b97b0f60aa6d99667a6bb4d402c420cb6d856e.tar.gz
ChibiOS-79b97b0f60aa6d99667a6bb4d402c420cb6d856e.tar.bz2
ChibiOS-79b97b0f60aa6d99667a6bb4d402c420cb6d856e.zip
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@2094 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/hal/platforms/STM32/uart_lld.h')
-rw-r--r--os/hal/platforms/STM32/uart_lld.h23
1 files changed, 21 insertions, 2 deletions
diff --git a/os/hal/platforms/STM32/uart_lld.h b/os/hal/platforms/STM32/uart_lld.h
index 29cdda1ed..2977e15c5 100644
--- a/os/hal/platforms/STM32/uart_lld.h
+++ b/os/hal/platforms/STM32/uart_lld.h
@@ -78,6 +78,25 @@
typedef uint32_t uartflags_t;
/**
+ * @brief Generic UART notification callback type.
+ */
+typedef void (*uartcb_t)(void);
+
+/**
+ * @brief Character received UART notification callback type.
+ *
+ * @param[in] c received character
+ */
+typedef void (*uartccb_t)(uint16_t c);
+
+/**
+ * @brief Receive error UART notification callback type.
+ *
+ * @param[in] e receive error mask
+ */
+typedef void (*uartecb_t)(uartflags_t e);
+
+/**
* @brief Driver configuration structure.
* @note It could be empty on some architectures.
*/
@@ -89,9 +108,9 @@ typedef struct {
/** @brief Receive buffer filled callback.*/
uartcb_t uc_rxend;
/** @brief Character received while out if the @p UART_RECEIVE state.*/
- uartcb_t uc_rxchar;
+ uartccb_t uc_rxchar;
/** @brief Receive error callback.*/
- uartcb_t uc_rxerr;
+ uartecb_t uc_rxerr;
/* End of the mandatory fields.*/
/** @brief Bit rate.*/
uint32_t uc_speed;