From c1aee1e2c5b6284d8165a88457654b296bcd81a5 Mon Sep 17 00:00:00 2001 From: Martin Preuss Date: Sun, 5 Feb 2023 15:39:15 +0100 Subject: [PATCH] Renamed i2c to twi. --- aqhome/libtest.c | 4 ++-- aqhome/msg.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/aqhome/libtest.c b/aqhome/libtest.c index 46a172f..63ce2bf 100644 --- a/aqhome/libtest.c +++ b/aqhome/libtest.c @@ -133,13 +133,13 @@ void _packetReceived(AQH_SERIAL *sr, AQH_MSG *msg) AQH_MsgSendStats_DumpToBuffer(msg, dbuf, "received"); fprintf(stdout, "%s", GWEN_Buffer_GetStart(dbuf)); } - else if (msgType==30) { /* CPRO_CMD_I2CBUSMEMBER */ + else if (msgType==AQH_MSG_TYPE_TWIBUSMEMBER) { /* CPRO_CMD_TWIBUSMEMBER */ int i2cAddr; int availability; i2cAddr=ptr[4]; availability=ptr[5]; - fprintf(stdout, "-> I2C DEVICE %02x: %s\n", i2cAddr, (availability==0)?"not available":"FOUND"); + fprintf(stdout, "-> TWI DEVICE %02x: %s\n", i2cAddr, (availability==0)?"not available":"FOUND"); } else if (msgType==40) { /* CPRO_CMD_DEBUG */ uint8_t param1; diff --git a/aqhome/msg.h b/aqhome/msg.h index 160ede4..e72de7a 100644 --- a/aqhome/msg.h +++ b/aqhome/msg.h @@ -30,7 +30,7 @@ #define AQH_MSG_TYPE_PONG 11 #define AQH_MSG_TYPE_COMSENDSTATS 20 #define AQH_MSG_TYPE_COMRECVSTATS 21 -#define AQH_MSG_TYPE_I2CBUSMEMBER 30 +#define AQH_MSG_TYPE_TWIBUSMEMBER 30 #define AQH_MSG_TYPE_DEBUG 40 #define AQH_MSG_TYPE_VALUE 50 #define AQH_MSG_TYPE_NEED_ADDRESS 60