Using an IoT Indicator with Analog Values

Hi All,
I'm trying to use a "Status Indicator" on an Arduino IoT cloud dashboard with analog values where the indicator is green/true when the analog values are under a certain threshold and red/false when the analog values are over that threshold. I don't seem to be able to code the logic to do this. Any suggestions/experience on this? The sensor is a MQ-5 Gas sensor which has no issue giving me an integer value into the cloud - I'm just not able to make it into a boolean true/false and make the Status work. . .

Thanks in advance,
Tim

You didn't post any code.

Sorry - here's the section of code. Again, i have no issue getting the analog numerical value to display on the cloud "value" widget. I just can seem to must make a basic indicator. Thanks !

void onPropaneChange() {
// Add your code here to act upon Propane change
propane = analogRead(ANALOG4_IN_PIN);
//
if (propane > 16); (propane, LOW);

if (propane <= 15); (propane, HIGH);

}

It's hardly a surprise that this doesn't work - it does not obey basic C semantic rules, or the Arduino API. Study C and the Arduino reference page, tutorials and examples. If the rest of the code is like that, you need to begin from scratch. It's unlikely that it works as intended. When you post code, please use code tags.