Blynk button state

Ok so as far as I can tell, BLYNK_WRITE() gets the state of the button as the button state changes. Is there a way I can get the state of the button without button state changing (as in the moment I start the microcontroller, I get the value of the button in my esp8266 without tapping a button in my Android device)?

Yes, using blynk sync

1 Like

Blynk.syncVirtual(Vx) will cause the corresponding BLYNK_WRITE(Vx) callback to fire.

You can put this in the BLYNK_CONNECTED() callback to synchronise on start-up if you wish.


1 Like