public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] Port to XScale board
@ 2001-08-18 16:21 Cristiano Ligieri Pereira
  2001-08-18 18:46 ` Gary Thomas
  0 siblings, 1 reply; 25+ messages in thread
From: Cristiano Ligieri Pereira @ 2001-08-18 16:21 UTC (permalink / raw)
  To: ecos-discuss

Hi folks,

Right now I have Redboot running on the RAM memory of my XScale board. I'm
trying to make the '$' command to work. In other words, I'm trying to
download some application into the RAM memory using Redboot (instead of
Cygmon), but something wrong is happenig and I'm getting the following
message from the gdb console:

"Ignoring packet error, continuing...
 Ignoring packet error, continuing...
 Ignoring packet error, continuing...
 Couldn't establish connection to remote target
 Malformed response to offset query, timeout
 gdb_config:3: Error in sourced command file:
 You can't do that when your target is `exec'"

Looking at the Redboot source I've noticed that the function breakpoint(),
which is called after issuing the command '$', is the last one called,
which in turn calls HAL_BREAKPOINT(_breakinst). From the comments I've
also noticed that this generates a breakpoint exception. From this point
on what should happen? Why I'm not able to communicate with RedBoot via
GDB? The serial communication Redboot/host is working fine since I'm
seeing the prompt and issuing commands...

Any help or suggestion is appreciated. :-|

Thanks,
Cristiano.

------------------------------------------------------------
Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-18 16:21 [ECOS] Port to XScale board Cristiano Ligieri Pereira
@ 2001-08-18 18:46 ` Gary Thomas
  2001-08-19 15:29   ` Cristiano Ligieri Pereira
                     ` (2 more replies)
  0 siblings, 3 replies; 25+ messages in thread
From: Gary Thomas @ 2001-08-18 18:46 UTC (permalink / raw)
  To: Cristiano Ligieri Pereira; +Cc: ecos-discuss

On 18-Aug-2001 Cristiano Ligieri Pereira wrote:
> 
> Hi folks,
> 
> Right now I have Redboot running on the RAM memory of my XScale board. I'm
> trying to make the '$' command to work. In other words, I'm trying to
> download some application into the RAM memory using Redboot (instead of
> Cygmon), but something wrong is happenig and I'm getting the following
> message from the gdb console:
> 
> "Ignoring packet error, continuing...
>  Ignoring packet error, continuing...
>  Ignoring packet error, continuing...
>  Couldn't establish connection to remote target
>  Malformed response to offset query, timeout
>  gdb_config:3: Error in sourced command file:
>  You can't do that when your target is `exec'"
> 
> Looking at the Redboot source I've noticed that the function breakpoint(),
> which is called after issuing the command '$', is the last one called,
> which in turn calls HAL_BREAKPOINT(_breakinst). From the comments I've
> also noticed that this generates a breakpoint exception. From this point
> on what should happen? Why I'm not able to communicate with RedBoot via
> GDB? The serial communication Redboot/host is working fine since I'm
> seeing the prompt and issuing commands...

First of all, you can load programs using RedBoot's "load" command as
well.

Try turning on GDB's remote debug facility which will display something
about what's going on on the communications line.  Note: it will be running
at the same speed that RedBoot was using, most likely 38400 unless you've
set it up to run otherwise.

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-18 18:46 ` Gary Thomas
@ 2001-08-19 15:29   ` Cristiano Ligieri Pereira
  2001-08-19 15:52   ` Cristiano Ligieri Pereira
  2001-08-20 14:36   ` Cristiano Ligieri Pereira
  2 siblings, 0 replies; 25+ messages in thread
From: Cristiano Ligieri Pereira @ 2001-08-19 15:29 UTC (permalink / raw)
  To: Gary Thomas; +Cc: ecos-discuss

> First of all, you can load programs using RedBoot's "load" command as
> well.

When I use the 'load' command, how should I proceed? I'm using 'kermit' as
my terminal. After issuing 'load', I should close the connection and
transmit the file? I tried this but it didn't work. I have only one serial
port on the board.

> Try turning on GDB's remote debug facility which will display something
> about what's going on on the communications line.  Note: it will be running
> at the same speed that RedBoot was using, most likely 38400 unless you've
> set it up to run otherwise.

That's all I get with the debug messages:

[
r <Timeout: 2 seconds>][<Timeout: 2 seconds>][<Timeout: 2
seconds>][<Timeout: 2 seconds>][<Timeout: 2 seconds>][<Timeout: 2
seconds>][<Timeout: 2 seconds>]Ignoring packet error, continuing...
[<Timeout: 2 seconds>][<Timeout: 2 seconds>][<Timeout: 2
seconds>][<Timeout: 2 seconds>][<Timeout: 2 seconds>][<Timeout: 2
seconds>][<Timeout: 2 seconds>]Ignoring packet error, continuing...
[<Timeout: 2 seconds>][<Timeout: 2 seconds>][<Timeout: 2
seconds>][<Timeout: 2 seconds>][<Timeout: 2 seconds>][<Timeout: 2
seconds>][<Timeout: 2 seconds>]Ignoring packet error, continuing...
target_terminal_ours ()
Couldn't establish connection to remote target
Malformed response to offset query, timeout
target_close (0)
gdb_config:5: Error in sourced command file:
You can't do that when your target is `exec'

It's timing out! I'm setting the baud rate to the proper value - 57600 -
(in the GDB prompt) before trying to download the file.

Thanks,
Cristiano.


^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-18 18:46 ` Gary Thomas
  2001-08-19 15:29   ` Cristiano Ligieri Pereira
@ 2001-08-19 15:52   ` Cristiano Ligieri Pereira
  2001-08-20 14:36   ` Cristiano Ligieri Pereira
  2 siblings, 0 replies; 25+ messages in thread
From: Cristiano Ligieri Pereira @ 2001-08-19 15:52 UTC (permalink / raw)
  To: Gary Thomas; +Cc: ecos-discuss

Ops! I forgot to mention something.

I'm using pretty much the same hal_diag.c as the iq80310 platform but I
had to comment the line to make it work:

HAL_INTERRUPT_MASK(channels[0].isr_vector);

in the function cyg_hal_plf_serial_init(void) because it was crashing.

This also remembers me to ask another question. In the file
hal_platform_ints.h there are many interrupts specific to the iq80310
platform. I'm not sure on how I modify this file. Do I just remove the
ones that doesn't exist on my board (many of them, actually) and keep the
ones I need adjusting the defines. Which other files should be modified to
adjust all these interrupts?

Thanks,
Cristiano.

------------------------------------------------------------
Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira

On Sat, 18 Aug 2001, Gary Thomas wrote:

> 
> On 18-Aug-2001 Cristiano Ligieri Pereira wrote:
> > 
> > Hi folks,
> > 
> > Right now I have Redboot running on the RAM memory of my XScale board. I'm
> > trying to make the '$' command to work. In other words, I'm trying to
> > download some application into the RAM memory using Redboot (instead of
> > Cygmon), but something wrong is happenig and I'm getting the following
> > message from the gdb console:
> > 
> > "Ignoring packet error, continuing...
> >  Ignoring packet error, continuing...
> >  Ignoring packet error, continuing...
> >  Couldn't establish connection to remote target
> >  Malformed response to offset query, timeout
> >  gdb_config:3: Error in sourced command file:
> >  You can't do that when your target is `exec'"
> > 
> > Looking at the Redboot source I've noticed that the function breakpoint(),
> > which is called after issuing the command '$', is the last one called,
> > which in turn calls HAL_BREAKPOINT(_breakinst). From the comments I've
> > also noticed that this generates a breakpoint exception. From this point
> > on what should happen? Why I'm not able to communicate with RedBoot via
> > GDB? The serial communication Redboot/host is working fine since I'm
> > seeing the prompt and issuing commands...
> 
> First of all, you can load programs using RedBoot's "load" command as
> well.
> 
> Try turning on GDB's remote debug facility which will display something
> about what's going on on the communications line.  Note: it will be running
> at the same speed that RedBoot was using, most likely 38400 unless you've
> set it up to run otherwise.
> 

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-18 18:46 ` Gary Thomas
  2001-08-19 15:29   ` Cristiano Ligieri Pereira
  2001-08-19 15:52   ` Cristiano Ligieri Pereira
@ 2001-08-20 14:36   ` Cristiano Ligieri Pereira
  2001-08-20 14:49     ` Gary Thomas
  2 siblings, 1 reply; 25+ messages in thread
From: Cristiano Ligieri Pereira @ 2001-08-20 14:36 UTC (permalink / raw)
  To: Gary Thomas; +Cc: ecos-discuss

Hi,

I kind of solved my RAM redboot problem (however temporarily since I only
removed the cause of the problem from the code instead of fixing it). I
commented out (till I figure out why) the three function calls that were
crashing... :-|

The first is the call to function __clear_breakpoints() whithin the
function __handle_exception (void), which is located in the file
generic-stub.c. Actually this one I haven't commented out but only defined
CYGNUM_HAL_BREAKPOINT_LIST_SIZE to 0, which in turn makes the function do
not be called. The second and third are the function calls
__data_cache(CACHE_FLUSH) and __instruction_cache(CACHE_FLUSH)
respectively, both within the same function and file, that I literally
commented out. Now I can download a file using GDB/Redboot (running from
RAM) but I can't actually execute it.

I'm downloading the file at the address 0x60000 (at RAM) since Redboot is
located at 0x20000 (right?). The entry point should be reset_vector
(right?), which had to be located in the address 0x64000, but is actually
being mapped to 0x60040. Is this a problem?

Anyways my application is loaded and GDB jumps to 0x60040

Loading section .rom_vectors, size 0x40 lma 0x60000
Loading section .text, size 0xf924 lma 0x60040
Loading section .rodata, size 0x4f0 lma 0x6f964
Loading section .data, size 0x4d4 lma 0x6fe54
Start address 0x60040 , load size 66344
Transfer rate: 40827 bits/sec, 302 bytes/write.

and nothing else happens. I have the LEDs being lightned up (in
vectors.S) but it's not working, what makes me assume that the application
is not being executed.

Am I missing something here? 

Thanks,
Cristiano.

------------------------------------------------------------
Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira

> First of all, you can load programs using RedBoot's "load" command as
> well.
> 
> Try turning on GDB's remote debug facility which will display something
> about what's going on on the communications line.  Note: it will be running
> at the same speed that RedBoot was using, most likely 38400 unless you've
> set it up to run otherwise.
> 


^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-20 14:36   ` Cristiano Ligieri Pereira
@ 2001-08-20 14:49     ` Gary Thomas
  2001-08-20 15:10       ` Cristiano Ligieri Pereira
  0 siblings, 1 reply; 25+ messages in thread
From: Gary Thomas @ 2001-08-20 14:49 UTC (permalink / raw)
  To: Cristiano Ligieri Pereira; +Cc: ecos-discuss

On 20-Aug-2001 Cristiano Ligieri Pereira wrote:
> 
> Hi,
> 
> I kind of solved my RAM redboot problem (however temporarily since I only
> removed the cause of the problem from the code instead of fixing it). I
> commented out (till I figure out why) the three function calls that were
> crashing... :-|
> 
> The first is the call to function __clear_breakpoints() whithin the
> function __handle_exception (void), which is located in the file
> generic-stub.c. Actually this one I haven't commented out but only defined
> CYGNUM_HAL_BREAKPOINT_LIST_SIZE to 0, which in turn makes the function do
> not be called. The second and third are the function calls
> __data_cache(CACHE_FLUSH) and __instruction_cache(CACHE_FLUSH)
> respectively, both within the same function and file, that I literally
> commented out. Now I can download a file using GDB/Redboot (running from
> RAM) but I can't actually execute it.
> 
> I'm downloading the file at the address 0x60000 (at RAM) since Redboot is
> located at 0x20000 (right?). The entry point should be reset_vector
> (right?), which had to be located in the address 0x64000, but is actually
> being mapped to 0x60040. Is this a problem?
> 
> Anyways my application is loaded and GDB jumps to 0x60040
> 
> Loading section .rom_vectors, size 0x40 lma 0x60000
> Loading section .text, size 0xf924 lma 0x60040
> Loading section .rodata, size 0x4f0 lma 0x6f964
> Loading section .data, size 0x4d4 lma 0x6fe54
> Start address 0x60040 , load size 66344
> Transfer rate: 40827 bits/sec, 302 bytes/write.
> 
> and nothing else happens. I have the LEDs being lightned up (in
> vectors.S) but it's not working, what makes me assume that the application
> is not being executed.
> 

What kind of a program are you trying to execute?
Have you tried letting RedBoot load the program and then execute it from
RedBoot?

> Am I missing something here? 

> 
> Thanks,
> Cristiano.
> 
> ------------------------------------------------------------
> Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira
> 
>> First of all, you can load programs using RedBoot's "load" command as
>> well.
>> 
>> Try turning on GDB's remote debug facility which will display something
>> about what's going on on the communications line.  Note: it will be running
>> at the same speed that RedBoot was using, most likely 38400 unless you've
>> set it up to run otherwise.
>> 

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-20 14:49     ` Gary Thomas
@ 2001-08-20 15:10       ` Cristiano Ligieri Pereira
  2001-08-20 15:14         ` Gary Thomas
  0 siblings, 1 reply; 25+ messages in thread
From: Cristiano Ligieri Pereira @ 2001-08-20 15:10 UTC (permalink / raw)
  To: Gary Thomas; +Cc: ecos-discuss

> What kind of a program are you trying to execute?
> Have you tried letting RedBoot load the program and then execute it from
> RedBoot?

The simple Hello World example. I've tried the Redboot load command, but
it's timing out. Maybe I'm doing it wrongly. I issue the 'load' command,
then I close the 'kermit' (I'm using kermit to communicate through the
serial) in which I'm interfacing with Redboot, open a new 'kermit' since I
have only one serial port and can't connect two kermit's to the same port
and transmit the file using xmodem. It's timing out.

Thanks,
Cristiano.



^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-20 15:10       ` Cristiano Ligieri Pereira
@ 2001-08-20 15:14         ` Gary Thomas
  2001-08-20 15:34           ` Cristiano Ligieri Pereira
  0 siblings, 1 reply; 25+ messages in thread
From: Gary Thomas @ 2001-08-20 15:14 UTC (permalink / raw)
  To: Cristiano Ligieri Pereira; +Cc: ecos-discuss

On 20-Aug-2001 Cristiano Ligieri Pereira wrote:
> 
>> What kind of a program are you trying to execute?
>> Have you tried letting RedBoot load the program and then execute it from
>> RedBoot?
> 
> The simple Hello World example. I've tried the Redboot load command, but
> it's timing out. Maybe I'm doing it wrongly. I issue the 'load' command,
> then I close the 'kermit' (I'm using kermit to communicate through the
> serial) in which I'm interfacing with Redboot, open a new 'kermit' since I
> have only one serial port and can't connect two kermit's to the same port
> and transmit the file using xmodem. It's timing out.

What's your development platform?  Can you use 'minicom' (we've had no
troubles with it).

What happens if you run 'load' from RedBoot, but _don't_ disconnect?
You should get a series of 'C' characters, each about 3 seconds apart.
If they all come out right off, then you need to look at your implementation
of HAL_DELAY_US().  This is also a common problem for new ports.

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-20 15:14         ` Gary Thomas
@ 2001-08-20 15:34           ` Cristiano Ligieri Pereira
  2001-08-20 15:38             ` Gary Thomas
  0 siblings, 1 reply; 25+ messages in thread
From: Cristiano Ligieri Pereira @ 2001-08-20 15:34 UTC (permalink / raw)
  To: Gary Thomas; +Cc: ecos-discuss

It's Linux. I'll try minicom. 

The 'C' characters come out around 3 seconds apart. The Delay is OK.

Cristiano.

------------------------------------------------------------
Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira

> What's your development platform?  Can you use 'minicom' (we've had no
> troubles with it).
> 
> What happens if you run 'load' from RedBoot, but _don't_ disconnect?
> You should get a series of 'C' characters, each about 3 seconds apart.
> If they all come out right off, then you need to look at your implementation
> of HAL_DELAY_US().  This is also a common problem for new ports.
> 

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-20 15:34           ` Cristiano Ligieri Pereira
@ 2001-08-20 15:38             ` Gary Thomas
  2001-08-20 16:21               ` Cristiano Ligieri Pereira
  0 siblings, 1 reply; 25+ messages in thread
From: Gary Thomas @ 2001-08-20 15:38 UTC (permalink / raw)
  To: Cristiano Ligieri Pereira; +Cc: ecos-discuss

On 20-Aug-2001 Cristiano Ligieri Pereira wrote:
> 
> It's Linux. I'll try minicom. 
> 

Cool.  With 'minicom', just use ^A-S (send) directly from minicom, without
breaking out.  I also turn off the little file selection menu and just
enter the file name directly as RedBoot will most likely timeout before
you can go toodling around the menus and find the file you want to download.

> The 'C' characters come out around 3 seconds apart. The Delay is OK.
> 
> Cristiano.
> 
> ------------------------------------------------------------
> Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira
> 
>> What's your development platform?  Can you use 'minicom' (we've had no
>> troubles with it).
>> 
>> What happens if you run 'load' from RedBoot, but _don't_ disconnect?
>> You should get a series of 'C' characters, each about 3 seconds apart.
>> If they all come out right off, then you need to look at your implementation
>> of HAL_DELAY_US().  This is also a common problem for new ports.
>> 

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-20 15:38             ` Gary Thomas
@ 2001-08-20 16:21               ` Cristiano Ligieri Pereira
  2001-08-20 16:56                 ` Cristiano Ligieri Pereira
  2001-08-20 17:01                 ` Gary Thomas
  0 siblings, 2 replies; 25+ messages in thread
From: Cristiano Ligieri Pereira @ 2001-08-20 16:21 UTC (permalink / raw)
  To: Gary Thomas; +Cc: ecos-discuss

This 'dots' mean that something was being downloaded?

RedBoot> load -r -v -m xmodem -b 0x00060000                                    
CC...........Can't load '': Timed out                                          
RedBoot>                                                                       

Looks like it keeps timing out :-(

Cristiano.

------------------------------------------------------------
Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira

On Mon, 20 Aug 2001, Gary Thomas wrote:

> 
> On 20-Aug-2001 Cristiano Ligieri Pereira wrote:
> > 
> > It's Linux. I'll try minicom. 
> > 
> 
> Cool.  With 'minicom', just use ^A-S (send) directly from minicom, without
> breaking out.  I also turn off the little file selection menu and just
> enter the file name directly as RedBoot will most likely timeout before
> you can go toodling around the menus and find the file you want to download.

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-20 16:21               ` Cristiano Ligieri Pereira
@ 2001-08-20 16:56                 ` Cristiano Ligieri Pereira
  2001-08-20 17:03                   ` Gary Thomas
  2001-08-20 17:04                   ` Gary Thomas
  2001-08-20 17:01                 ` Gary Thomas
  1 sibling, 2 replies; 25+ messages in thread
From: Cristiano Ligieri Pereira @ 2001-08-20 16:56 UTC (permalink / raw)
  To: Gary Thomas; +Cc: ecos-discuss

Which kind of file should I donwload via RedBoot? 
Binary or SREC?

------------------------------------------------------------
Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira

On Mon, 20 Aug 2001, Cristiano Ligieri Pereira wrote:

> 
> This 'dots' mean that something was being downloaded?
> 
> RedBoot> load -r -v -m xmodem -b 0x00060000                                    
> CC...........Can't load '': Timed out                                          
> RedBoot>                                                                       
> 
> Looks like it keeps timing out :-(
> 
> Cristiano.
> 
> ------------------------------------------------------------
> Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira
> 
> On Mon, 20 Aug 2001, Gary Thomas wrote:
> 
> > 
> > On 20-Aug-2001 Cristiano Ligieri Pereira wrote:
> > > 
> > > It's Linux. I'll try minicom. 
> > > 
> > 
> > Cool.  With 'minicom', just use ^A-S (send) directly from minicom, without
> > breaking out.  I also turn off the little file selection menu and just
> > enter the file name directly as RedBoot will most likely timeout before
> > you can go toodling around the menus and find the file you want to download.
> 
> 


^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-20 16:21               ` Cristiano Ligieri Pereira
  2001-08-20 16:56                 ` Cristiano Ligieri Pereira
@ 2001-08-20 17:01                 ` Gary Thomas
  1 sibling, 0 replies; 25+ messages in thread
From: Gary Thomas @ 2001-08-20 17:01 UTC (permalink / raw)
  To: Cristiano Ligieri Pereira; +Cc: ecos-discuss

On 20-Aug-2001 Cristiano Ligieri Pereira wrote:
> 
> This 'dots' mean that something was being downloaded?
> 
> RedBoot> load -r -v -m xmodem -b 0x00060000                                    
> CC...........Can't load '': Timed out                                          
> RedBoot>                                                                       
> 
> Looks like it keeps timing out :-(

What had you done after the 'CC' but before the '....'?  You should
have instructed minicom to "send" the file at that point and it should
tell you something about what's going on.

I just tried this (without actually sending anything) and I saw:
   RedBoot> load -m xm -v
   CCCCCCCCC...........Can't load '': Timed out
The whole thing took about a minute.  The 'C' characters come out every
3-4 seconds.  These characters are RedBoot telling minicom (X-modem) to
send packets with a CRC style checksum. If nothing shows up after 10
tries, it backs off to using simple Xor checksums (the '.') character.

Bottom line: RedBoot is not seeing anything come from minicom.  When
you are typing, you should be entering something like:
  load -r -x xm -b 0x600000^M^As
where '^M' is enter/return, '^As' is Control-A followed by 's' which
tells minicom to start sending the file.  It's not automatic, you
have to start the transfer manually.


> 
> Cristiano.
> 
> ------------------------------------------------------------
> Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira
> 
> On Mon, 20 Aug 2001, Gary Thomas wrote:
> 
>> 
>> On 20-Aug-2001 Cristiano Ligieri Pereira wrote:
>> > 
>> > It's Linux. I'll try minicom. 
>> > 
>> 
>> Cool.  With 'minicom', just use ^A-S (send) directly from minicom, without
>> breaking out.  I also turn off the little file selection menu and just
>> enter the file name directly as RedBoot will most likely timeout before
>> you can go toodling around the menus and find the file you want to download.

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-20 16:56                 ` Cristiano Ligieri Pereira
@ 2001-08-20 17:03                   ` Gary Thomas
  2001-08-20 17:14                     ` Cristiano Ligieri Pereira
  2001-08-20 17:04                   ` Gary Thomas
  1 sibling, 1 reply; 25+ messages in thread
From: Gary Thomas @ 2001-08-20 17:03 UTC (permalink / raw)
  To: Cristiano Ligieri Pereira; +Cc: ecos-discuss

On 20-Aug-2001 Cristiano Ligieri Pereira wrote:
> 
> Which kind of file should I donwload via RedBoot? 
> Binary or SREC?

Either.  Your example implies binary, but I'm not so sure about
it anyway.  If this is the "Hello world" example we talked about
last week, shouldn't you be downloading it at 0x20000?

Note: if you use S-records, you shouldn't need to specify a load
address or an entry point when you use the 'go' command.

> 
> ------------------------------------------------------------
> Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira
> 
> On Mon, 20 Aug 2001, Cristiano Ligieri Pereira wrote:
> 
>> 
>> This 'dots' mean that something was being downloaded?
>> 
>> RedBoot> load -r -v -m xmodem -b 0x00060000                                    
>> CC...........Can't load '': Timed out                                          
>> RedBoot>                                                                       
>> 
>> Looks like it keeps timing out :-(
>> 
>> Cristiano.
>> 
>> ------------------------------------------------------------
>> Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira
>> 
>> On Mon, 20 Aug 2001, Gary Thomas wrote:
>> 
>> > 
>> > On 20-Aug-2001 Cristiano Ligieri Pereira wrote:
>> > > 
>> > > It's Linux. I'll try minicom. 
>> > > 
>> > 
>> > Cool.  With 'minicom', just use ^A-S (send) directly from minicom, without
>> > breaking out.  I also turn off the little file selection menu and just
>> > enter the file name directly as RedBoot will most likely timeout before
>> > you can go toodling around the menus and find the file you want to download.
>> 
>> 

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-20 16:56                 ` Cristiano Ligieri Pereira
  2001-08-20 17:03                   ` Gary Thomas
@ 2001-08-20 17:04                   ` Gary Thomas
  1 sibling, 0 replies; 25+ messages in thread
From: Gary Thomas @ 2001-08-20 17:04 UTC (permalink / raw)
  To: Cristiano Ligieri Pereira; +Cc: ecos-discuss

On 20-Aug-2001 Cristiano Ligieri Pereira wrote:
> 
> Which kind of file should I donwload via RedBoot? 
> Binary or SREC?
> 

Like I mentioned, either mode can be used, but if you don't specify
the '-r' flag to the 'load' command, you *must* use S-records.  Only
use the '-r' flag if the data is raw binary, i.e. not formatted in
any way.

> ------------------------------------------------------------
> Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira
> 
> On Mon, 20 Aug 2001, Cristiano Ligieri Pereira wrote:
> 
>> 
>> This 'dots' mean that something was being downloaded?
>> 
>> RedBoot> load -r -v -m xmodem -b 0x00060000                                    
>> CC...........Can't load '': Timed out                                          
>> RedBoot>                                                                       
>> 
>> Looks like it keeps timing out :-(
>> 
>> Cristiano.
>> 
>> ------------------------------------------------------------
>> Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira
>> 
>> On Mon, 20 Aug 2001, Gary Thomas wrote:
>> 
>> > 
>> > On 20-Aug-2001 Cristiano Ligieri Pereira wrote:
>> > > 
>> > > It's Linux. I'll try minicom. 
>> > > 
>> > 
>> > Cool.  With 'minicom', just use ^A-S (send) directly from minicom, without
>> > breaking out.  I also turn off the little file selection menu and just
>> > enter the file name directly as RedBoot will most likely timeout before
>> > you can go toodling around the menus and find the file you want to download.
>> 
>> 

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-20 17:03                   ` Gary Thomas
@ 2001-08-20 17:14                     ` Cristiano Ligieri Pereira
  2001-08-20 18:05                       ` Gary Thomas
  0 siblings, 1 reply; 25+ messages in thread
From: Cristiano Ligieri Pereira @ 2001-08-20 17:14 UTC (permalink / raw)
  To: Gary Thomas; +Cc: ecos-discuss

> Either.  Your example implies binary, but I'm not so sure about
> it anyway.  If this is the "Hello world" example we talked about
> last week, shouldn't you be downloading it at 0x20000?

0x20000 is where RedBoot is running. So I'm assuming I have to put the
application somewhere else and thus I'm compiling it accordingly.

Cristiano.

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-20 17:14                     ` Cristiano Ligieri Pereira
@ 2001-08-20 18:05                       ` Gary Thomas
  2001-08-20 18:25                         ` Cristiano Ligieri Pereira
  0 siblings, 1 reply; 25+ messages in thread
From: Gary Thomas @ 2001-08-20 18:05 UTC (permalink / raw)
  To: Cristiano Ligieri Pereira; +Cc: ecos-discuss

On 21-Aug-2001 Cristiano Ligieri Pereira wrote:
> 
>> Either.  Your example implies binary, but I'm not so sure about
>> it anyway.  If this is the "Hello world" example we talked about
>> last week, shouldn't you be downloading it at 0x20000?
> 
> 0x20000 is where RedBoot is running. So I'm assuming I have to put the
> application somewhere else and thus I'm compiling it accordingly.

You don't have RedBoot running from ROM/FLASH?

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-20 18:05                       ` Gary Thomas
@ 2001-08-20 18:25                         ` Cristiano Ligieri Pereira
  2001-08-20 19:32                           ` Gary Thomas
  0 siblings, 1 reply; 25+ messages in thread
From: Cristiano Ligieri Pereira @ 2001-08-20 18:25 UTC (permalink / raw)
  To: Gary Thomas; +Cc: ecos-discuss

No. I made it run from RAM only. Then I'm loading RedBoot using Cygmon and
trying to download an eCos application using Redboot. Isn't it a good
approach? I actually do it running eCos on the ipaq...

Cristiano.

------------------------------------------------------------
Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira

On Mon, 20 Aug 2001, Gary Thomas wrote:

> 
> On 21-Aug-2001 Cristiano Ligieri Pereira wrote:
> > 
> >> Either.  Your example implies binary, but I'm not so sure about
> >> it anyway.  If this is the "Hello world" example we talked about
> >> last week, shouldn't you be downloading it at 0x20000?
> > 
> > 0x20000 is where RedBoot is running. So I'm assuming I have to put the
> > application somewhere else and thus I'm compiling it accordingly.
> 
> You don't have RedBoot running from ROM/FLASH?
> 

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-20 18:25                         ` Cristiano Ligieri Pereira
@ 2001-08-20 19:32                           ` Gary Thomas
  2001-08-21 14:00                             ` Cristiano Ligieri Pereira
  0 siblings, 1 reply; 25+ messages in thread
From: Gary Thomas @ 2001-08-20 19:32 UTC (permalink / raw)
  To: Cristiano Ligieri Pereira; +Cc: ecos-discuss

On 21-Aug-2001 Cristiano Ligieri Pereira wrote:
> 
> No. I made it run from RAM only. Then I'm loading RedBoot using Cygmon and
> trying to download an eCos application using Redboot. Isn't it a good
> approach? I actually do it running eCos on the ipaq...
> 

Well, RedBoot can more than replace Cygmon [plus it's what we're
supporting now]  Perhaps some of your other problems would go away
if you were running in that mode.

That has nothing to do with the X-modem download problems you are
experiencing though.

> Cristiano.
> 
> ------------------------------------------------------------
> Cristiano Ligieri Pereira - http://www.ics.uci.edu/~cpereira
> 
> On Mon, 20 Aug 2001, Gary Thomas wrote:
> 
>> 
>> On 21-Aug-2001 Cristiano Ligieri Pereira wrote:
>> > 
>> >> Either.  Your example implies binary, but I'm not so sure about
>> >> it anyway.  If this is the "Hello world" example we talked about
>> >> last week, shouldn't you be downloading it at 0x20000?
>> > 
>> > 0x20000 is where RedBoot is running. So I'm assuming I have to put the
>> > application somewhere else and thus I'm compiling it accordingly.
>> 
>> You don't have RedBoot running from ROM/FLASH?
>> 

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-20 19:32                           ` Gary Thomas
@ 2001-08-21 14:00                             ` Cristiano Ligieri Pereira
  2001-08-21 14:12                               ` Gary Thomas
  0 siblings, 1 reply; 25+ messages in thread
From: Cristiano Ligieri Pereira @ 2001-08-21 14:00 UTC (permalink / raw)
  To: Gary Thomas; +Cc: ecos-discuss

> That has nothing to do with the X-modem download problems you are
> experiencing though.
> 
> > Cristiano.

Now I have some communication but with errors:

Minicom console:

"Retry 0: Got 31 for sector ACK                            
 Retry 0: NAK on sector
 Retry 0: Got 31 for sector ACK"

Redboot console:

"load -v -m xm                                                         
C                                                                          
Cailure - Addr: 60015, 92 <> 00                                                
xyzModem - CRC mode, 9(SOH)/0(STX)/1(CAN) packets, 13 retries"

If I dump memory address 0x60000 I see that part (the beggining of the
file was downloaded):

RedBoot> dump -b 0x60000 -l 0x100                                              
0x00060000: 18F0 9FE5 18F0 9FE5  18F0 9FE5 18F0 9FE5   |................|      
0x00060010: 18F0 9FE5 0000 0000  18F0 9FE5 18F0 9FE5   |................|      
0x00060020: 4000 0600 FFFF FFFF  FFFF 0000 0000 0000   |@...............|      
0x00060030: 0000 0000 0000 0000  0000 0000 0000 0000   |................|      
0x00060040: 0000 0000 0000 0000  0000 0000 0000 0000   |................|      
0x00060050: 0000 0000 0000 0000  0000 0000 0000 0000   |................|      
0x00060060: 0000 0000 0000 0000  0000 0000 0000 0000   |................|      

Is this purely communication error or has something to do with the SREC
file? If I try the binary file I get no message at all.

Thanks,
Cristiano.

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-21 14:00                             ` Cristiano Ligieri Pereira
@ 2001-08-21 14:12                               ` Gary Thomas
  2001-08-21 14:31                                 ` Cristiano Ligieri Pereira
  0 siblings, 1 reply; 25+ messages in thread
From: Gary Thomas @ 2001-08-21 14:12 UTC (permalink / raw)
  To: Cristiano Ligieri Pereira; +Cc: ecos-discuss

On 21-Aug-2001 Cristiano Ligieri Pereira wrote:
> 
>> That has nothing to do with the X-modem download problems you are
>> experiencing though.
>> 
>> > Cristiano.
> 
> Now I have some communication but with errors:
> 
> Minicom console:
> 
> "Retry 0: Got 31 for sector ACK                            
>  Retry 0: NAK on sector
>  Retry 0: Got 31 for sector ACK"
> 
> Redboot console:
> 
> "load -v -m xm                                                         
> C                                                                          
> Cailure - Addr: 60015, 92 <> 00                                                
> xyzModem - CRC mode, 9(SOH)/0(STX)/1(CAN) packets, 13 retries"
> 
> If I dump memory address 0x60000 I see that part (the beggining of the
> file was downloaded):
> 
> RedBoot> dump -b 0x60000 -l 0x100                                              
> 0x00060000: 18F0 9FE5 18F0 9FE5  18F0 9FE5 18F0 9FE5   |................|      
> 0x00060010: 18F0 9FE5 0000 0000  18F0 9FE5 18F0 9FE5   |................|      
> 0x00060020: 4000 0600 FFFF FFFF  FFFF 0000 0000 0000   |@...............|      
> 0x00060030: 0000 0000 0000 0000  0000 0000 0000 0000   |................|      
> 0x00060040: 0000 0000 0000 0000  0000 0000 0000 0000   |................|      
> 0x00060050: 0000 0000 0000 0000  0000 0000 0000 0000   |................|      
> 0x00060060: 0000 0000 0000 0000  0000 0000 0000 0000   |................|      
> 
> Is this purely communication error or has something to do with the SREC
> file? If I try the binary file I get no message at all.

The binary download won't print any messages.  S-record does some
verification and thus does print things.

First of all, try leaving the "-v" option off.  It will only get in
the way (most recent sources disable it for X-modem).

Then, try loading to some different address - try a much higer one like
0x100000.

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-21 14:12                               ` Gary Thomas
@ 2001-08-21 14:31                                 ` Cristiano Ligieri Pereira
  2001-08-21 14:58                                   ` Gary Thomas
  2001-08-21 16:04                                   ` Jonathan Larmour
  0 siblings, 2 replies; 25+ messages in thread
From: Cristiano Ligieri Pereira @ 2001-08-21 14:31 UTC (permalink / raw)
  To: Gary Thomas; +Cc: ecos-discuss

> The binary download won't print any messages.  S-record does some
> verification and thus does print things.
> 
> First of all, try leaving the "-v" option off.  It will only get in
> the way (most recent sources disable it for X-modem).
> 
> Then, try loading to some different address - try a much higer one like
> 0x100000.

RedBoot> load -v -m xmodem                                                     
..Entry point: 0x00060040, address range: 0x00060000-0x00070328                
xyzModem - CRC mode, 1386(SOH)/0(STX)/0(CAN) packets, 4 retries       

RedBoot> dump -b 0x60000 -l 0x100                                              
0x00060000: 18F0 9FE5 18F0 9FE5  18F0 9FE5 18F0 9FE5   |................|      
0x00060010: 18F0 9FE5 0000 0000  18F0 9FE5 18F0 9FE5   |................|      
0x00060020: 4000 0600 8801 0600  F001 0600 2802 0600   |@...........(...|      
0x00060030: 8802 0600 0000 0000  7403 0600 3C03 0600   |........t...<...|      
0x00060040: 2106 A0E3 4010 A0E3  0010 80E5 0070 0FE1   |!...@........p..|      
0x00060050: 1F70 07E2 1300 57E3  0700 000A 0000 A0E3   |.p....W.........|      
0x00060060: 1015 9FE5 0420 91E5  0420 80E5 2420 91E5   |..... ... ..$ ..|      

...

I found out what was wrong (I put some stupid printf's where i shouldn't
yesterday late night... ). It working fine now. So after downloading the
file I should just type 'go' to the entry point address and it should
work, right?

That's not happening... :-| (as usual nothing works at the first time...)

Cristiano.

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-21 14:31                                 ` Cristiano Ligieri Pereira
@ 2001-08-21 14:58                                   ` Gary Thomas
  2001-08-21 20:13                                     ` Cristiano Ligieri Pereira
  2001-08-21 16:04                                   ` Jonathan Larmour
  1 sibling, 1 reply; 25+ messages in thread
From: Gary Thomas @ 2001-08-21 14:58 UTC (permalink / raw)
  To: Cristiano Ligieri Pereira; +Cc: ecos-discuss

On 21-Aug-2001 Cristiano Ligieri Pereira wrote:
> 
>> The binary download won't print any messages.  S-record does some
>> verification and thus does print things.
>> 
>> First of all, try leaving the "-v" option off.  It will only get in
>> the way (most recent sources disable it for X-modem).
>> 
>> Then, try loading to some different address - try a much higer one like
>> 0x100000.
> 
> RedBoot> load -v -m xmodem                                                     
> ..Entry point: 0x00060040, address range: 0x00060000-0x00070328                
> xyzModem - CRC mode, 1386(SOH)/0(STX)/0(CAN) packets, 4 retries       
> 
> RedBoot> dump -b 0x60000 -l 0x100                                              
> 0x00060000: 18F0 9FE5 18F0 9FE5  18F0 9FE5 18F0 9FE5   |................|      
> 0x00060010: 18F0 9FE5 0000 0000  18F0 9FE5 18F0 9FE5   |................|      
> 0x00060020: 4000 0600 8801 0600  F001 0600 2802 0600   |@...........(...|      
> 0x00060030: 8802 0600 0000 0000  7403 0600 3C03 0600   |........t...<...|      
> 0x00060040: 2106 A0E3 4010 A0E3  0010 80E5 0070 0FE1   |!...@........p..|      
> 0x00060050: 1F70 07E2 1300 57E3  0700 000A 0000 A0E3   |.p....W.........|      
> 0x00060060: 1015 9FE5 0420 91E5  0420 80E5 2420 91E5   |..... ... ..$ ..|      
> 
> ...
> 
> I found out what was wrong (I put some stupid printf's where i shouldn't
> yesterday late night... ). It working fine now. So after downloading the
> file I should just type 'go' to the entry point address and it should
> work, right?
> 
> That's not happening... :-| (as usual nothing works at the first time...)

Try stepping through the code.  Time to learn to use GDB :-)

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [ECOS] Port to XScale board
  2001-08-21 14:31                                 ` Cristiano Ligieri Pereira
  2001-08-21 14:58                                   ` Gary Thomas
@ 2001-08-21 16:04                                   ` Jonathan Larmour
  1 sibling, 0 replies; 25+ messages in thread
From: Jonathan Larmour @ 2001-08-21 16:04 UTC (permalink / raw)
  To: Cristiano Ligieri Pereira; +Cc: Gary Thomas, ecos-discuss

Cristiano Ligieri Pereira wrote:
> I found out what was wrong (I put some stupid printf's where i shouldn't
> yesterday late night... ). It working fine now. So after downloading the
> file I should just type 'go' to the entry point address and it should
> work, right?

You have to build it to run at the address you've loaded it at surely.

Jifl
-- 
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
Maybe this world is another planet's Hell -Aldous Huxley || Opinions==mine

^ permalink raw reply	[flat|nested] 25+ messages in thread

* RE: [ECOS] Port to XScale board
  2001-08-21 14:58                                   ` Gary Thomas
@ 2001-08-21 20:13                                     ` Cristiano Ligieri Pereira
  0 siblings, 0 replies; 25+ messages in thread
From: Cristiano Ligieri Pereira @ 2001-08-21 20:13 UTC (permalink / raw)
  To: Gary Thomas; +Cc: ecos-discuss

> Try stepping through the code.  Time to learn to use GDB :-)

At last it's working fine now. Well, at least I can execute the simple
Hello World application from Redboot.

That problem was on the macros ICACHE_INVALIDATE_ALL() and
DCACHE_INVALIDATED_ALL() that are not working properly and that are called
right before Redboot transfers the execution control to the application.

Now I guess that the next step is to clean up all the unnecessary code and
fix the non-working ones to generate a ROM version of RedBoot.

Cristiano.


^ permalink raw reply	[flat|nested] 25+ messages in thread

end of thread, other threads:[~2001-08-21 20:13 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-08-18 16:21 [ECOS] Port to XScale board Cristiano Ligieri Pereira
2001-08-18 18:46 ` Gary Thomas
2001-08-19 15:29   ` Cristiano Ligieri Pereira
2001-08-19 15:52   ` Cristiano Ligieri Pereira
2001-08-20 14:36   ` Cristiano Ligieri Pereira
2001-08-20 14:49     ` Gary Thomas
2001-08-20 15:10       ` Cristiano Ligieri Pereira
2001-08-20 15:14         ` Gary Thomas
2001-08-20 15:34           ` Cristiano Ligieri Pereira
2001-08-20 15:38             ` Gary Thomas
2001-08-20 16:21               ` Cristiano Ligieri Pereira
2001-08-20 16:56                 ` Cristiano Ligieri Pereira
2001-08-20 17:03                   ` Gary Thomas
2001-08-20 17:14                     ` Cristiano Ligieri Pereira
2001-08-20 18:05                       ` Gary Thomas
2001-08-20 18:25                         ` Cristiano Ligieri Pereira
2001-08-20 19:32                           ` Gary Thomas
2001-08-21 14:00                             ` Cristiano Ligieri Pereira
2001-08-21 14:12                               ` Gary Thomas
2001-08-21 14:31                                 ` Cristiano Ligieri Pereira
2001-08-21 14:58                                   ` Gary Thomas
2001-08-21 20:13                                     ` Cristiano Ligieri Pereira
2001-08-21 16:04                                   ` Jonathan Larmour
2001-08-20 17:04                   ` Gary Thomas
2001-08-20 17:01                 ` Gary Thomas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).