ROMable High Level Languages
Timothy Hansell
hansell at poppy.cis.ohio-state.edu
Sat Mar 11 10:00:23 AEST 1989
>In article <8902152259.AA04690 at wpi> GREYELF at WPI.BITNET writes:
>| | I made a 65c02 handheld computer about 1 year ago, with a seiko 4x20lcd
>| | screen.
> .... [stuff deleted]
>
I just wanted to post a note about how easy I found C to rom.
I created a boot program for a 68000 based system. The initial routine
that got called upon power on was in assembler, but after I set up enough
of a stack enviroment I jumped to C. I generated all of the binaries using
the Sun C compiler, and linker, ( linking in my own rommable version of
the libc routines that I used ) and was able to take this binary, burn it
in the prom directly and have it work.
This is not so much of an praise for the Sun c compiler, which you
would not be able to use, but a comment that it only took about a week to
create my prommed versions of the libc routines ( there were a whole lot
more simple than the Unix versions ). I just provided the capability I needed
to use, and ignored unecessary fluff.
If a C compiler is available for the CPU you are using, try it.
Or another option is to Port the Small-C compiler ( which generates Mneumnic
assembly code ) to generate the assembler for the chip you are using. You code
write your routines in Small-C, and tweak the assemle output if you want.
Currently the Small-C comes in two flavor's 8080 and 8086. But it is
possible that someone has generated a version for the 6502.
I am biased for C ( if you can get it )
-tim
More information about the Comp.lang.c
mailing list