Does anyone know how to send values to arduino using Terminal Widget?

Can someone plz help?

I’m working on a project to tell me if the temp/humidity goes above or below 2 different numbers, and i’d like to be able to type in these 2 numbers into a terminal.
here’s an example


Please enter MAX temp
me: 30
Please enter MIN temp
me: 10

So I need someone to help me with the following:
-How do I detect if somethings been typed (Anything, preferably numbers only)

-How do I make the typed numbers into an integer or something to use as a limit (like, if the temperature goes
above the first typed number, or below the second, then turn on an LED)

If someone could help me with this, THAT WOULD BE AMAZING!! and will greatly shorten the time of my project!

Thank You!!!

P.S. I am using a NodeMCU 1.0 and a DHT11 (If that’s necessary)

So your title says Arduino, then you say NodeMCU… oh, well… doesn’t make a difference in the terminal code :slight_smile:

See the Terminal example for the how to -

The terminal widget is just like all the other input widgets… what you type (once you press enter) shows up in the designated BLYNK_WRITE() function as a string, and usually is passed onto a variable with the variable = param.asStr() command.

The normal Arduino code way to convert is as such…

But also read the Documentation for Blynk’s vPin control…

Since the DHT11 doesn’t work with decimal points, and Blynk has such nice vPin conversion options built in (as per them pesky Docs :wink: ), I suppose you could try using the param.asInt() (Integer) and see how that translates for any numerical input.

OMG Thank you so much! This will make my project easier! I should’ve thought of that! Thanks a million Gunner!! (Sorry for the confusion at the beginning:joy:)