How to avoid Blynk button widget flicking (3 states)

Hi, I have a Blynk button that has three states; 'On', 'Off' and 'Auto'.
Here is a test code I'm going to use in a final program and it works fine.
Though, it flicks default values ("ON" or "OFF") between the states I change in a code.

Not a major problem but I do not want this. Any way to avoid these flicks?
Neither widget, "PUSH" or "SWITCH" setting does not help.

#include <BlynkSimpleEsp8266.h>
#include "secrets.h"
#define mainButton V3

void SetHeatingState(byte vH_state); // set button text, color, etc

byte heaterState;
String strMainButton;

BLYNK_WRITE(mainButton) // 0 = Off, 1 = On, 2 = Auto
  {   
    heaterState ++;
    if(heaterState > 2)
      heaterState = 0;
   SetHeatingState(heaterState); 
  }

void setup()
{
  Blynk.begin(AUTH_CODE, WLAN_SSID, WLAN_PASS);
  Blynk.setProperty(mainButton, "color", BLYNK_WHITE);
  Serial.begin(115200); 
}

void loop()
{
Blynk.run();
}

void SetHeatingState(byte vHeatState)
  {
    Serial.println(vHeatState);
  switch (vHeatState)
  {
    case 1:      
      Blynk.setProperty(V3, "color", BLYNK_YELLOW);
      Blynk.setProperty(V3, "onLabel", "On");
      Serial.println("YEL");
      Blynk.virtualWrite(V3, HIGH);      
    break;
    
    case 0:          
      Blynk.setProperty(V3, "color", BLYNK_GREY);
      Blynk.setProperty(V3, "offLabel", "Off");
      Blynk.virtualWrite(V3, LOW);
    break;

    case 2:      
      Blynk.setProperty(V3, "color", BLYNK_WHITE);
      Blynk.setProperty(V3, "offLabel", "Auto");
      Blynk.virtualWrite(V3, LOW);
    break;
  }
  }

Is this code copied from a site or did you write it?

fnb111:
Is this code copied from a site or did you write it?

That is all written by myself. Why you asked? Does it look like copied? Something totally wrong in it? :slight_smile: