public class I2CTransaction extends Object
Sometimes, only one message per transaction is supported, which defeat the purpose of having transactions.
| Modifier and Type | Field and Description |
|---|---|
int |
length
How many messages this transaction holds.
|
static int |
MAX_LENGTH
The maximum number of messages a single transaction can carry out in theory.
|
| Constructor and Description |
|---|
I2CTransaction(int length)
Creates a new transaction.
|
| Modifier and Type | Method and Description |
|---|---|
I2CMessage |
getMessage(int index)
Retrieves a message from this transaction.
|
public static final int MAX_LENGTH
public final int length
public I2CTransaction(int length)
length - The number of messages.MAX_LENGTHpublic I2CMessage getMessage(int index)
index - Which one.