Skip to content

Commit

Permalink
Update channel type and modifier lists
Browse files Browse the repository at this point in the history
Update the channel type and modifier lists against Linux 5.4.22.

Signed-off-by: Petr Štetiar <[email protected]>
  • Loading branch information
ynezz committed Mar 3, 2020
1 parent 875d937 commit 98ba731
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
10 changes: 10 additions & 0 deletions channel.c
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,9 @@ static const char * const iio_chan_type_name_spec[] = {
[IIO_COUNT] = "count",
[IIO_INDEX] = "index",
[IIO_GRAVITY] = "gravity",
[IIO_POSITIONRELATIVE] = "positionrelative",
[IIO_PHASE] = "phase",
[IIO_MASSCONCENTRATION] = "massconcentration",
};

static const char * const modifier_names[] = {
Expand All @@ -79,6 +82,7 @@ static const char * const modifier_names[] = {
[IIO_MOD_LIGHT_GREEN] = "green",
[IIO_MOD_LIGHT_BLUE] = "blue",
[IIO_MOD_LIGHT_UV] = "uv",
[IIO_MOD_LIGHT_DUV] = "duv",
[IIO_MOD_QUATERNION] = "quaternion",
[IIO_MOD_TEMP_AMBIENT] = "ambient",
[IIO_MOD_TEMP_OBJECT] = "object",
Expand All @@ -94,7 +98,13 @@ static const char * const modifier_names[] = {
[IIO_MOD_I] = "i",
[IIO_MOD_Q] = "q",
[IIO_MOD_CO2] = "co2",
[IIO_MOD_ETHANOL] = "ethanol",
[IIO_MOD_H2] = "h2",
[IIO_MOD_VOC] = "voc",
[IIO_MOD_PM1] = "pm1",
[IIO_MOD_PM2P5] = "pm2p5",
[IIO_MOD_PM4] = "pm4",
[IIO_MOD_PM10] = "pm10",
};

/*
Expand Down
10 changes: 10 additions & 0 deletions iio.h
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,9 @@ enum iio_chan_type {
IIO_COUNT,
IIO_INDEX,
IIO_GRAVITY,
IIO_POSITIONRELATIVE,
IIO_PHASE,
IIO_MASSCONCENTRATION,
IIO_CHAN_TYPE_UNKNOWN = INT_MAX
};

Expand Down Expand Up @@ -173,6 +176,13 @@ enum iio_modifier {
IIO_MOD_CO2,
IIO_MOD_VOC,
IIO_MOD_LIGHT_UV,
IIO_MOD_LIGHT_DUV,
IIO_MOD_PM1,
IIO_MOD_PM2P5,
IIO_MOD_PM4,
IIO_MOD_PM10,
IIO_MOD_ETHANOL,
IIO_MOD_H2,
};

/* ---------------------------------------------------------------------------*/
Expand Down

0 comments on commit 98ba731

Please sign in to comment.