Skip to content

Instantly share code, notes, and snippets.

@litnimax
Created January 29, 2018 10:30
Show Gist options
  • Save litnimax/16a286b6db725c51c905988396ba647f to your computer and use it in GitHub Desktop.
Save litnimax/16a286b6db725c51c905988396ba647f to your computer and use it in GitHub Desktop.
import BlynkLib
import time
BLYNK_AUTH = 'my-auth'
# Initialize Blynk
blynk = BlynkLib.Blynk(BLYNK_AUTH)
# Register virtual pin handler
@blynk.VIRTUAL_WRITE(3)
def v3_write_handler(value):
print('Current slider value: {}'.format(value))
# Start Blynk (this call should never return)
blynk.run()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment