Yahoo Groups archive

Lpc2000

Index last updated: 2026-04-28 23:31 UTC

Message

Re: Different execution speed between simulator and chip (LDRB, STRB instructions).

2005-09-27 by conhalk

Thank you Karl. I guess I will have to use a latch externally and 
read two bytes each time on P0.0-16. Anyway, I believe the simulator 
shouldn't display those waveforms and timing information, since 
letting you select a specific chip as target, and simulating its 
peripherals implies they have sorted these things out.



--- In lpc2000@yahoogroups.com, "Karl Olsen" <kro@p...> wrote:
> --- In lpc2000@yahoogroups.com, "conhalk" <conhalk@y...> wrote:
> 
> > I am using the lpc2138, and I have wrote a program which 
includes 
> > reading port0.16-24 pins at a 10 Mhz sampling rate:
> 
> [...]
> 
> > ON THE KEIL ARM SIMULATOR (60 MHZ) THE ROUTINE SAMPLES AT 10 Mhz.
> > 
> > ON THE REAL CHIP (60 MHZ) THE ROUTINE SAMPLES AT 5,5 Mhz ! ( I 
> > specify the function to be copied to ram)	
> > 
> > Meanwhile, I use an output compare timer on a pin, and it works 
at 
> > 10 Mhz both on the simulator and the chip (checked on a scope)!
> > 
> > The simulator shows the lDRB, STRB need 2,3 and the nop 1 cycle, 
> > hence rate = 60 / (3+2+1) = 10Mhz
> > 
> > I guess LDRB, STRB actually take double time. If it is so, does 
> > anybody know why? Is there any way around this?
> 
> The Keil simulator doesn't know about the waitstates that the MAM 
and 
> AHB-to-VPB bridge add.  The simulator is not useful for simulating 
> the timing of code involving jumps in flash and loads/stores to 
VPB 
> peripherals.
> 
> See also http://groups.yahoo.com/group/lpc2000/message/7808
> 
> > Unfortunately I must use the 2138, and it has no external bus. Is
> > it possible to achieve 10 Mhz sampling with this chip?
> 
> I don't think so.  It would with the new LPC214x or LPC210{1,2,3}.
> 
> Karl Olsen

Attachments

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.