diff options
author | Tomasz Moń <desowin@gmail.com> | 2021-07-10 08:56:32 +0200 |
---|---|---|
committer | Tomasz Moń <desowin@gmail.com> | 2021-07-10 08:56:32 +0200 |
commit | b4ecd612f7184cbf23d83ef78b0ccb5ed2c318e3 (patch) | |
tree | d0c25f174efbfa49612b5bdb7d6f6adf3e146ed6 /firmware/export/generic_i2c.h | |
parent | 663539619c05d9b429dfbea1e5d38d8bb043ee03 (diff) | |
download | rockbox-b4ecd612f7184cbf23d83ef78b0ccb5ed2c318e3.tar.gz rockbox-b4ecd612f7184cbf23d83ef78b0ccb5ed2c318e3.zip |
Sansa Connect: Use deviceid in USB Serial Number
Atmel AT88SC6416C CryptoMemory is almost I2C compatible. The device
is connected to bitbanged I2C bus shared with compliant I2C devices.
Change-Id: Iec54702db1bdfb93c01291eef18ec60391c63b16
Diffstat (limited to 'firmware/export/generic_i2c.h')
-rw-r--r-- | firmware/export/generic_i2c.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/firmware/export/generic_i2c.h b/firmware/export/generic_i2c.h index f71736acf0..9fdba26836 100644 --- a/firmware/export/generic_i2c.h +++ b/firmware/export/generic_i2c.h | |||
@@ -49,5 +49,15 @@ int i2c_write_data(int bus_index, int bus_address, int address, | |||
49 | int i2c_read_data(int bus_index, int bus_address, int address, | 49 | int i2c_read_data(int bus_index, int bus_address, int address, |
50 | unsigned char* buf, int count); | 50 | unsigned char* buf, int count); |
51 | 51 | ||
52 | /* Special function for devices that can appear on I2C bus but do not | ||
53 | * comply to I2C specification. Such devices include AT88SC6416C crypto | ||
54 | * memory. To read data from AT88SC6416C, a write I2C transaction starts, | ||
55 | * 3 bytes are written and then, in the middle of transaction, the device | ||
56 | * starts sending data. | ||
57 | */ | ||
58 | int i2c_write_read_data(int bus_index, int bus_address, | ||
59 | const unsigned char* buf_write, int count_write, | ||
60 | unsigned char* buf_read, int count_read); | ||
61 | |||
52 | #endif /* _GEN_I2C_ */ | 62 | #endif /* _GEN_I2C_ */ |
53 | 63 | ||