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 / 302
301  |  303
Subject: 
Re: Comment file?
Newsgroups: 
lugnet.robotics
Date: 
Fri, 6 Nov 1998 18:06:06 GMT
Original-From: 
Kekoa Proudfoot <kekoa@Graphics.Stanford.EDU>
Viewed: 
2236 times
  
I'm looking at the disassembly, and I see the comment file is rather old
(21 Oct). Is there a later version, so I don't duplicate effort?

If you don't want to duplicate effort, do not wade through the firmware.
It has been done already, but there is no comment file.  Instead, I
documented the firmware with pseudocode.  See:

http://grephics.stanford.edu/~kekoa/rcx/#Rom

Things are not complete on the pages, so feel free to ask questions, or (if
I don't get back to you as quickly as you'd like) to step through the
disassembly on points that are not clear - although be warned that I have
gone through 95% of the disassembly line-by-line and I probably know the
answer already.  Also be warned that I am up to my ears with other things,
both RCX related and not.  My priorities are not to explain the firmware,
although I will do so if I have time or want to procrastinate (like I'm
doing now).

Also, am I being dim, or is this silly?

008D04  0CEC                mov.b r6l,r4l
008D06  6D75                pop   r5
008D08  6D74                pop   r4

Doesn't the pop obliterate the mov.b? This seems to happen all over the
place...

Yes, the pop r4 obliterates the mov.b.  It's not clear what the intent was
here.  Given that the compiler used by the Lego folks generated such
terrible code, it's not surprise that you see superflouous opcodes lying
about.

The function you are referring to, 8cf4, is the cleanup routine for the
third handler.  The function it calls, 27f4, returns 0 in r6l, which the is
then stored in r4l at 8d04, presumably in case it needs it later, which it
doesn't.  The function 8cf4 then returns this value (the return value of
27f4) in r6.

But if you look at where 8cf4 is called (80f2 - jsr @r5), you will see that
the return value in r6l is simply ignored.  Specifically, note the bra to
80fe, which proceeds to load @cc33 into r6l.  cc33 contains the power on
flag.  (sigh)

The function at 27f4 is the complement of the stuff done in 1aba, which is
documented on my web page.

-Kekoa



1 Message in This Thread:

Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    
Active threads in Robotics

 
Verified and Trusted Team of Hackers
5 hours ago
Custom Search

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