From e5c320a0d1a00915f88b379f27e981b89a787e33 Mon Sep 17 00:00:00 2001 From: gdisirio Date: Sun, 18 Mar 2012 20:30:06 +0000 Subject: git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@4050 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/hal/src/i2s.c | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) (limited to 'os/hal/src') diff --git a/os/hal/src/i2s.c b/os/hal/src/i2s.c index e0c547847..99e4246ad 100644 --- a/os/hal/src/i2s.c +++ b/os/hal/src/i2s.c @@ -128,11 +128,30 @@ void i2sStartExchange(I2SDriver *i2sp) { chDbgCheck(i2sp != NULL "i2sStartExchange"); chSysLock(); - chDbgAssert(i2sp->state == I2S_READY, "i2sStartExchange(), #1", "not ready"); + chDbgAssert(i2sp->state == I2S_READY, + "i2sStartExchange(), #1", "not ready"); i2sStartExchangeI(i2sp); chSysUnlock(); } +/** + * @brief Starts a I2S data exchange in continuous mode. + * + * @param[in] i2sp pointer to the @p I2SDriver object + * + * @api + */ +void i2sStartExchangeContinuous(I2SDriver *i2sp) { + + chDbgCheck(i2sp != NULL "i2sStartExchangeContinuous"); + + chSysLock(); + chDbgAssert(i2sp->state == I2S_READY, + "i2sStartExchangeContinuous(), #1", "not ready"); + i2sStartExchangeContinuousI(i2sp); + chSysUnlock(); +} + /** * @brief Stops the ongoing data exchange. * @details The ongoing data exchange, if any, is stopped, if the driver -- cgit v1.2.3