1 /* 2 * Copyright (c) 2022 Würth Elektronik eiSos GmbH & Co. KG 3 * 4 * SPDX-License-Identifier: Apache-2.0 5 */ 6 7 #ifndef WEPLATFORM_I2C_H_INCLUDED 8 #define WEPLATFORM_I2C_H_INCLUDED 9 10 #include <stdint.h> 11 12 #include <WeSensorsSDK.h> 13 14 /* Read a register's content via I2C */ 15 extern int8_t WE_ReadReg_I2C(WE_sensorInterface_t *interface, uint8_t regAdr, 16 uint16_t numBytesToRead, uint8_t *data); 17 18 /* Write a register's content via I2C */ 19 extern int8_t WE_WriteReg_I2C(WE_sensorInterface_t *interface, uint8_t regAdr, 20 uint16_t numBytesToWrite, uint8_t *data); 21 22 #endif /* WEPLATFORM_I2C_H_INCLUDED */ 23