To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.roboticsOpen lugnet.robotics in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / 4827
4826  |  4828
Subject: 
Re: Something else is needed, I think...
Newsgroups: 
lugnet.robotics
Date: 
Tue, 4 May 1999 16:07:05 GMT
Viewed: 
1229 times
  
Java is a very good language, but *NOT* a very good choice of language for robot
control.  Java's greatest strength is its portability, but portable programs in
hardware like the RCX, are not likely to accomplish much.  (Have you ever tried to
write a device driver in Java?   Sorta defeats the point to writing in Java,
doesn't it?)  Further, Java bytecode is many many many times more complicated than
something else which just controls the RCX needs to be.  The key advantage to
making a JVM for the RCX seems to be that there would be no need to design a new
bytecode set, and especially that there would be no need to develop compilers for
it because there already exists an abundance of them for all sorts of platforms.  I
believe that the people who think that this makes implementing a JVM for the RCX
worthwhile are either under the impression that java is practical for
device-dependent code, or they believe that writing a compiler is too hard.  The
former is defintely not true.  As for the second, well... I've had experience
writing compilers and interpreters, and while I'd say that it's certainly a
challenging task, it's actually not that difficult to do when one has a good
knowledge of the target code, and if the source code language specification is
consistent and not overflowing with exceptions.  I've found it to be more tedious
than difficult, actually.  What *IS* hard is designing a virtual machine (bytecode
interpreter) in such a way that programs running under it can do pretty much
anything that is computationally possible as well as being able to control every
aspect of the hardware in an absolutely minimal set of instructions, while at the
same time, being complex enough to not require lengthy sequences of instructions to
perform most relatively simple tasks.   A minimal instruction set is required so
that the interpreter does not take up space that would otherwise be useful for
program and code storage, and a moderately complex set is required because with too
simple an instruction set, an instruction sequence to do even the most simple
things would be dozens, hundreds, or sometimes even thousands of instructions long,
thereby again, reducing the amount of useful code that you can fit within a finite
amount of space.  This balancing act is one of the greatest challenges to robust
instructiion set design.  I can appreciate the tendency for some people to simply
throw up their hands and surrender to the idea that we should use a pre-designed
bytecode set.

Nevertheless, I would maintain that in spite of the difficulty, it would still be a
worthwhile project to undertake.  The RCX is a pretty cool piece of hardware, in
spite of its physical limitations.  A more robust programming environment for it
that could come about through a more versatile bytecode set would open up a world
of new possibilities to people who may not have the technical expertise to use
LegOS (or find it too cumbersome), but still find the limitations of the standard
firmware too restrictive.  Such people, I would expect, are quite distinctly in the
majority.

Mark



Message has 1 Reply:
  Re: Something else is needed, I think...
 
(...) Don't forget writing the bytecode interpreter. With JVM, we just have to port that. Writing a bytecode interpreter that is fast, general purpose, supports multithreading & synchronization etc. is no small task. (...) Java would not be used for (...) (25 years ago, 4-May-99, to lugnet.robotics)

Message is in Reply To:
  Re: Something else is needed, I think...
 
I say let us go ahead and make this JVM for the RCX. I am in, Any other volunteers? As I have previously announced (in the LegOS) group that I was going to do this one person has already agreed to volunteer. As a side note take a look at: (URL) (...) (25 years ago, 4-May-99, to lugnet.robotics)

67 Messages in This Thread:






















Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact

This Message and its Replies on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR