brymen-bm86x: Add current loop sensor support.

This commit is contained in:
Aurelien Jacobs 2014-09-04 22:06:54 +02:00 committed by Uwe Hermann
parent 7343ad1ec7
commit af1e487e3f
1 changed files with 3 additions and 0 deletions

View File

@ -161,6 +161,9 @@ static void brymen_bm86x_parse(unsigned char *buf, float *floatval,
} else if (buf[9] & 0x04) {
analog[1].mq = SR_MQ_CURRENT;
analog[1].unit = SR_UNIT_AMPERE;
} else if (buf[9] & 0x08) {
analog[1].mq = SR_MQ_CURRENT;
analog[1].unit = SR_UNIT_PERCENTAGE;
} else if (buf[14] & 0x04) {
analog[1].mq = SR_MQ_FREQUENCY;
analog[1].unit = SR_UNIT_HERTZ;