|
|
Up |
  |
Author: jpbjpb Date: Jul 28, 2008 16:29
Hi,
I wrote a small but handy framework in C for
bootstrapping a Forth system, thus for
creating a "Forth Kernel". Hence the name,
even when it's already taken by a Forth
boot-loader for BSD systems(when you know a
better name let me know it).
How do you create a "Forth Kernel", thus a
small forth system for building the rest of the
system? You write your custom primitives in C,
add a bit of your own startup code to it,
compile it and then you have the "Forth Kernel".
Why? Because I wanted to start my own
forth system through writing in itself, without
ANS Forths, etc. flavor in it, just my own
ideas.
Whoever is interested into it:
http://gitorious.org/projects/bootforth
I'm interested in your opinions or ideas about it.
|
| Show full article (0.76Kb) |
| 19 Comments |
|
  |
Author: Nickolai LeschovNickolai Leschov Date: Jul 30, 2008 02:39
jpb wrote:
> I'm interested in your opinions or ideas about it.
Hi, I've just built the sample on Windows and it works! I already had
mingw and git installed.
I totally understand your idea. I will look into the source now.
Do you think it's possible to make BootForth run on an embedded system
with 1.5K of RAM and 32K of ROM?
Best wishes,
Nickolai Leschov
|
| |
| no comments |
|
  |
Author: jpbjpb Date: Jul 30, 2008 06:19
Nickolai Leschov gmail.com> wrote:
> Hi, I've just built the sample on Windows and it works! I already had
> mingw and git installed.
Good to know. So it seems quite portable.
> I totally understand your idea. I will look into the source now.
Hopefully you understand it. Because most people who I'm talking to
about it, don't get the point of it at the first explanation try.
Well, I should take a better name than "BootForth", even when it means
in that case bootstrapping a Forth System and not booting a computer.
> Do you think it's possible to make BootForth run on an embedded system
> with 1.5K of RAM and 32K of ROM?
At the current moment, I don't think so. It depends on a couple of
standard C functions which need something like a library.
But why, should you want to run BootForth on an
embedded system with those limitations?
For the joy? Or because you can? Both are good targets
and probably it would fit into the ROM, but the RAM
is too small and it assumes the whole memory space
for it's own, which means that it's not ROM-able.
|
| Show full article (1.33Kb) |
| no comments |
|
  |
Author: Bruce McFarlingBruce McFarling Date: Jul 30, 2008 09:46
On Jul 30, 9:19 am, jpb wrote:
> Well, I should take a better name than "BootForth", even when it means in that case bootstrapping a Forth System and not booting a computer.
Maybe the fact that "BootXYZ" is normally read as meaning booting the
computer is the problem.
Forthstrap?
|
| |
| no comments |
|
  |
Author: Jonah ThomasJonah Thomas Date: Jul 30, 2008 10:07
jpb wrote:
> Well, I should take a better name than "BootForth", even when it means
> in that case bootstrapping a Forth System and not booting a computer.
Maybe call it BootstrapForth?
|
| |
| no comments |
|
  |
Author: Nickolai LeschovNickolai Leschov Date: Jul 31, 2008 03:08
jpb wrote:
>> Do you think it's possible to make BootForth run on an embedded system
>> with 1.5K of RAM and 32K of ROM?
> At the current moment, I don't think so. It depends on a couple of
> standard C functions which need something like a library.
Embedded processors (microcontrollers) nowadays are normally programmed
in C. (sometimes, C++ even) Therefore, there is standard library. I hope
that there would be just a few things to consider to be able to run
Forth on a microcontroller; here's the ones that come to mind:
1. Using malloc/free is impractical, even though it may be implemented
in standard library.
2. IO device is a serial line, which may be used by the application as
well. Again, this may or may not be accounted for in the implementation
of the standard library.
> But why, should you want to run BootForth on an
> embedded system with those limitations?
I think Forth could fit such systems. I would like to be able to use
umbilical Forth on such system. Currently I'm stuck with C's
edit/compile/test cycle. In-curcuit debugging is not available and
programming (writing binary code) is not instantaneous and is apart from ...
|
| Show full article (1.92Kb) |
| no comments |
|
  |
Author: MakiMaki Date: Jul 31, 2008 03:38
"Nickolai Leschov" gmail.com> wrote in message
news:g6s397$kac$1@aioe.org...
> jpb wrote:
>>> Do you think it's possible to make BootForth run on an embedded system
>>> with 1.5K of RAM and 32K of ROM?
>> At the current moment, I don't think so. It depends on a couple of
>> standard C functions which need something like a library.
> Embedded processors (microcontrollers) nowadays are normally programmed in
> C. (sometimes, C++ even) Therefore, there is standard library. I hope that
> there would be just a few things to consider to be able to run Forth on a
> microcontroller; here's the ones that come to mind:
> 1. Using malloc/free is impractical, even though it may be implemented in
> standard library.
> 2. IO device is a serial line, which may be used by the application as
> well. Again, this may or may not be accounted for in the implementation of
> the standard library.
>> But why, should you want to run BootForth on an embedded system with
>> those limitations?
> I think Forth could fit such systems. I would like to be able to use
> umbilical Forth on such system. Currently I'm stuck with C's ...
|
| Show full article (2.41Kb) |
| no comments |
|
  |
Author: Elizabeth D RatherElizabeth D Rather Date: Jul 31, 2008 10:30
Nickolai Leschov wrote:
> jpb wrote:
>>> Do you think it's possible to make BootForth run on an embedded
>>> system with 1.5K of RAM and 32K of ROM?
>> At the current moment, I don't think so. It depends on a couple of
>> standard C functions which need something like a library.
Assuming you have flash instead of real ROM, it's quite possible in
SwiftX (which doesn't use any C).
...
>> But why, should you want to run BootForth on an embedded system with
>> those limitations?
> I think Forth could fit such systems. I would like to be able to use
> umbilical Forth on such system. Currently I'm stuck with C's
> edit/compile/test cycle. In-curcuit debugging is not available and
> programming (writing binary code) is not instantaneous and is apart from
> running. I used to use Forth in the past and I'd like to use Forth's
> interactivity in my embedded project.
You should really check out one of the evaluation versions of SwiftX and
see how its umbilical system works.
|
| Show full article (2.14Kb) |
| no comments |
|
  |
Author: rickmanrickman Date: Jul 31, 2008 11:57
On Jul 31, 1:30 pm, Elizabeth D Rather forth.com> wrote:
> Nickolai Leschov wrote:
>> jpb wrote:
>>>> Do you think it's possible to make BootForth run on an embedded
>>>> system with 1.5K of RAM and 32K of ROM?
>>> At the current moment, I don't think so. It depends on a couple of
>>> standard C functions which need something like a library.
>
> Assuming you have flash instead of real ROM, it's quite possible in
> SwiftX (which doesn't use any C).
>
> ...
>
>>> But why, should you want to run BootForth on an embedded system with
>>> those limitations?
>> I think Forth could fit such systems. I would like to be able to use
>> umbilical Forth on such system. Currently I'm stuck with C's
>> edit/compile/test cycle. In-curcuit debugging is not available and
>> programming (writing binary code) is not instantaneous and is apart from
>> running. I used to use Forth in the past and I'd like to use Forth's ...
|
| Show full article (2.46Kb) |
| no comments |
|
  |
Author: Stephen PelcStephen Pelc Date: Jul 31, 2008 12:25
On Wed, 30 Jul 2008 13:39:01 +0400, Nickolai Leschov
gmail.com> wrote:
>Do you think it's possible to make BootForth run on an embedded system
>with 1.5K of RAM and 32K of ROM?
An MPE cross compiler can build a full interactive Forth in
that space! There's an MSP430 somewhere on my desk ...
Stephen
--
Stephen Pelc, stephenXXX@ mpeforth.com
MicroProcessor Engineering Ltd - More Real, Less Time
133 Hill Lane, Southampton SO15 5AF, England
tel: +44 (0)23 8063 1441, fax: +44 (0)23 8033 9691
web: http://www.mpeforth.com - free VFX Forth downloads
|
| |
| no comments |
|
RELATED THREADS |
  |
|
|
|
|
|