To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.spyboticsOpen lugnet.robotics.spybotics in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / Spybotics / 159
158  |  160
Subject: 
Spybotics API in NQC
Newsgroups: 
lugnet.robotics.spybotics
Date: 
Fri, 10 Jan 2003 05:34:08 GMT
Viewed: 
6428 times
  
I'm attempting to extend the API that Dave Baum started with 2.5a4.
Particularly, I'm working on getting access to the ROM library of
subroutines.  I'm not sure if I'm going about it wrong or not, but I'm
posting this to see if others are looking in the same area.

The Spybotics ROM subroutines are listed in the Spybotics ROM
Documentation.pdf file in the Lego Mindstorms SDK.  The LASM byte code
file for the Spybotics shows me the byte code to make a subroutine
call . In fact, it's the same as for the Scout so using the NQC API
call that the Scout does works (or I think it should).

You end up with a routine that looks like:

void Call(const int n) { asm { 0x17, n }; }

which can be used by Call (sub_number).

However, the difficulty I'm having is the parameters for the
subroutines.  I don't know if these should be passed on the stack, in
variables, registers, as byte-codes, or what.  I read in the Scout SDK
where the data sources are defined that the words specifically mention
that subroutine parameters are from source 0.  However, the Spybotics
SDK doesn't discuss this at all.

Anybody have any idea about this?

Ultimately, what I'm working on is porting the
SpybotMissionTemplate.rcx2 to NQC.  I know I could just use MindScript
for all this, but I really don't want to.



1 Message 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