Unformatted text preview:

The MRRoboto Language Jason Kopylec Hema Krishnan Adam Marczyk Programming Languages Spring 2004 The Inspiration In most operating systems writing programs that interact with other programs is difficult n Graphical user interfaces are designed for humans not programs n There are many conceivable situations for which it would be nice to be able to control other programs programmatically n Solution Control the keyboard and the mouse through software n The Concept The Macro Record Robot Language MRRoboto for short allows programmers to automate control of the keyboard and the mouse through simple batch programs n The syntax is Java like but simplified so that scripts can be written quickly n A good way to teach beginning programmers basic concepts such as flow control and modularization n The Execution The ANTLR parser generator was used to create a grammar file that translates MRRoboto scripts into human readable Java source code which can then be compiled and run n Translation consists of three steps lexical analysis syntax tree generation and a treewalking algorithm that performs semantic analysis and generates the code n Some Examples a simple hello world program mouseMove 10 10 click mouseMove 50 10 click type notepad press ENTER type Hello World More Examples delays and flow control int a a 3 wait 60000 60 seconds if a 10 moveAndDoubleClick 20 20 else while a 5 moveAndClick 50 50 end end The Main Block and Procedures string b b foo doType b procedure doType string msg type msg end Error Detection and Recovery Code that violates the grammar rules bad token incorrect syntax etc will be detected by ANTLR during initial lexical analysis and parsing n Code that contains semantic errors undefined symbol type mismatch missing return statement etc will be detected by the semantic analyzer during the final stage of translation n Future Directions We had relatively little time to implement computer vision functionality other than some simple pixel color detection so the ability of MRRoboto programs to actually interact with the screen is fairly limited n More sophisticated means of interaction perhaps including automatic detection of system native windowing components seems to be a likely place for future expansion n


View Full Document

Columbia COMS W4115 - The MRRoboto Language

Documents in this Course
YOLT

YOLT

13 pages

Lattakia

Lattakia

15 pages

EasyQL

EasyQL

14 pages

Photogram

Photogram

163 pages

Espresso

Espresso

27 pages

NumLang

NumLang

6 pages

EMPATH

EMPATH

14 pages

La Mesa

La Mesa

9 pages

JTemplate

JTemplate

238 pages

MATVEC

MATVEC

4 pages

TONEDEF

TONEDEF

14 pages

SASSi

SASSi

16 pages

JTemplate

JTemplate

39 pages

BATS

BATS

10 pages

Synapse

Synapse

11 pages

c.def

c.def

116 pages

TweaXML

TweaXML

108 pages

Load more
Loading Unlocking...
Login

Join to view The MRRoboto Language and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view The MRRoboto Language and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?