If it helps, I even tried float, and interestingly it showed also a 'decimal' point and nothing after it (for example: 843.) as if the app has a limited character or width space of text field? (that's just my guess).
I really need it to get it working soon for a client. Relevant code snippets below. Please help!
Thanks,
Hasan
Code: Select all
static Device CO2("CO2 (ppm)", "custom.device.co2");
my_node.addDevice(CO2);
void setup() {
Param co2_param("CO2 (ppm)", "custom.param.value", value((int)DEFAULT_CO2), PROP_FLAG_READ);
CO2.addParam(co2_param);
CO2.assignPrimaryParam(CO2.getParamByName("CO2 (ppm)")); }
//To update:
int h = int(mySensor.getCO2());
CO2.updateAndReportParam("CO2 (ppm)", h);