I2C:WriteRegistersBuffer8
Jump to navigation
Jump to search
Request
| Index Word | Description | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| 0 |
| ||||||||
| 1 | u8, device ID | ||||||||
| 2 | u8, starting register | ||||||||
| 3 | u32, size | ||||||||
| 4 | Descriptor for mapping a read-only buffer in the target process | ||||||||
| 5 | Input buffer pointer |
Response
| Index Word | Description | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| 0 |
| ||||||||
| 1 | Result code | ||||||||
| 2 | Descriptor for mapping a read-only buffer in the target process | ||||||||
| 3 | Input buffer pointer |
Description
Writes the given buffer sequentially to a range of 8-bit I2C registers of the specified device.
Similar to I2C:WriteRegisters8, except this version uses a mapped buffer instead of a static buffer.
For example, writing a buffer of consisting of { 0xAA, 0xBB, 0xCC, 0xDD } with starting register 0x5 would do the following:
reg[0x5] = 0xAA
reg[0x6] = 0xBB
reg[0x7] = 0xCC
reg[0x8] = 0xDD