Arduinocoms icon Arduinocoms EZB v4-Arduino I2C bridge for ARC: supports custom C# code and reads gamepad or Wii controller inputs for robot control Try it →
Israel
Asked — Edited
Resolved Resolved by Rich!

Entering A String Of Moves?

Hello! I have built this robot with the EZ-Robot card!

Now i would like to build a script, that when i start it, a text input window will pop up, where i can enter a string of characters, and this string will be taken apart to its single characters, by the script, and for each character case, a certain movement of the robot will be executed, one after the other.

Is it possible to do all that, using an ARC script?

How do i do it?

Thanks, Roi.


ARC Pro

Upgrade to ARC Pro

Get access to the latest features and updates before they're released. You'll have everything that's needed to unleash your robot's potential!

Author Avatar
United Kingdom
LinkedIn Twitter Google+ YouTube
#1  

ARC/EZ-Script doesn't have a command to pop up a dialogue for input

You can assign each movement script to single keyboard characters to be run when the key is down or when it is up or you can write a script that will execute a number of scripts one after the other on a single key press.

But without the dialogue for a string of characters you would need to write your own application and send the commands to trigger each script in turn via either telnet or http.

#2  

Hello Rich!

OK, Say i enter the string within the script itself and don't need a pop-up window, is it possible to break down the string to its single characters and execute a movement per character, using the script language?

Thanks.

Author Avatar
United Kingdom
LinkedIn Twitter Google+ YouTube
#3  

Yes, using the Length() and GetCharAt() commands however entering the string in the script seems redundant as you could simply use ControlCommand() to start the required scripts.

#4  

@roin,.I'm glad Rich was able to answer your question. Could you please mark this thread as answered? Thank you - Josh