Package io.helins.linux.i2c
Enum I2CFlag
- java.lang.Object
-
- java.lang.Enum<I2CFlag>
-
- io.helins.linux.i2c.I2CFlag
-
- All Implemented Interfaces:
Serializable,Comparable<I2CFlag>
public enum I2CFlag extends Enum<I2CFlag>
Enum representing a flag for describing an I2C message.- See Also:
I2CMessage
-
-
Enum Constant Summary
Enum Constants Enum Constant Description IGNORE_NAKIgnores not acknowledge.NO_READ_ACKIgnores read acknowledge.NO_STARTDoes not issue any more START/address after the initial START/address in a combined message.READIs a read operation, not a write.REVISE_RW_BITSends a read flag for writes and a write flag for reads.TEN_BIT_ADDRESSINGUses 10-bit addressing scheme instead of 7-bit.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static I2CFlagvalueOf(String name)Returns the enum constant of this type with the specified name.static I2CFlag[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
TEN_BIT_ADDRESSING
public static final I2CFlag TEN_BIT_ADDRESSING
Uses 10-bit addressing scheme instead of 7-bit.
-
READ
public static final I2CFlag READ
Is a read operation, not a write.
-
NO_START
public static final I2CFlag NO_START
Does not issue any more START/address after the initial START/address in a combined message.This is a workaround for broken I2C slave devices.
-
REVISE_RW_BIT
public static final I2CFlag REVISE_RW_BIT
Sends a read flag for writes and a write flag for reads.This is a workaround for broken I2C slave devices.
Check for the
protocol mangling functionality.
-
IGNORE_NAK
public static final I2CFlag IGNORE_NAK
Ignores not acknowledge.Check for the
protocol mangling functionality.
-
NO_READ_ACK
public static final I2CFlag NO_READ_ACK
Ignores read acknowledge.Check for the
protocol mangling functionality.
-
-
Method Detail
-
values
public static I2CFlag[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (I2CFlag c : I2CFlag.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static I2CFlag valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
-