From 24987e2873a946bc41ee1c5088b703abf9d7c526 Mon Sep 17 00:00:00 2001 From: barthess Date: Wed, 22 Jun 2011 08:38:54 +0000 Subject: [PATCH] I2C. Test changes git-svn-id: svn://svn.code.sf.net/p/chibios/svn/branches/i2c_dev@3068 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- testhal/STM32/I2C/lis3.c | 4 ++-- testhal/STM32/I2C/max1236.c | 4 ++-- testhal/STM32/I2C/tmp75.c | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/testhal/STM32/I2C/lis3.c b/testhal/STM32/I2C/lis3.c index 00bb712a1..14616478b 100644 --- a/testhal/STM32/I2C/lis3.c +++ b/testhal/STM32/I2C/lis3.c @@ -19,7 +19,7 @@ static i2cblock_t accel_rx_data[ACCEL_RX_DEPTH]; static i2cblock_t accel_tx_data[ACCEL_TX_DEPTH]; /* Error trap */ -static void i2c_lis3_error_cb(I2CDriver *i2cp, I2CSlaveConfig *i2cscfg){ +static void i2c_lis3_error_cb(I2CDriver *i2cp, const I2CSlaveConfig *i2cscfg){ (void)i2cscfg; int status = 0; status = i2cp->id_i2c->SR1; @@ -62,7 +62,7 @@ static msg_t I2CAccelThread(void *arg) { } /* This callback raise up when transfer finished */ -static void i2c_lis3_cb(I2CDriver *i2cp, I2CSlaveConfig *i2cscfg){ +static void i2c_lis3_cb(I2CDriver *i2cp, const I2CSlaveConfig *i2cscfg){ (void) i2cp; // only wake up processing thread if (i2c_accel_tp != NULL) { diff --git a/testhal/STM32/I2C/max1236.c b/testhal/STM32/I2C/max1236.c index ed9d12ca6..2ba5f89b0 100644 --- a/testhal/STM32/I2C/max1236.c +++ b/testhal/STM32/I2C/max1236.c @@ -18,7 +18,7 @@ static uint16_t ch1 = 0, ch2 = 0, ch3 = 0, ch4 = 0; /* Error trap */ -static void i2c_max1236_error_cb(I2CDriver *i2cp, I2CSlaveConfig *i2cscfg){ +static void i2c_max1236_error_cb(I2CDriver *i2cp, const I2CSlaveConfig *i2cscfg){ (void)i2cscfg; int status = 0; status = i2cp->id_i2c->SR1; @@ -27,7 +27,7 @@ static void i2c_max1236_error_cb(I2CDriver *i2cp, I2CSlaveConfig *i2cscfg){ /* This callback raise up when transfer finished */ -static void i2c_max1236_cb(I2CDriver *i2cp, I2CSlaveConfig *i2cscfg){ +static void i2c_max1236_cb(I2CDriver *i2cp, const I2CSlaveConfig *i2cscfg){ (void)*i2cp; /* get ADC data */ ch1 = ((i2cscfg->rxbuf[0] & 0xF) << 8) + i2cscfg->rxbuf[1]; diff --git a/testhal/STM32/I2C/tmp75.c b/testhal/STM32/I2C/tmp75.c index 6744fe325..1d1432601 100644 --- a/testhal/STM32/I2C/tmp75.c +++ b/testhal/STM32/I2C/tmp75.c @@ -19,7 +19,7 @@ static i2cblock_t tmp75_tx_data[TMP75_TX_DEPTH]; static int16_t temperature = 0; // Simple error trap -static void i2c_tmp75_error_cb(I2CDriver *i2cp, I2CSlaveConfig *i2cscfg){ +static void i2c_tmp75_error_cb(I2CDriver *i2cp, const I2CSlaveConfig *i2cscfg){ (void)i2cscfg; int status = 0; status = i2cp->id_i2c->SR1; @@ -27,7 +27,7 @@ static void i2c_tmp75_error_cb(I2CDriver *i2cp, I2CSlaveConfig *i2cscfg){ } /* This callback raise up when transfer finished */ -static void i2c_tmp75_cb(I2CDriver *i2cp, I2CSlaveConfig *i2cscfg){ +static void i2c_tmp75_cb(I2CDriver *i2cp, const I2CSlaveConfig *i2cscfg){ (void)*i2cp; /* store temperature value */ temperature = (i2cscfg->rxbuf[0] << 8) + i2cscfg->rxbuf[1];