To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.rcxOpen lugnet.robotics.rcx in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / RCX / 2206
2205  |  2207
Subject: 
Re: Low level programming of the RCX
Newsgroups: 
lugnet.robotics.rcx
Date: 
Fri, 12 Sep 2003 15:49:58 GMT
Viewed: 
3395 times
  
In lugnet.robotics.rcx, Benjamin Sigonneau wrote:
Hello everybody,

I try to program the RCX at low level. I want to be able to program
using the Hitachi h8/3292 directly. For example, I want to use the
free-running timer, define own interrupt handlers and so on. In fact, I
*really* need to control the timer (this is for educational purpose).

My tries so far leads to failures... I tried using Quite C and libRCX,
but I think I have to shortcut some ROM routines (particularly the
init_timer routine).

Can anyone give me a tip about controlling Hitachi free-running timer
directly ? Thanks.

Quite C is your best place to start with a language.  C can give you direct
access to the timer.  The timer is considered an I/O device, but all I/O on the
H8 is memory mapped.  Having said that, if you know the address of the timer,
you can access it for writing and reading.  If quite C does not provide you with
access to the interrupt handlers directly, you should be able to walk the
interrupt mechanism in memory and figure out where the default interrupt handler
is (I'm guessing a bit here).

A good place to learn *everything* you want to know about this is brickOS.  I'm
sure it has all this solved.

Maybe you just want to start there and modify the source as necessary.

I don't know if you can short cut the init_timer routine, but you might be able
to write over the top of whatever it does to get what you want.

Again, brickOS comes with the source, so you can hack it (I mean this in the
geek sense of the word, not the media's).

I've not looked ad brickOS source myself much, but the parts I have looked at
look very well laid out.

Good luck,
Kevin



Message has 2 Replies:
  Re: Low level programming of the RCX
 
(...) [snip] (...) [snip] I'll second that. The BrickOS source code provides a good example of using the FRC as well as other low-level I/O. Between that source and the H8 manuals, you should be set. If you have specific questions, there are quite a (...) (21 years ago, 12-Sep-03, to lugnet.robotics.rcx)
  Re: Low level programming of the RCX
 
(...) Speaking of Quite C, I am working on figuring out a good way to integrate Quite C into the BricxCC system. It is a bit different from the other languages BricxCC supports in that you compile to an SREC and download it as a new firmware rather (...) (21 years ago, 12-Sep-03, to lugnet.robotics.rcx)

Message is in Reply To:
  Low level programming of the RCX
 
Hello everybody, I try to program the RCX at low level. I want to be able to program using the Hitachi h8/3292 directly. For example, I want to use the free-running timer, define own interrupt handlers and so on. In fact, I *really* need to control (...) (21 years ago, 12-Sep-03, to lugnet.robotics.rcx)

7 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