String values from app button to device

hello,
as i know, values from the app buttons coming to device (esp, raspberry etc) as text strings.
but currently, buttons acts only as switches or “just buttons” )

is it possible to have a super-puper-megabutton, which can send a pre-defined text string to the device? for example, to issue a command to existing controller.

as a workaround, i can set a button to virtual pin, then program an event on device side such way, device send a string needed to the controller (by serial connection). but this way requires device reprogramming each time when commands changes.

So in short. Is it possible to have a button sending a text value?

Thank you

@s_t_cat

With button this is not possible. But today-tomorrow we will release Terminal for Android. It will do exactly what you want - send text to device.

great news. but for terminal needs, i do have a terminal)
i’d like to see some kind of shortcuts. one press- one command to the device…

maybe as a terminal feature?
maybe in future releases?

@Pavel what do you think?

Could you please describe your case or project?

I once thought about a widget that sends strings, but then figured out that in most of the cases you can do it with Button + Virtual pins.

Anyway, your idea is stored. Thanks for it.

Well, i have Arduino as relay/sensor controller, connected to Raspbery running control application.
Between arduino and raspberry there’s serial connectio. Communication between control applicaction and ardiuno is based on human-like stings, to allow terminal debug and control

Blynk could be handy dashboards to send prepared commands thru my application directly to controls.
right now, i have 1) establish a VPN to my network, 2) SSH to raspberry, 3) remember what i wanted to execute before step1 and type the command, 4) find a mistypings and type command again, 5) read out values/reports needed.
It works but requires a lot of extra funny actions indeed)

So if it possible to have a one-button pre-defined string send from the Blynk to {somewhere else}, i would be so happy…It could provide a flexible UI/dashboard to control many of different setups i suppose.

Regards,
Serge tC

PS i’d better describe in russian if tou dont mind)

This would be useful for myself as well. Only being able to send a Boolean from a button to a virtual pin is a bit limiting, and so is having to repeatedly type into the terminal. I have an application where I have preset serial commands (some with variable data). It would be nice to set up a group of buttons with preset strings.

Thanks!

@jbaugh what about MENU widget?

As far as I can tell, the menu widget will only send the numeric index of the selection to the virtual pin. I would rather not have to do a lookup table in my firmware to link index numbers to strings. As the previous poster mentioned, this would require me to reprogram my hardware more often than appropriate. It is a good feature, however.

@jbaugh how many different strings do you expect to use?

Costas, My strings are composed of about 30 different ASCII commands and some of which have 16-bit variable data (in Hex). In effect, hundreds of thousands.

@jbaugh I don’t think it will happen in my lifetime that Blynk will offer hundreds of thousands of buttons within the app.

Maybe if you explained in more detail what it is you are doing with your system it might help but based on those kind of numbers then Terminal is probably the only way to do it at present.

Dears,

Let us not concentrate on numbers of buttons. My idea was to provide flexible and comfortable way to pass predefined text strings from Blynk to my app. And i mean user (Me:) should be able to modify/correct those values from the Blynk GUI.

Again, if it too complex and you push us to use terminal - so i get remote VPN and terminal with much better functions than Blynk and i dont need your features. Idea is to provide string communication to software by pushing buttons. By easy way, without typing commands each time.

And yes, we can combine all those buttons by tabs.

here is my example. I’d like to have serveral buttons sending commands like “CMD_CHECK_OUTPUT#” where output number can be let me guess 1…16. and “cmd_set_status_green”, “cmd_set_status_orange”, “cmd_set_status_red”. and “cmd_sensors_query”. And let me guess “cmd_shutdown_alarm”. and any other command depending on my imagination. And maybe later i will decide this command format is crazy and i will replace it by some other strings like just dont know what ))), so only change in GUI i need is text label correction. without any linux C code recompilation.

For typing all those commands i can use good old JusieSSH with predefined login profile and command history. and good scroll buffer. and snippets. ans even X server despite i dont need it…

well, i still hope “string sending button” feature is possible…I think it can make life more easy.

Regards,
Serge tC

1 Like

And for that you still need to recompile your code, aren’t you?

my logic was following:
if application receives event from blynk from button # (1…X) with text value, i will just pass this value from application to controller. So it looks like link from Blynk GUI <-internet-> my application <-serial-> controller.
So no need to recomplie application, only change text labels at Blynk GUI. For my opinion, this solution can provide more flexibility of GUI setup.

and from controller - it all at my side, i can reprogram it as needed (if needed).

I am not looking to create thousands of buttons. I would just like the flexibility to change my system from the app without having haul out the arduino, recompile, and upload. I believe that s_t_cat’s application and mine are similar in that way.

I don’t want to have thousands of buttons in much the same way I don’t want to have thousands of lookup table entries in my arduino application code. I just need simple (preset) pass throughs from GUI to arduino.

1 Like

3 posts were split to a new topic: I would like a textbox