To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.rcx.pbforthOpen lugnet.robotics.rcx.pbforth in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / RCX / pbFORTH / 25
24  |  26
Subject: 
Re: SENSOR_READ doesn't return 0
Newsgroups: 
lugnet.robotics.rcx.pbforth
Date: 
Tue, 13 Apr 1999 09:07:51 GMT
Reply-To: 
ROBOTS@JPSC.stopspammersCO.UK
Viewed: 
1637 times
  
I have been experimenting with the latest version of pbFORTH (102)

AhA! Another victim within my clutches!!!!! Glad to hear you are trying
things out, John. The more questions I get, the sooner I can get a FAQ
out to help with the common ones.

I am just dabbling at the moment, trying a few words to try and get them
debugged. In order to fully port the SpeedBot (currently in NQC) I'll need
multitasking...

Which announces itself thus:

hhii


hForth H8/300 for RCX RAM Model V1.0.0 by Ralph Hempel, 1998

All noncommercial and commercial uses are granted.

Please send comments, bug reports and suggestions to:

  rhempel@bmts.com

That's a good sign, at least.

Oh, good - I wondered if I'd got versions mixed up somewhere. It would be a good
idea to change it to match the number of the release (V1.0.2 I presume).

I cannot get the LIGHT? word (tracker.txt) to work, it seems never to
return 0, usually 200 or 300 (hex). I am initialising using:

1 CONSTANT RawLight
1 CONSTANT RunButton
3 CONSTANT MotorStop

You have obviously had some FORTH experience, I'll have to admit I haven't
fully tested the CONSTANT word...

It hadn't occurred to me that ther might be something wrong with CONSTANT, but I
think the problem was there before. Making the sensor idx a constant was one of
the things I did to make sure that I didn't have an inconsistancy.

: BOT_INIT

  ." BOT_INIT" CR \

  RCX_INIT
  POWER_INIT
  BUTTON_INIT
  SENSOR_INIT

    RawLight SENSOR_ACTIVE
  3 RawLight SENSOR_TYPE   ( Light )
  0 RawLight SENSOR_MODE   ( Raw )

;

What is the significance of a non-zero return by SENSOR_READ ?

This LOOKS ok, the non-zero return generally indicates BUSY, or not ready.

I wondered if the actual values had any significance.

First off, does the script as presented work? In other words, does TRACKER.TXT
work on your RCX? If so, then I'd be looking at the CONSTANT word and making
sure it works properly too.

I need to move the motor connections to implement Tracker, which are buried
under the claw mounting, which is why I haven't done it up to now, but it looks
like I have to bite that bullet.

Please email me again if you have problems, and give me as much feedback as
you can, good or bad...

Do you have a list of all the words defined by pbFORTH (no WORDS or SEE). I have
been working through the .ASM files extracting the comments, but if you have a
readymade list somewhere, that would help.

How do you use RCX_INIT POWER_INIT and POWER_OFF to shutdown? and how do you get
it back once shutdown - the ON/OFF button?

Cheers,

Ralph Hempel - P.Eng
--
John & James Cooper, Wallington, UK



Message is in Reply To:
  RE: SENSOR_READ doesn't return 0
 
(...) AhA! Another victim within my clutches!!!!! Glad to hear you are trying things out, John. The more questions I get, the sooner I can get a FAQ out to help with the common ones. (...) That's a good sign, at least. (...) You have obviously had (...) (26 years ago, 13-Apr-99, to lugnet.robotics.rcx.pbforth)

10 Messages in This Thread:



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

Custom Search

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