aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/templates/spi_lld.c
diff options
context:
space:
mode:
Diffstat (limited to 'os/hal/templates/spi_lld.c')
-rw-r--r--os/hal/templates/spi_lld.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/os/hal/templates/spi_lld.c b/os/hal/templates/spi_lld.c
index 1fca51d41..f3053f725 100644
--- a/os/hal/templates/spi_lld.c
+++ b/os/hal/templates/spi_lld.c
@@ -177,6 +177,22 @@ void spi_lld_receive(SPIDriver *spip, size_t n, void *rxbuf) {
}
+/**
+ * @brief Exchanges one frame using a polled wait.
+ * @details This synchronous function exchanges one frame using a polled
+ * synchronization method. This function is useful when exchanging
+ * small amount of data on high speed channels, usually in this
+ * situation is much more efficient just wait for completion using
+ * polling than suspending the thread waiting for an interrupt.
+ *
+ * @param[in] spip pointer to the @p SPIDriver object
+ * @param[in] frame the data frame to send over the SPI bus
+ * @return The received data frame from the SPI bus.
+ */
+uint16_t spi_lld_polled_exchange(SPIDriver *spip, uint16_t frame) {
+
+}
+
#endif /* CH_HAL_USE_SPI */
/** @} */