public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] i386 target crashes after download
@ 2001-01-18  9:40 Jochen Hagemann
  2001-01-18 13:51 ` Jonathan Larmour
  0 siblings, 1 reply; 7+ messages in thread
From: Jochen Hagemann @ 2001-01-18  9:40 UTC (permalink / raw)
  To: ecos-discuss

I am trying to run ECOS on an i386 target, a PC-104 board.
The Kernel and the gdb-stubs seem to be ok. The target boots from a floppy disk
and I am able to connect to it with Insight 5 and download test applications.
While loading, lots of those "mysterious" characters appear on the screen, fine !
Until here everything works as desired.
But right after downloading, the screen shows wild flickering, then the target reboots.
There are no messages in the gdb console except download progress.
Setting breakpoints anywhere in the code doesen't help, it seems that they are never reached.

My PC-104 board has a 66 MHz STPC-CPU, 16 MB Ram and a Phoenix Bios from 07/19/00
I already checked if parts of the stubs are overwritten during download, i386-elf-objdump says:

gdb_module.img:  file format elf32-i386
Disassembly of section .text:
00001000 <_start>: ...

<any test application>:  file format elf32-i386
Disassembly of section .text:
00010000 <_start>: ...

This should be ok.

Does anybody know what's going wrong here ? I even tried:

int main(void){
  return 0;
}

without success...Jochen Hagemann

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

* Re: [ECOS] i386 target crashes after download
  2001-01-18  9:40 [ECOS] i386 target crashes after download Jochen Hagemann
@ 2001-01-18 13:51 ` Jonathan Larmour
  2001-01-19  1:41   ` Jochen Hagemann
       [not found]   ` <5.0.2.1.0.20010119105711.00a90510@imap.ee.ethz.ch>
  0 siblings, 2 replies; 7+ messages in thread
From: Jonathan Larmour @ 2001-01-18 13:51 UTC (permalink / raw)
  To: Jochen Hagemann; +Cc: ecos-discuss

Jochen Hagemann wrote:
> 
> I am trying to run ECOS on an i386 target, a PC-104 board.
> The Kernel and the gdb-stubs seem to be ok. The target boots from a floppy disk
> and I am able to connect to it with Insight 5 and download test applications.
> While loading, lots of those "mysterious" characters appear on the screen, fine !
> Until here everything works as desired.
> But right after downloading, the screen shows wild flickering, then the target reboots.

Wild flickering? You mean extra characters output, or does it just go
weird? If the latter it may be a hardware problem - are you sure the
hardware is known good?

Jifl
-- 
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
Un cheval, pas du glue. Pas du cheval, beaucoup du glue. || Opinions==mine

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

* Re: [ECOS] i386 target crashes after download
  2001-01-18 13:51 ` Jonathan Larmour
@ 2001-01-19  1:41   ` Jochen Hagemann
  2001-01-19  2:03     ` Christian Plessl
       [not found]   ` <5.0.2.1.0.20010119105711.00a90510@imap.ee.ethz.ch>
  1 sibling, 1 reply; 7+ messages in thread
From: Jochen Hagemann @ 2001-01-19  1:41 UTC (permalink / raw)
  To: Jonathan Larmour; +Cc: ecos-discuss

Jonathan Larmour wrote:
> 
> Wild flickering? You mean extra characters output, or does it just go
> weird? 
It goes weird, but see below...

> If the latter it may be a hardware problem - are you sure the
> hardware is known good?

The PC-104 hardware works, i.e. I can run another OS from floppy without problems.
This morning, I tried out an ordinary desktop PC. The result is not much better,
it still reboots right after downloading, except that the screen doesen't go weird.

Maybe I forgot to say that I checked the Item "Run Program" in addition to 
"Attach to Target" and "Download Program" in the Target Selection Dialog.

Regards Jochen

-- 
Jochen Hagemann
GenoLogic GmbH
Emil-Figge-Str. 80
D-44227 Dortmund

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

* Re: [ECOS] i386 target crashes after download
  2001-01-19  1:41   ` Jochen Hagemann
@ 2001-01-19  2:03     ` Christian Plessl
  0 siblings, 0 replies; 7+ messages in thread
From: Christian Plessl @ 2001-01-19  2:03 UTC (permalink / raw)
  To: ecos-discuss; +Cc: ecos-discuss

At 09:35 19.01.01 +0100, Jochen Hagemann wrote:
>Jonathan Larmour wrote:
> >
> > Wild flickering? You mean extra characters output, or does it just go
> > weird?
>It goes weird, but see below...
>
> > If the latter it may be a hardware problem - are you sure the
> > hardware is known good?
>
>The PC-104 hardware works, i.e. I can run another OS from floppy without 
>problems.
>This morning, I tried out an ordinary desktop PC. The result is not much 
>better,
>it still reboots right after downloading, except that the screen doesen't 
>go weird.
>
>Maybe I forgot to say that I checked the Item "Run Program" in addition to
>"Attach to Target" and "Download Program" in the Target Selection Dialog.
>
>Regards Jochen
>
>--
>Jochen Hagemann
>GenoLogic GmbH
>Emil-Figge-Str. 80
>D-44227 Dortmund

--
Christian Plessl, Loorenstr. 20d, CH-5443 Niederrohrdorf
Tel, Fax: 056 496 41 73 email: cplessl@ee.ethz.ch


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

* Re: [ECOS] i386 target crashes after download
       [not found]   ` <5.0.2.1.0.20010119105711.00a90510@imap.ee.ethz.ch>
@ 2001-01-19  7:40     ` Jochen Hagemann
  2001-01-19  8:25       ` Christian Plessl
  0 siblings, 1 reply; 7+ messages in thread
From: Jochen Hagemann @ 2001-01-19  7:40 UTC (permalink / raw)
  To: Christian Plessl; +Cc: ecos-discuss

Christian Plessl wrote:
> Just to make this sure.
> 
> How did you link your executable? Did you make 2 seperate ecos trees, one
> for building the ecos loader with gdb-stubs and another tree for building
> the ecos library which is linked with your application
> 
> ecosconfig new pc stubs
> ecosconfig tree
> make
> 
> --> this gives you the loader
> 
> than, in a different directory
> 
> ecosconfig new pc     (note! no stubs here)
> ecosconfig tree
> make
> 
> this gives you the library to link your application with
> 
> Chris

Hi Chris,
I built the gdb-stubs and the library in different directories.
But perhaps I made another mistake. Here is a detailed description
of what I did:

I built the loader with the following script in a directory named "stub"
--
export ECOS_REPOSITORY=/opt/ecos/ecos-1.3.1/packages
export PATH=/tools/H-i686-pc-linux-gnu/bin:$PATH
ECOS_TOOLS=/opt/ecos-1.3.1/tools/bin
$ECOS_TOOLS/ecosconfig new pc stubs
$ECOS_TOOLS/ecosconfig check
$ECOS_TOOLS/ecosconfig tree
make
--
...and got those messages:

7 conflict(s) resolved:
CYGBLD_BUILD_GDB_STUBS:
  Requires constraint not satisfied:  CYG_HAL_STARTUP == "FLOPPY"  
CYGSEM_HAL_ROM_MONITOR:
  Requires constraint not satisfied: !CYGDBG_HAL_DEBUG_GDB_CTRLC_SUPPORT  
CYGBLD_BUILD_GDB_STUBS:
  Requires constraint not satisfied: CYGSEM_HAL_ROM_MONITOR
CYGBLD_BUILD_COMMON_GDB_STUBS:   
  Requires constraint not satisfied: CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS
CYGBLD_BUILD_GDB_STUBS:
  Requires constraint not satisfied: CYGBLD_BUILD_COMMON_GDB_STUBS
CYGBLD_BUILD_GDB_STUBS:
  Requires constraint not satisfied: ! CYGDBG_HAL_COMMON_INTERRUPTS_SAVE_MINIMUM_CONTEXT 
CYGBLD_BUILD_GDB_STUBS:
  Requires constraint not satisfied: ! CYGDBG_HAL_COMMON_CONTEXT_SAVE_MINIMUM
Target: pc
Template: stubs 
No conflicts
...
(finally :-) build finished\x19

To create the boot disk, I typed:
dd conv=sync if=install/bin/gdb_module.bin of=/dev/fd0


When I built the library in a different directory named "target" with
--
export ECOS_REPOSITORY=/opt/ecos/ecos-1.3.1/packages
export PATH=/tools/H-i686-pc-linux-gnu/bin:$PATH
ECOS_TOOLS=/opt/ecos-1.3.1/tools/bin
$ECOS_TOOLS/ecosconfig new pc
$ECOS_TOOLS/ecosconfig check
$ECOS_TOOLS/ecosconfig tree
make
--
...I got those messages:

1 conflict(s) resolved:
CYGSEM_HAL_I386_PC_STARTUP_RAM:
  Requires constraint not satisfied: !CYGIMP_HAL_COMMON_INTERRUPTS_USE_INTERRUPT
Target: pc
Template: default
2 conflict(s):
CYGSEM_HAL_I386_PC_STARTUP_RAM:
  Requires constraint not satisfied: CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS
CYGSEM_HAL_I386_PC_STARTUP_RAM:
  Requires constraint not satisfied: CYGDBG_HAL_DEBUG_GDB_BREAK_SUPPORT
5 conflict(s) resolved:
CYGSEM_HAL_I386_PC_STARTUP_RAM:
  Requires constraint not satisfied: CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS
CYGDBG_HAL_DEBUG_GDB_CTRLC_SUPPORT:
  Requires constraint not satisfied: !CYGDBG_HAL_DEBUG_GDB_BREAK_SUPPORT
CYGSEM_HAL_I386_PC_STARTUP_RAM:
  Requires constraint not satisfied: CYGDBG_HAL_DEBUG_GDB_BREAK_SUPPORT
CYGDBG_HAL_DEBUG_GDB_CTRLC_SUPPORT:
  Requires constraint not satisfied: !CYGDBG_HAL_DEBUG_GDB_BREAK_SUPPORT
CYGSEM_HAL_I386_PC_STARTUP_RAM:
  Requires constraint not satisfied: CYGDBG_HAL_DEBUG_GDB_BREAK_SUPPORT   
...
(finally :-) build finished\x19
I could get rid of the conflicts by editing the ecos.ecc file.


My Makefile for the simplest program you can imagine looks like this:
--
PATH	:= /tools/H-i686-pc-linux-gnu/bin:$(PATH)
CC       = i386-elf-gcc
CXX	 = i386-elf-g++
INCLUDE  = -I ../target/install/include
LIB      = -L ../target/install/lib
CFLAGS = $(INCLUDE) -g -O2 -fno-rtti -fno-exceptions -ffunction-sections \
         -fdata-sections -fvtable-gc -finit-priority
LDFLAGS  = $(LIB) -g -Ttarget.ld -nostdlib

hello:	hello.o
--

Any ideas ?
-- 
Jochen Hagemann
GenoLogic GmbH
Emil-Figge-Str. 80
D-44227 Dortmund

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

* Re: [ECOS] i386 target crashes after download
  2001-01-19  7:40     ` Jochen Hagemann
@ 2001-01-19  8:25       ` Christian Plessl
  0 siblings, 0 replies; 7+ messages in thread
From: Christian Plessl @ 2001-01-19  8:25 UTC (permalink / raw)
  To: Jochen Hagemann; +Cc: ecos-discuss

>
>I built the loader with the following script in a directory named "stub"
>--
>export ECOS_REPOSITORY=/opt/ecos/ecos-1.3.1/packages
>export PATH=/tools/H-i686-pc-linux-gnu/bin:$PATH
>ECOS_TOOLS=/opt/ecos-1.3.1/tools/bin
>$ECOS_TOOLS/ecosconfig new pc stubs
>$ECOS_TOOLS/ecosconfig check
>$ECOS_TOOLS/ecosconfig tree
>make
>--
>...and got those messages:
>
>7 conflict(s) resolved:
>CYGBLD_BUILD_GDB_STUBS:
>   Requires constraint not satisfied:  CYG_HAL_STARTUP == "FLOPPY"
>CYGSEM_HAL_ROM_MONITOR:
>   Requires constraint not satisfied: !CYGDBG_HAL_DEBUG_GDB_CTRLC_SUPPORT
>CYGBLD_BUILD_GDB_STUBS:
>   Requires constraint not satisfied: CYGSEM_HAL_ROM_MONITOR
>CYGBLD_BUILD_COMMON_GDB_STUBS:
>   Requires constraint not satisfied: CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS
>CYGBLD_BUILD_GDB_STUBS:
>   Requires constraint not satisfied: CYGBLD_BUILD_COMMON_GDB_STUBS
>CYGBLD_BUILD_GDB_STUBS:
>   Requires constraint not satisfied: ! 
> CYGDBG_HAL_COMMON_INTERRUPTS_SAVE_MINIMUM_CONTEXT
>CYGBLD_BUILD_GDB_STUBS:
>   Requires constraint not satisfied: ! CYGDBG_HAL_COMMON_CONTEXT_SAVE_MINIMUM
>Target: pc
>Template: stubs
>No conflicts
>...
>(finally :-) build finished

Ok,this looks reasonable.



>When I built the library in a different directory named "target" with
>--
>export ECOS_REPOSITORY=/opt/ecos/ecos-1.3.1/packages
>export PATH=/tools/H-i686-pc-linux-gnu/bin:$PATH
>ECOS_TOOLS=/opt/ecos-1.3.1/tools/bin
>$ECOS_TOOLS/ecosconfig new pc
>$ECOS_TOOLS/ecosconfig check
>$ECOS_TOOLS/ecosconfig tree
>make
>--
>...I got those messages:
>
>1 conflict(s) resolved:
>CYGSEM_HAL_I386_PC_STARTUP_RAM:
>   Requires constraint not satisfied: 
> !CYGIMP_HAL_COMMON_INTERRUPTS_USE_INTERRUPT
>Target: pc
>Template: default
>2 conflict(s):
>CYGSEM_HAL_I386_PC_STARTUP_RAM:
>   Requires constraint not satisfied: CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS
>CYGSEM_HAL_I386_PC_STARTUP_RAM:
>   Requires constraint not satisfied: CYGDBG_HAL_DEBUG_GDB_BREAK_SUPPORT
>5 conflict(s) resolved:
>CYGSEM_HAL_I386_PC_STARTUP_RAM:
>   Requires constraint not satisfied: CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS
>CYGDBG_HAL_DEBUG_GDB_CTRLC_SUPPORT:
>   Requires constraint not satisfied: !CYGDBG_HAL_DEBUG_GDB_BREAK_SUPPORT
>CYGSEM_HAL_I386_PC_STARTUP_RAM:
>   Requires constraint not satisfied: CYGDBG_HAL_DEBUG_GDB_BREAK_SUPPORT
>CYGDBG_HAL_DEBUG_GDB_CTRLC_SUPPORT:
>   Requires constraint not satisfied: !CYGDBG_HAL_DEBUG_GDB_BREAK_SUPPORT
>CYGSEM_HAL_I386_PC_STARTUP_RAM:
>   Requires constraint not satisfied: CYGDBG_HAL_DEBUG_GDB_BREAK_SUPPORT
>...
>(finally :-) build finished
>I could get rid of the conflicts by editing the ecos.ecc file.

This is strange, I do not have any conflicts that need to be resolved by 
hand.. What version of ecos you are using? The latest CVS snapshot? Your 
install path of ecos looks like you are using ecos-1.3.1 release, are you?

My experience was, that upgrading, to the latest cvs version solves a lot 
of problems..

Cheers,
Chris



--
Christian Plessl <cplessl@ee.ethz.ch>

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

* Re: [ECOS] i386 target crashes after download
@ 2001-01-19  3:18 Christian Plessl
  0 siblings, 0 replies; 7+ messages in thread
From: Christian Plessl @ 2001-01-19  3:18 UTC (permalink / raw)
  To: ecos-discuss

Oops, hmm, I forgot to attach my posting...

.. so here we go..



Just to make this sure.

How did you link your executable? Did you make 2 seperate ecos trees, one 
for building the ecos loader with gdb-stubs and another tree for building 
the ecos library which is linked with your application

ecosconfig new pc stubs
ecosconfig tree
make

--> this gives you the loader

than, in a different directory

ecosconfig new pc (note! no stubs here)
ecosconfig tree
make

this gives you the library to link your application with

Chris




--
Christian Plessl <cplessl@ee.ethz.ch>

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

end of thread, other threads:[~2001-01-19  8:25 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-01-18  9:40 [ECOS] i386 target crashes after download Jochen Hagemann
2001-01-18 13:51 ` Jonathan Larmour
2001-01-19  1:41   ` Jochen Hagemann
2001-01-19  2:03     ` Christian Plessl
     [not found]   ` <5.0.2.1.0.20010119105711.00a90510@imap.ee.ethz.ch>
2001-01-19  7:40     ` Jochen Hagemann
2001-01-19  8:25       ` Christian Plessl
2001-01-19  3:18 Christian Plessl

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).