i2c_software: Implementation of software i2c (#6141)

Signed-off-by: Alan.Ma from BigTreeTech <tech@biqu3d.com>
This commit is contained in:
BIGTREETECH 2023-06-08 08:55:46 +08:00 committed by GitHub
parent b389c70d5a
commit 645a1b8364
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 299 additions and 17 deletions

13
src/i2c_software.h Normal file
View file

@ -0,0 +1,13 @@
#ifndef __I2C_SOFTWARE_H
#define __I2C_SOFTWARE_H
#include <stdint.h> // uint8_t
struct i2c_software *i2c_software_oid_lookup(uint8_t oid);
void i2c_software_write(struct i2c_software *sw_i2c
, uint8_t write_len, uint8_t *write);
void i2c_software_read(struct i2c_software *sw_i2c
, uint8_t reg_len, uint8_t *reg
, uint8_t read_len, uint8_t *read);
#endif // i2c_software.h