Attr

class iio.Attr

iio.Attr class: Contains the representation of an iio_attr.

Public Functions

string read ()

Read the value of this attribute as a string.

Throws IioLib.IIOException:

The attribute could not be read.

void write (string val)

Set this attribute to the value contained in the string argument.

Param val:

The string value to set the parameter to.

Throws IioLib.IIOException:

The attribute could not be written.

bool read_bool ()

Read the value of this attribute as a bool.

Throws IioLib.IIOException:

The attribute could not be read.

double read_double ()

Read the value of this attribute as a double.

Throws IioLib.IIOException:

The attribute could not be read.

long read_long ()

Read the value of this attribute as a long.

Throws IioLib.IIOException:

The attribute could not be read.

void write (bool val)

Set this attribute to the value contained in the bool argument.

Param val:

The bool value to set the parameter to.

Throws IioLib.IIOException:

The attribute could not be written.

void write (long val)

Set this attribute to the value contained in the long argument.

Param val:

The long value to set the parameter to.

Throws IioLib.IIOException:

The attribute could not be written.

void write (double val)

Set this attribute to the value contained in the double argument.

Param val:

The double value to set the parameter to.

Throws IioLib.IIOException:

The attribute could not be written.

Public Members

readonly string name

The name of this attribute.

readonly string filename

The filename in sysfs to which this attribute is bound.