public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* Re: [ECOS] ROM startup on EP7212
       [not found] <CAEMICOOKMKAGHPNGNFNOEDECHAA.danc@iobjects.com>
@ 2001-03-23  7:45 ` Fano Ramparany
  0 siblings, 0 replies; 6+ messages in thread
From: Fano Ramparany @ 2001-03-23  7:45 UTC (permalink / raw)
  To: Dan Conti; +Cc: eCos Disuss

You were right, Dan. The march 23, 2001 eCos version corrects the problem.
Thank you Lewin and Dan for your help.

Fano

Dan Conti wrote:

> there were some snapshots from cvs that had a cdl bug involving rom builds
> and serial i/o via virtual vectors. when switched to rom mode, as i
> remember, it didn't correctly reconfigure the virtual vector setup, and you
> ended up with (as was described in an earlier reply) a situation where
> diagnostic i/o gets dumped into la-la land.
>
> have you tried updating to a more recent snapshot?
>
> -Dan

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

* Re: [ECOS] ROM startup on EP7212
  2001-03-22  5:43     ` Lewin A.R.W. Edwards
@ 2001-03-22  8:22       ` Fano Ramparany
  0 siblings, 0 replies; 6+ messages in thread
From: Fano Ramparany @ 2001-03-22  8:22 UTC (permalink / raw)
  To: Lewin A.R.W. Edwards; +Cc: eCos Disuss

"Lewin A.R.W. Edwards" wrote:

> Hi Fano,
>
> > > Does the DIAG LED come on when you hit the wakeup button?
> >
> >Yes it does. However I've noticed that it does only if I switch off and switch
> >on the board before doing the "ureset wakeup" (if the boards remains
> >switched on and I do several "ureset wakeup", then only the first and
> >sometimes second ones make the DIAG come on.
>
> This is some artifact of the Cirrus board. I haven't bothered to look into
> this issue extensively (because it just didn't seem that important) but I
> think the state of the boot jumper is only read on powerup or hard reset
> (NOT user reset). My two EDB7212s are both a bit flaky/recalcitrant about
> being re-flashed, quite often it seems to "tire" the board and I need to
> leave it off for a few minutes before the board will work again.
>
> >No this example doesn't make the buzzer work, although the diag led turns on.
>
> Then your code is probably never getting to main.

One application I've managed to run on rom startup mode is a video decoder,
which displays the video on the LCD screen. For this code control reaches the
main. I was rather thinking about a mistake on the configuration of the serial
line driver,
or a change (with respect to the 1.3.1 version of the driver) which could explain
why "printf"
of "diag_printf" didn't send data to the serial port.

> Maybe you could email me
> the compiled .exe (not the .bin) and I could have a quick look at it?

I'll send you the hello.exe file offline.

> Also, did you change the CPU variant to EP7212? (Not that it seems to make
> any difference).

Yes I did.

> >What date your version of ecos is?
>
> I have built ROM-startup binaries (working, of course) using the 1.3.1
> release and also using CVS, the most recent CVS checkout date for which
> I've tested ROM startup is 2001-02-28.

I'll check if my problem is solved with a more recent version of eCos.

>
> There's a deep problem here, control doesn't seem to be passing to your
> program. Put a write to one of the GPIO ports as the first thing in main()
> and see if the chip's pin changes state to absolutely confirm this.

Do you mean serial port when you say GPIO? and how can I check the chip's pin
changes
practically (sorry I'm a software oriented guy and don't have much experience
yet on hardware manipulation).

Thank you for your help.

Fano

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

* Re: [ECOS] ROM startup on EP7212
  2001-03-22  0:51   ` Fano Ramparany
@ 2001-03-22  5:43     ` Lewin A.R.W. Edwards
  2001-03-22  8:22       ` Fano Ramparany
  0 siblings, 1 reply; 6+ messages in thread
From: Lewin A.R.W. Edwards @ 2001-03-22  5:43 UTC (permalink / raw)
  To: Fano.Ramparany; +Cc: eCos Disuss

Hi Fano,

> > Does the DIAG LED come on when you hit the wakeup button?
>
>Yes it does. However I've noticed that it does only if I switch off and switch
>on the board before doing the "ureset wakeup" (if the boards remains 
>switched on and I do several "ureset wakeup", then only the first and 
>sometimes second ones make the DIAG come on.

This is some artifact of the Cirrus board. I haven't bothered to look into 
this issue extensively (because it just didn't seem that important) but I 
think the state of the boot jumper is only read on powerup or hard reset 
(NOT user reset). My two EDB7212s are both a bit flaky/recalcitrant about 
being re-flashed, quite often it seems to "tire" the board and I need to 
leave it off for a few minutes before the board will work again.

>No this example doesn't make the buzzer work, although the diag led turns on.

Then your code is probably never getting to main. Maybe you could email me 
the compiled .exe (not the .bin) and I could have a quick look at it?

Also, did you change the CPU variant to EP7212? (Not that it seems to make 
any difference).

>What date your version of ecos is?

I have built ROM-startup binaries (working, of course) using the 1.3.1 
release and also using CVS, the most recent CVS checkout date for which 
I've tested ROM startup is 2001-02-28.

>just wanted to add some tracing (simple printf calls) to check on the 
>hyperterminal  how far the application on the board is going? but couldn't.

There's a deep problem here, control doesn't seem to be passing to your 
program. Put a write to one of the GPIO ports as the first thing in main() 
and see if the chip's pin changes state to absolutely confirm this.

Weren't you also the person having troubles writing to LCD frame buffer 
memory? That was also a bizarre one.

=== Lewin A.R.W. Edwards (Embedded Engineer)
Work: http://www.digi-frame.com/
Personal: http://www.zws.com/ and http://www.larwe.com/

"Und setzet ihr nicht das Leben ein,
Nie wird euch das Leben gewonnen sein."

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

* Re: [ECOS] ROM startup on EP7212
  2001-03-21  9:47 ` Lewin A.R.W. Edwards
@ 2001-03-22  0:51   ` Fano Ramparany
  2001-03-22  5:43     ` Lewin A.R.W. Edwards
  0 siblings, 1 reply; 6+ messages in thread
From: Fano Ramparany @ 2001-03-22  0:51 UTC (permalink / raw)
  To: Lewin A.R.W. Edwards; +Cc: eCos Disuss

"Lewin A.R.W. Edwards" wrote:

> Does the DIAG LED come on when you hit the wakeup button?

Hi Lewin,
Yes it does. However I've noticed that it does only if I switch off and switch
on the
board before doing the "ureset wakeup" (if the boards remains switched on and
I do several "ureset wakeup", then only the first and sometimes second ones
make the DIAG come on.

> If so, try to compilfde this little example (just paste it over hello.c).
> Connect a loudspeaker to position LS2 on the board. If you hear a beep out
> of it, then the code is running and getting to main() OK.

No this example doesn't make the buzzer work, although the diag led turns on.

What date your version of ecos is?

The reason I've tested back the rom startup of hello.c. Is that I have just
finished testing  a client/server application with the redboot monitor. This
worked
fine, but the application gets stuck once I moved it to rom startup mode. So I
just wanted
to add some tracing (simple printf calls) to check on the hyperterminal  how
far the application
on the board is going? but couldn't.

Thank you again for your help.

Fano

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

* Re: [ECOS] ROM startup on EP7212
  2001-03-21  9:03 Fano Ramparany
@ 2001-03-21  9:47 ` Lewin A.R.W. Edwards
  2001-03-22  0:51   ` Fano Ramparany
  0 siblings, 1 reply; 6+ messages in thread
From: Lewin A.R.W. Edwards @ 2001-03-21  9:47 UTC (permalink / raw)
  To: Fano.Ramparany, eCos Disuss

Hi Fano,

>checked in the ROM startup, set the EP7212 processor variant,
>ticked the box "Hardware serial device drivers".
>Then I've build the .bin  using "arm-elf-objcopy -O binary..."
>and downloaded it on the board using "dl_edb7.exe".

Does the DIAG LED come on when you hit the wakeup button?

If so, try to compile this little example (just paste it over hello.c). 
Connect a loudspeaker to position LS2 on the board. If you hear a beep out 
of it, then the code is running and getting to main() OK.

I think the most likely problem is that console output isn't going anywhere 
(it's being sent to a nonexistent debugger).

#include <cyg/kernel/kapi.h>
#include <cyg/hal/hal_edb7xxx.h>

/*
         Wiggle the buzzer output bit with specified period and duration
         Both period and duration are in arbitrary units based on processor
         speed and Icache enabled/disabled state.
         For the EP7212 at 74MHz, a typical value for a system beep would be
         period = 100, duration = 500. Duration for such a system is 
calibrated to
         be VERY ROUGHLY 1u=0.5ms.
*/
void BUZZ_SimpleBeep(int period, int duration)
{
         volatile cyg_uint32 *p = (volatile cyg_uint32 *) SYSCON1;
         volatile int i;

         // This just makes the input values of period and duration more 
reasonable
         duration = duration * 1000;
         period = period * 10;

         while (duration) {
                 *p |= SYSCON1_BZTOG;
                 for (i=0;i<period;i++) { }
                 *p &= ~SYSCON1_BZTOG;
                 for (i=0;i<period;i++) { }

                 if (duration < period)
                         duration = 0;
                 else
                         duration -= period;
         }
}

int main(void) {
BUZZ_SimpleBeep(100,500);
}
=== Lewin A.R.W. Edwards (Embedded Engineer)
Work: http://www.digi-frame.com/
Personal: http://www.zws.com/ and http://www.larwe.com/

"Und setzet ihr nicht das Leben ein,
Nie wird euch das Leben gewonnen sein."

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

* [ECOS] ROM startup on EP7212
@ 2001-03-21  9:03 Fano Ramparany
  2001-03-21  9:47 ` Lewin A.R.W. Edwards
  0 siblings, 1 reply; 6+ messages in thread
From: Fano Ramparany @ 2001-03-21  9:03 UTC (permalink / raw)
  To: eCos Disuss

I have some problems running the hello.c under rom startup mode.
To summarize:
I've build the eCos Library from the cirrus logic HW + default template,

checked in the ROM startup, set the EP7212 processor variant,
ticked the box "Hardware serial device drivers".
Then I've build the .bin  using "arm-elf-objcopy -O binary..."
and downloaded it on the board using "dl_edb7.exe".
When I reset and wake up the board, the hyperterminal
doesn't display the "Hello, eCos world!"
I use the Windows toolchain, jan.30, 2001 eCos snapshot
and Configuration Tool 1.3.1.2

The Hyperterminal configuration is OK, as loading redboot
yields the correct redboot prompt.

I've seen a thread some weeks ago on this rom startup problem,
which ended up recommending building a tree for rom startup
from scratch (instead of starting from a ram startup tree).
Thus I followed this recommendation but with no result.

I remember it working with the Configuration Tool 1.3.1 and the
eCos net distribution (dated Oct. 2000).

Any hint is welcome

Fano



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

end of thread, other threads:[~2001-03-23  7:45 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CAEMICOOKMKAGHPNGNFNOEDECHAA.danc@iobjects.com>
2001-03-23  7:45 ` [ECOS] ROM startup on EP7212 Fano Ramparany
2001-03-21  9:03 Fano Ramparany
2001-03-21  9:47 ` Lewin A.R.W. Edwards
2001-03-22  0:51   ` Fano Ramparany
2001-03-22  5:43     ` Lewin A.R.W. Edwards
2001-03-22  8:22       ` Fano Ramparany

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