Re: How to run a "Hello world" on ppc board?

From: Frank (young726_at_yahoo.com)
Date: 04/08/04


Date: 7 Apr 2004 15:20:21 -0700

I think I didn't make myself clear. I haven't had the linux kernel
running on my board yet. The board has only a boot loader. The boot
loader has TFTP and serial port enabled. I am wondering if I can run a
program _before_ I load the linux kernel? In another word, can I use
the boot loader to load a C program and send some data to serial port
so that I can monitor it through minicom?

Thanks,
Frank

"Blane Bramble" <blane@spamguard.lyzard.net> wrote in message news:<ghsdk1-29r.ln1@shelob.lyzard.net>...
> "Frank" <young726@yahoo.com> wrote in message
> news:620b1276.0404062207.4ae6f853@posting.google.com...
> > I am using ppc 405gp and monta vista. How to make a simple "Hello
> > world" C program so that boot loader can load it and run it in RAM?
> > The boot loader already has serial port enabled. I will be happy if I
> > can see the string output on the serial monitor (I am using minicom).
> > Is this kind of program considered running in kernel space or user
> > space? Should I use printf or printk? Could anyone give some detailed
> > compile and link commands?
>
> Read the manuals that come with MontaVista's distribution, and get the board
> to boot the MontaVista kernel via TFTP and NFS. You can then cross-compile a
> test program, put it in the NFS exported directory on your host, and either
> use ssh or a serial terminal (minicom) to log in and run the program.
>
> Blane.



Relevant Pages

  • Re: Hard Drive Question
    ... > The reason being that iirc the linux kernel must reside below the 1024 ... > cylinder to be found by the boot loader. ...
    (alt.os.linux)
  • Re: Cannot call C function in "Simple" boot loader
    ... think I have solve the problem between boot loader and linux kernel. ... Is the cache off? ... > Ignore this unless you have over 2 Gigs of RAM. ...
    (comp.os.linux.embedded)
  • floppy led dont turn off when booting on 2.6
    ... When booting 2.6.7 linux kernel on PC, if the timeout of the boot loader is very ...
    (Debian-User)
  • Re: bootloader internals
    ... This introduces linux 0.11. ... Another good book is Understanding The Linux Kernel by Daniel P. ... > A boot loader finds the kernel image on the ... >boot loader sources, so I cannot say for sure which one ...
    (comp.os.linux.development.system)
  • Re: How to enable debug output for eboot.nb0?
    ... The solution to this is going to be very specific to your boot loader. ... could be that the serial port is not enabled until just before jumping to ... beitman AT applieddata DOT net ... My old eboot.nb0 showed a lot of debug strings into debug serial port, ...
    (microsoft.public.windowsce.platbuilder)