diff --git a/linux/i2c/I2cComIF.cpp b/linux/i2c/I2cComIF.cpp index ea5cbe6..a88b019 100644 --- a/linux/i2c/I2cComIF.cpp +++ b/linux/i2c/I2cComIF.cpp @@ -38,7 +38,7 @@ ReturnValue_t I2cComIF::initializeInterface(CookieIF* cookie) { i2cDeviceMapIter = i2cDeviceMap.find(i2cAddress); if(i2cDeviceMapIter == i2cDeviceMap.end()) { size_t maxReplyLen = i2cCookie->getMaxReplyLen(); - I2cInstance_t i2cInstance = {std::vector(maxReplyLen), 0}; + I2cInstance i2cInstance = {std::vector(maxReplyLen), 0}; auto statusPair = i2cDeviceMap.emplace(i2cAddress, i2cInstance); if (not statusPair.second) { sif::error << "I2cComIF::initializeInterface: Failed to insert device with address " << diff --git a/linux/i2c/I2cComIF.h b/linux/i2c/I2cComIF.h index 17a4167..0856c9b 100644 --- a/linux/i2c/I2cComIF.h +++ b/linux/i2c/I2cComIF.h @@ -9,10 +9,10 @@ #include /** - * @brief This is the communication interface for i2c devices connected - * to a system running a linux OS. + * @brief This is the communication interface for I2C devices connected + * to a system running a Linux OS. * - * @note The xilinx linux kernel does not support to read more than 255 bytes at once. + * @note The Xilinx Linux kernel might not support to read more than 255 bytes at once. * * @author J. Meier */ @@ -33,12 +33,12 @@ public: private: - typedef struct I2cInstance { + struct I2cInstance { std::vector replyBuffer; size_t replyLen; - } I2cInstance_t; + }; - using I2cDeviceMap = std::unordered_map; + using I2cDeviceMap = std::unordered_map; using I2cDeviceMapIter = I2cDeviceMap::iterator; /* In this map all i2c devices will be registered with their address and