Page 1 of 1

Reference Page - ZUNO_SENSOR_MULTILEVEL() - Incorrect?

Posted: 30 Jun 2018 11:18
by DaveDotNet
In looking at the reference page for ZUNO_SENSOR_MULTILEVEL(), I'm wondering if the top section is wrong. It says the syntax is;

Code: Select all

ZUNO_SENSOR_MULTILEVEL(type, scale_size_precision, getter)
but, ZUNO_SENSOR_MULTILEVEL is a macro that takes 5 parameters. The description also doesn't match as it suggests packing, but the macro already does that by leveraging SENSOR_MULTILEVEL_PROPERTIES_COMBINER(). It should probably look like this:

Code: Select all

ZUNO_SENSOR_MULTILEVEL(type, scale, size, precision, getter)
Lower down, the example:

Code: Select all

ZUNO_SENSOR_MULTILEVEL(ZUNO_SENSOR_MULTILEVEL_TYPE_TEMPERATURE, SENSOR_MULTILEVEL_SCALE_CELSIUS, SENSOR_MULTILEVEL_SIZE_ONE_BYTE, SENSOR_MULTILEVEL_PRECISION_ZERO_DECIMALS, GETTER)
seems to be correct. Have I read this wrong ?

Re: Reference Page - ZUNO_SENSOR_MULTILEVEL() - Incorrect?

Posted: 30 Jun 2018 14:45
by p0lyg0n1
Hi,
The right one is from header:

Code: Select all

#define ZUNO_SENSOR_MULTILEVEL(TYPE, SCALE, SIZE, PRECISION, GETTER) 						
You are right!
We'll update it soon. Thank you. The reference is for old version, before we add a SENSOR_MULTILEVEL_PROPERTIES_COMBINER() macro.

Alex.

Re: Reference Page - ZUNO_SENSOR_MULTILEVEL() - Incorrect?

Posted: 25 Jul 2018 02:53
by PoltoS