To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.rcx.javaOpen lugnet.robotics.rcx.java in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / RCX / Java / 45
44  |  46
Subject: 
Re: please help with threaded robot program
Newsgroups: 
lugnet.robotics.rcx.java
Date: 
Tue, 20 Feb 2001 18:32:43 GMT
Viewed: 
2363 times
  
Hi Susan,

Subsumption works great in leJOS. See this message for some example
code:

http://news.lugnet.com/robotics/rcx/java/?n=23

I think what you're missing is an arbitrator, which will probably run as
yet another thread.

Regards,
Jonathan

Susan Hoover wrote:

Hi, this is my first message to the robotics groups.  A little background: I've
had RIS 1.0 for a couple of years, I have ~14 years of programming experience
but only 1 year of Java (mostly server side).

I downloaded leJOS beta 3 last week and wrote a simple program that goes
forward, turns, and backs up when it hits a wall, but it was strictly a
procedural do this - then do that kind of program.  I am also reading Jonathan's
book for tips.

My question is this: will subsumption architecture work under leJOS?  I tried
implementing something similar what's in the Robotag chapter, except with fewer
tasks.  My program has two tasks: (1) go forward (following a line) and (2)
react to falling off the line.  I kicked off a new thread for each of these
tasks.  However, when I run it, it just keeps going forward as if the "hey, am I
off the line?" thread is not even there (or is not getting processing time).
Since I haven't done a whole lot of thread programming, I'm not sure whether the
problem lies in (1) my understanding of subsumption architecture, (2) my
implementation of threaded tasks, or (3) something in leJOS.

The code is here if anyone wants to look at it: <URL: http://code.shoover.com/>

Thanks in advance for any assistance,
Susan



Message has 1 Reply:
  Re: please help with threaded robot program
 
(...) Thanks for the pointer. I'll go check it out. (My bad for not actually searching on "subsumption" -- I think I searched for +lejos +thread.) Susan (24 years ago, 22-Feb-01, to lugnet.robotics.rcx.java)

Message is in Reply To:
  please help with threaded robot program
 
Hi, this is my first message to the robotics groups. A little background: I've had RIS 1.0 for a couple of years, I have ~14 years of programming experience but only 1 year of Java (mostly server side). I downloaded leJOS beta 3 last week and wrote (...) (24 years ago, 19-Feb-01, to lugnet.robotics.rcx.java)

3 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