Search the web
Sign In
New User? Sign Up
lpc2000 · LPC ARM Group
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Want to share photos of your group with the world? Add a group photo to Flickr.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
Re: Simple test program - is now instruction pipeline/VPB question   Message List  
Reply | Forward Message #37 of 45977 |
Re: [lpc2100] Simple test program - is now instruction pipeline/VPB question

At 05:07 AM 11/23/03 +1100, you wrote:
>The 2nd question is, what if I write at a slower rate to VPB ?
>Do I still need the fastest pclk for my I/O pins to update as fast as
>possible ?????
>(I can't trace :-)
>
>As an example, C code generating this sequence :
>.......
>STR R4,[R7,#0] P0.0 set to "1"
>MOV R4,#1
>STR R4,[R0,#0] P0.0 set to "0"
>......
>
>Takes :
>1.6 uS (16 cclks) with pclk = 4 cclks
>1.0 uS (10 cclks) with pclk = 2 cclks
>0.8 uS (8 cclks) with pclk = 1 cclks
>
>(that's what I measure here on HW)
>
>Is there anyone that can shed some light on this ?
>
>
>
>toggling P0.0 with pclk = cclk/4
>
>
>-- Kris
><http://www.microbit.com.au>www.microbit.com.au
>

I was going to play with bus optimization next anyway so I thought I'd
measure the results and pass them along.

All of these with a 10MHz clock PLL'd to 60MHz.

MAM Off
ASM optimized 1.06uS period ~740nS on ~330nS off
C 1.8uS period ~800ns on ~1uS off

MAM on, Access to flash at recommended 3 cycles, VPB divider at default.
ASM optimized near square wave with 600nS period
C near square wave with 736nS period

MAM on , Access to flash at recommended 3 cycles, , VPB divider to 1
ASM optimized 264nS period ~168nS off ~118nS on
C near square wave with 416nS period

The (hand) optimized assembly loop used is

mov r3, #256
ldr r2, .L67+32
ldr r4, .L67+36
.L64:
str r3, [r2, #0]
str r3, [r4, #0]
b .L64

If the output is instruction rate limited then I would expect an output
with an approx 2/3 duty cycle. That is only approached for the first
case. For all other cases there is clearly some time taken up with I/O.

Also clearly getting maximum throughput will depend on setting up the bus
'correctly'.

Setting the VPB divider to 1 in this configuration also seems to have an
effect on the UART. I haven't figured that out yet but what should be
9600 baud drops to about 9000 baud.

Robert Adsett




Sat Nov 22, 2003 10:47 pm

robertadsett
Offline Offline
Send Email Send Email

Forward
Message #37 of 45977 |
Expand Messages Author Sort by Date

Hi Leon, I'm "on the air" now too with LPC2106 ! Here is a prelim. current consumption figure I took : I measure 6.5 mA @ 10 MHz setting and clearing P0.0 in a...
microbit
microbit@...
Send Email
Nov 22, 2003
6:14 pm

... I was going to play with bus optimization next anyway so I thought I'd measure the results and pass them along. All of these with a 10MHz clock PLL'd to...
Robert Adsett
robertadsett
Offline Send Email
Nov 22, 2003
10:48 pm

Here is an explanation of the I/O toggle speed that is observed in these devices. Richard The I/O speed has a maximum at ~3.7 Mhz because of several reasons, ...
philips_apps
Offline Send Email
Nov 10, 2004
9:27 pm

Hello, first many thanks for your explanation ! We had a similar thread in this mailinglist at 1st of Feb 2004 (name: Optimization of capture routine...). ...
capiman@...
capiman26061973
Offline Send Email
Nov 11, 2004
6:58 am

Is there any published documentation which contains this information (e.g.: that VPB operations are 3 clocks)? ... the ... the ... itself. ... pin) ... is ... ...
lp2000c
Offline Send Email
Nov 11, 2004
5:41 pm

... Got it. Cleaning up by support and generalizing it so I could place it with some newlib support and I realized that I had misplaced the pll divider field...
Robert Adsett
robertadsett
Offline Send Email
Dec 3, 2003
11:42 pm
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help