Hi, i have an issue. When i use blynk_write function it doesnt work. i use slider to pass data and control servo somehow. and it doesnt work . have any1 has idea what can be wrong
#define BLYNK_PRINT Serial
int value;//vaule of rotation
char auth = "3e0c43c56c494b139abed9d05cd3a032";
char ssid = "21:37";
char pass = "elomelo12";
Blynk.begin(auth, ssid, pass);
int pinValue = param.asInt(); // assigning incoming value from pin V1 to a variable
value = pinValue;
Remove the delay from void loop and try it again.
Edit: also you need to add 3 back ticks as per forum rules for your code otherwise it may be deleted.
Yes it does!
Three backticks look like this:
If you copy and paste these characters at the top and bottom of your code the it will display correctly.
i’ve deleted delay and still doesn display value
sorry, now i’ve reapir this
pinValue as a local variable. This means that it’s only available within the
Try googling “variable scope in C++” to learn how to resolve this issue.
Evnen if i use global variable it still doesnt work. it looks like function desnt iniciate (trigger).
What widget do you have attached to V0, and how is it configured?
It looks like the project has multiple devices.
Is the Auth code you’re using in the sketch the same one that is attached to device “Pomiary”?
yes it is i’ve checked this twice.
So when you put the app into ‘run’ mode and move the slider, zero is printed in the serial monitor?
yes, 0 printed. and if i connect servo like in code. servo doesnt move.
Ok, i’ve reset ath token and it works. I dont know why. Thank you @PeteKnight Pete for your help, and time spend to help me. U re good man.