mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Vanalme Filip <F.Vanalme@TELEVIC.com>
To: Sascha Hauer <s.hauer@pengutronix.de>
Cc: "barebox@lists.infradead.org" <barebox@lists.infradead.org>
Subject: RE: test app
Date: Tue, 8 Mar 2011 13:43:21 +0100	[thread overview]
Message-ID: <6EE7D1502C48E44E92DCADF9DD3E0DB9017FF3B0123D@SRV-VS06.TELEVIC.COM> (raw)
In-Reply-To: <20110308114319.GU29521@pengutronix.de>

> -----Original Message-----
> From: Sascha Hauer [mailto:s.hauer@pengutronix.de]
> Sent: dinsdag 8 maart 2011 12:43
> To: Vanalme Filip
> Cc: Baruch Siach; barebox@lists.infradead.org
> Subject: Re: test app
> 
> On Tue, Mar 08, 2011 at 11:09:57AM +0100, Vanalme Filip wrote:
> > > -----Original Message-----
> > > From: barebox-bounces@lists.infradead.org [mailto:barebox-
> > > bounces@lists.infradead.org] On Behalf Of Vanalme Filip
> > > Sent: dinsdag 8 maart 2011 9:13
> > > To: Baruch Siach
> > > Cc: barebox@lists.infradead.org
> > > Subject: RE: test app
> > >
> > > Thank you Baruch ! Good starting point for my test app.
> > >
> > > > -----Original Message-----
> > > > From: Baruch Siach [mailto:baruch@tkos.co.il]
> > > > Sent: dinsdag 8 maart 2011 6:40
> > > > To: Vanalme Filip
> > > > Cc: barebox@lists.infradead.org
> > > > Subject: Re: test app
> > > >
> > > > Hi Vanalme,
> > > >
> > > > On Mon, Mar 07, 2011 at 02:05:32PM +0100, Vanalme Filip wrote:
> > > > > We would like to have a kind of small test application, that can be
> > > > > started from the barebox prompt, to do some basic tests on some hardware
> > > > components.
> > > > > What's the best way to do that ? E.g. can I add that test application
> > > > > to the environment and would this be good practice ? Or do I better
> > > > > extend the barebox commands with my own command to start the tests ?
> > > > > Maybe there's an example on how to do it ?
> > > >
> > > > I'm using the attached program to do a simple RAM read/write test on i.MX25.
> > > > This program runs on bare hardware from the internal chip SRAM, and
> doesn't
> > > rely
> > > > on the Barebox run-time code.  I only use Barebox to start this program.
> > > >
> > > > The program is built with the following Makefile rules:
> > > >
> > > > all: ramtest.bin
> > > >
> > > > %.bin: %.elf
> > > >     ${OBJCOPY} -O binary $^ $@
> > > >
> > > > ramtest.elf: ramtest.c
> > > >     ${CC} -Wall -Os -nostdlib $^ -o $@ -Wl,-Ttext=0x78000000
> > > >
> > > > Running this program from the Barebox prompt:
> > > >
> > > > cp ramtest.bin /dev/sram0
> > > > go /dev/sram0
> > > >
> > > > I hope this helps.
> > > >
> > > > baruch
> > > >
> >
> > [Filip]
> >
> > As a start, I just took over your Makefile and a minimal source file :
> >
> > __asm__ (".text\n"
> >         ".globl _start\n"
> >         "_start:\n"
> >         "ldr    sp, =0xA7E00000\n"
> >         "bl     main\n"
> >         "stop:\n"
> >         "b      stop\n"
> >         );
> >
> > int main (int argc, char *argv[])
> > {
> > 	return 0;
> > }
> >
> > I think I might still miss something because the assembler part gives me errors
> e.g.
> > 	" Error: no such instruction: 'ldr sp,=0xA7E00000' "
> > 	" Error: no such instruction: 'bl main' "
> > 	" Error: no such instruction: 'b stop' "
> 
> Just a guess, did you set $CC to your cross compiler?

[Filip] 

Of course.....How could I have missed that... shame...Think I badly need a holiday one of these days... ;-)
Thanks anyway
> 
> Sascha
> 
> --
> Pengutronix e.K.                           |                             |
> Industrial Linux Solutions                 | http://www.pengutronix.de/  |
> Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
> Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

  reply	other threads:[~2011-03-08 12:43 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-07 13:05 Vanalme Filip
2011-03-08  5:40 ` Baruch Siach
2011-03-08  8:13   ` Vanalme Filip
2011-03-08 10:09     ` Vanalme Filip
2011-03-08 11:22       ` Baruch Siach
2011-03-08 15:52         ` Vanalme Filip
2011-03-08 18:08           ` Baruch Siach
2011-03-09  8:28             ` Vanalme Filip
2011-03-14 14:55               ` Vanalme Filip
2011-03-14 17:31                 ` Jean-Christophe PLAGNIOL-VILLARD
2011-03-14 18:03                 ` Baruch Siach
2011-03-15 11:03                   ` Vanalme Filip
2011-03-15 11:47                     ` Zoltán Kócsi
2011-03-08 11:43       ` Sascha Hauer
2011-03-08 12:43         ` Vanalme Filip [this message]
2011-03-08 11:50 ` Sascha Hauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6EE7D1502C48E44E92DCADF9DD3E0DB9017FF3B0123D@SRV-VS06.TELEVIC.COM \
    --to=f.vanalme@televic.com \
    --cc=barebox@lists.infradead.org \
    --cc=s.hauer@pengutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox