[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Announcing StarLogo 1.0 Beta 2!!!
- Date: Thu, 23 Sep 1999 16:54:54 -0700
- From: Andrew Begel <abegel@cs.berkeley.edu>
- Subject: Announcing StarLogo 1.0 Beta 2!!!
Hi everyone,
The second beta of StarLogo 1.0 is now available! Our original
version of StarLogo, which runs only on Macintosh computers, has been
renamed MacStarLogo. This version of StarLogo is implemented in Java
and is able to run on many different platforms. Since our first beta
release, we have been hard at work adding many new features and
fixing bugs. We have also expanded our development efforts to include
MacOS, Unix and OS/2, so this new StarLogo should run pretty well on
many more computers than before.
You can download this second beta version of StarLogo from the StarLogo Web
site (http://www.media.mit.edu/starlogo). See the Web site for more
information.
We look forward to hearing your comments and suggestions!
-- The StarLogo Development Team
-----------
We include the README that comes with the StarLogo download in the
remainder of this letter.
STARLOGO (Beta 2)
September 22, 1999
----------------------------
1. INTRODUCTION
----------------------------
Welcome to the second beta release of StarLogo, a totally new version
of StarLogo. Our original version of StarLogo, which runs only on
Macintosh computers, has been renamed MacStarLogo. As with
MacStarLogo, this new version is designed to help you model and
explore the workings of decentralized systems, such as bird flocks,
traffic jams, and market economies (see
http://www.media.mit.edu/starlogo).
This version of StarLogo is implemented in Java, the
"write-once-run-everywhere" programming language. As a result,
StarLogo can (in theory) run on all different types of
computers. While there are already good versions of StarLogo for the
Macintosh, there have been none for PCs. For Mac users, MacStarLogo
will see superior performance to StarLogo for most purposes (however,
we do encourage you try out the new features of the Java version).
You will notice that StarLogo has some significant differences from
MacStarLogo. Most notably, this version requires you to be more
explicit about which StarLogo objects you are "talking to". In Mac
StarLogo, the compiler tried to figure out automatically whether you
meant to "talk to" the turtles or the observer. That approach was
elegant, but it was confusing at times. So we have put control back in
your hands, with separate command centers and procedure windows for
the turtles and the observer.
We have also removed some of the capabilities of the StarLogo
patches. The patches can still hold information, and the turtles and
observer can still act on the patches. But the patches themselves can
not execute instructions. We restricted the patches for several
reasons. Most important is the speed of the software. Since this
version is implemented in Java (not assembly code), it is slower than
previous versions. Telling thousands of patches to execute a command
would be very slow. Also, we thought that restricting the patches
might simplify the language, making it easier for people to build
their own models. We'll see. As speed improves in the future, we might
add back the traditional patch capabilities.
StarLogo also includes some new features, including a "grab" primitive
to facilitate turtle-turtle interactions, and new capabilities for
adding sound effects to your programs. We expect that later versions
of StarLogo will enable you to integrate StarLogo models into Web
pages, creating your own "active essays" on the Web. (See
http://el.www.media.mit.edu/groups/el/projects/emergence for an
example of an active essay.)
This document will discuss: how to run StarLogo; the differences
between StarLogo and traditional MacStarLogo; the system requirements
for running this beta version; some implementation issues.
The primitives in this beta version of StarLogo are listed in a
companion document reference.txt. Most of the primitives behave the
same as in MacStarLogo (so you can use the MacStarLogo documentation
at http://www.media.mit.edu/starlogo/documentation for more
information). A few primitives are new and are explained in more
detail.
StarLogo is clearly still a work in progress. We plan to add more
features in the coming months. As we create new versions, they will be
available from http://www.media.mit.edu/starlogo.
As you use StarLogo, please let us know what you think. Please send
suggestions and bug reports to bug-starlogo@media.mit.edu. (Be sure to
mention which Java runtime system you're running with so we can easily
pin down any problems.)
Thanks again for trying out this new version of StarLogo!
-------------------------------------------------
2. HOW TO RUN STARLOGO
-------------------------------------------------
To use StarLogo, you will need to have a version of Java 1.1 or higher
installed on your computer. If you have a Windows PC and Internet
Explorer 4.0 or higher, then you most likely already have a good
enough version of Java to run StarLogo. Try it out and see. If not,
you will need to install a Java runtime system which you can get from
Microsoft or Sun (for Windows PCs), Apple (for Macs), or your
particular operating system vendor (Unix).
Read the following to find out how to run StarLogo on your computer.
***** On a Windows PC *****
1. Double-click on the starlogo.bat file.
StarLogo should start up and pop two windows up on the screen. If you
don't see them, they might be hidden behind other windows. Check your
taskbar for them.
If you don't have Internet Explorer 4.0 or greater installed, this
isn't going to work. You should go to Microsoft's home page and
download Internet Explorer 5.0.
If you have Sun's JDK 1.1.x or 1.2.x (from http://java.sun.com),
double-click on starlogo-sun.bat instead. We have found that Sun's
Java is much faster than the one from Microsoft. After installation,
you'll need to make sure that the JRE bin directory is in your PATH.
***** On a Mac *****
Make sure that you have MRJ 2.1.4 (or 2.2) (from
http://www.apple.com/java) installed on your Macintosh before trying
to run StarLogo.
1. Double-click on the StarLogo application.
StarLogo should start up and pop two windows up on the screen.
You might see strange behavior when pressing the enter key in the
command center. There is a bug in MRJ 2.1.4 (which is fixed in MRJ
2.2) which erases the carriage return character from the command
center after the line is run. If you see this behavior and don't like
it, go to Apple's developer home page
(http://developer.apple.com/java) and download (and install) the early
access release of MRJ 2.2.
***** On Unix *****
(we've successfully run StarLogo on Solaris 2.6 and 2.7)
1. Install your favorite Java 1.1.x or Java 1.2.x.
2. Go to the StarLogo distribution directory.
3. Execute the unix-run-starlogo shell script.
Note: We've seen that StarLogo requires that you set Java to use a
larger stack size. This is necessary with Sun's Java; we're not sure
whether this is necessary on other Unixes.
-------------------------------------------------------------
3. STARLOGO VS. MAC STARLOGO
-------------------------------------------------------------
1. Patches as active entities have been removed in the name of
performance (and simplification). Patches still exist, however, as
passive entities, which the turtles and the observer can act upon,
such as reading and writing the patch color and any patches-own
variables. In addition, diffuse, nsum and nsum4 still exist and may be
used as observer commands.
2. Turtle code and observer code now live in separate procedure
windows, and there are separate command centers as well. In order to
run observer code, turtles must explicitly ask the observer to run it
using ask-observer [do-something]. Likewise, in order for the observer
to run turtle code, it must ask the turtles to run something with
ask-turtles [do-something].
3. The turtles and the observer are now completely multi-threaded, so
they can be running multiple processes/buttons at the same time and
have them execute in parallel. Turtle code and observer code are also
now scheduled independently of one another, so they will run in
parallel with respect to each other as well.
4. The turtles and the observer now both run at the same speed. This
means no more slowdowns by running observer code. In addition, the
turtles now gain all of the features that only the observer was able
to perform, such as the more complicated mathematical functions and
list manipulation.
5. There is a new command called grab. This lets you hold onto a
turtle or list of turtles and run some code on them. It encompasses
this popular StarLogo idiom:
turtles-own [which-turtle]
to mate
if count-turtles-here > 0
[setwhich-turtle one-of-turtles-here
mate-with which-turtle]
end
and replaces it by this:
to mate
grab one-of-turtles-here
[mate-with partner]
end
If there is no turtle to grab, the code is not run. Once the turtle
has been grabbed, you may refer to it as "partner". If multiple
turtles have been grabbed (via nesting grab calls, or passing a list
of turtles to grab), you may refer to them as "partners".
6. The syntax for setting a variable is slightly different. There is
now a space between the "set" and the variable name:
turtles-own [energy]
to foo
set energy energy + 1
end
The old form, "setenergy", still works in this version.
7. The variable suffixes have new altered behavior:
-of <turtle's who>
allows you to get the turtle variable belonging to a
particular turtle. This hasn't changed at all.
-at <absolute xcor> <absolute ycor>
allows you to get the turtle or patch variable at the absolute
location <xcor, ycor>. Note: MacStarLogo uses relative
coordinates. Thus, to get relative coordinates <1,1> from Java
StarLogo, you must use "foo-at xcor + 1 ycor + 1"
-towards <absolute angle> <distance>
allows you to get the turtle or patch variable which is distance
units away in the direction of the absolute angle. To use this
for relative directions, add heading to the given angle:
"foo-towards heading + 45 5"
8. StarLogo now supports sound effects! We have included in this
distribution a folder called sounds. In this folder, are sound files
in the .au format. Both the observer and turtles may play sounds. If
more than one sound is played, they will get mixed and the volume will
increase. Each turtle may only play one sound file at a time. If a
turtle tries to play another sound file while playing the first one,
the first one will stop and the second one will begin. The command is
called "play-sound" and takes the quoted name of a sound file in the
sounds folder without the .au extension. Here is an example:
to move-and-cluck
right random 40
left random 40
forward 1
play-sound "chirp"
end
You can add your own sounds to StarLogo by putting them into the
sounds folder.
Note: starlogo.bat uses Microsoft Java. We have found that MS Java
doesn't play multiple simultaneous sounds very well. If you want each
turtle to play a sound simultaneously with each other, you might
consider downloading Sun's JDK 1.1.x or 1.2.x and using
starlogo-sun.bat.
9. This beta version has no paint tools, no output window, no shapes,
no turtle monitors, and no information window. We expect to add these
features in later versions.
10. There is a new text-only file format. It saves the entire state of
the turtles, patches, and observer. It also saves the code in the
procedure windows and the interface. You can open a MacStarLogo file
with StarLogo and it will translate it to the new format. However, the
code will most likely not run, due to the new split between observer
and turtles. We hope to make an add-on to MacStarLogo to save files
in the StarLogo file format.
-----------------------------------------
4. SYSTEM REQUIREMENTS
-----------------------------------------
1. This version has been developed with Sun's JDK 1.1.x
(http://java.sun.com/products/jdk/1.1/index.html), and Sun's JDK 1.2.x
(http://java.sun.com/products/jdk/1.2/index.html). We recommend going
to Sun and picking up one of these today.
2. This version was initially developed on a Windows PC using Sun's
JDK. Many of the assumptions made about screen layout and file
linefeed termination and other such platform-specific features might
not be correct for your platform. We have since expanded our
development effort to include Microsoft's Java and Apple's MRJ, and
made adjustments accordingly. However, while the Java portion of
StarLogo is "Write Once, Run Anywhere," in the regions of Java
semantics where this isn't quite true, it may look odd on some
systems.
3. This program was designed to be an application, not an
applet. While it may be possible to make it run through a Web browser
(it could run in Windows IE 4.0/5.0 or Mac IE 4.5, but not in Windows
Netscape 4.x nor Mac Netscape 4.x), this isn't recommended. One major
issue: you can't save files when using it as an applet.
-----------------------------
5. IMPLEMENTATION
-----------------------------
StarLogo is based partly on Java code and partly on a language we
created, called YoYo (http://el.www.media.mit.edu/yoyo). YoYo is a
variant of Logo that is built on Java and allows you to construct
Logo/Java hybrid programs and put them on the Web. We've used YoYo
here to write the StarLogo compiler and script our user interface.
Andrew Begel
Computer Science Dept.
University of California, Berkeley