[SOLVED] JavaScript on Raspberry Pi with Button Push - Invoking 2 times

Hello,

i have a simple Programm on Raspberry Pi with one method. In this method i have the problem that if i klick the button once in my ios application the function is invoking 2 times. Why?

v1.on('write', function(param) {
  console.log('V1:', param); 
});

i get:

V1: [1]
V1: [0]

Exactly. Fist time is for press (value: 1) second for release (value: 0).
Just add an “if” if you want to use only one of them.

Cheers.

There are two modes for button in the blynk app, push and switch mode, you can try switch mode for button in your case