Soletta™ Framework
Framework for making IoT devices

Full online documentation | C API Index
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Typedefs | Functions
sol-iio.h File Reference

Routines to access Linux Industrial I/O (iio) devices under Soletta. More...

#include <sol-buffer.h>
#include <sol-common-buildopts.h>
#include <linux/limits.h>

Go to the source code of this file.

Data Structures

struct  sol_iio_channel_config
 A configuration struct for an IIO channel. More...
 
struct  sol_iio_config
 A configuration struct for an IIO device. More...
 

Macros

#define SOL_IIO_CHANNEL_CONFIG_API_VERSION   (1)
 
#define SOL_IIO_CHANNEL_CONFIG_INIT
 Macro that may be used for initialized a sol_iio_channel_config. More...
 
#define SOL_IIO_CONFIG_API_VERSION   (2)
 

Typedefs

typedef struct sol_iio_channel sol_iio_channel
 An IIO channel handle. More...
 
typedef struct
sol_iio_channel_config 
sol_iio_channel_config
 A configuration struct for an IIO channel. More...
 
typedef struct sol_iio_config sol_iio_config
 A configuration struct for an IIO device. More...
 
typedef struct sol_iio_device sol_iio_device
 An IIO device handle. More...
 

Functions

struct sol_iio_channelsol_iio_add_channel (struct sol_iio_device *device, const char *name, const struct sol_iio_channel_config *config)
 Add reading channel. More...
 
int sol_iio_address_device (const char *commands)
 Address an IIO device from a list of commands to find them. More...
 
const char * sol_iio_channel_get_name (const struct sol_iio_channel *channel)
 Gets the configuration attribute name of a channel. More...
 
void sol_iio_close (struct sol_iio_device *device)
 Close an IIO device. More...
 
int sol_iio_device_get_offset (const struct sol_iio_device *device, const char *prefix_name, double *offset)
 Gets the configuration offset attribute from one device. More...
 
int sol_iio_device_get_sampling_frequency (const struct sol_iio_device *device, const char *prefix_name, int *sampling_frequency)
 Gets the configuration sampling_frequency attribute from one device. More...
 
int sol_iio_device_get_scale (const struct sol_iio_device *device, const char *prefix_name, double *scale)
 Gets the configuration scale attribute from one device. More...
 
int sol_iio_device_start_buffer (struct sol_iio_device *device)
 Start reading device buffer. More...
 
int sol_iio_device_trigger (struct sol_iio_device *device)
 Manually 'pull' device current trigger. More...
 
int sol_iio_mount_calibration (struct sol_iio_device *device, sol_direction_vector *value)
 Perform the mount calibration. More...
 
struct sol_iio_devicesol_iio_open (int id, const struct sol_iio_config *config)
 Open an IIO device. More...
 
struct sol_str_slice sol_iio_read_channel_raw_buffer (struct sol_iio_channel *channel)
 Returns raw buffer with channel sample. More...
 
int sol_iio_read_channel_value (struct sol_iio_channel *channel, double *value)
 Read channel value. More...
 

Detailed Description

Routines to access Linux Industrial I/O (iio) devices under Soletta.

Macro Definition Documentation

#define SOL_IIO_CHANNEL_CONFIG_API_VERSION   (1)
#define SOL_IIO_CONFIG_API_VERSION   (2)