亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? boot_gnu.s

?? altera epxa1的例子程序
?? S
?? 第 1 頁 / 共 3 頁
字號:
//***************************************************************************
//***************************************************************************
//
//                           boot.s
//
//  This assembly code file demonstrates the boot process of Altera 
//  ARM-based Excalibur devices.  After executing this boot code, the
//  Excalibur device will be fully configured and initialized for basic 
//  system operation.
//
//  Note that the code in this file is not intended to be efficient nor is
//  it intended to follow proper assembly coding style.  The purpose of the
//  code in this file is for demonstration and clarity of the procedures
//  performed.  Literal values are used in most cases in place of variables
//  to allow easy correlation with register descriptions in the ARM-based 
//  Excalibur Hardware Reference Manual.  The Excalibur Megawizard Plugin
//  for the Quartus II software provides header files that contain much of
//  the information presented here as literal values.
//
//  Copyright (c) Altera Corporation 2001.
//  All rights reserved.
//
//***************************************************************************
//***************************************************************************

#define	EXC_REGISTERS_BASE (0x7fffc000)                 //-Stripe configuration
                                                        //  register base

	.section .text

//***************************************************************************
//                          Vector Table
//
//  This section acts as the processor's interrupt vector table.  When 
//  booting is complete, this table will reside at address 0, the fixed 
//  interrupt vectors taken by the ARM922T microprocessor
//
//***************************************************************************

    b   START
    b   UDEFHND
    b   SWIHND
    b   PABTHND
    b   DABTHND
    b   UNEXPECTED
    b   IRQHND
    b   FIQHND


START:


//***************************************************************************
//                           Read IDCODE
//
//  This section reads the IDCODE register ad address (base + 0x8) and 
//  compares it to the XA10 IDCODE, 0x090010DD.  An error vector is taken if 
//  they do not match.

//***************************************************************************

    ldr     r0, =(EXC_REGISTERS_BASE + 0x8)         //-Load address of IDCODE
    ldr     r1, [r0]                                //-Load value of IDCODE
    ldr     r2, =0x090010DD                         //-IDCODE for EPXA10
    cmp     r1,r2                                   //-Compare IDCODE's
    bne     ID_Error                                //-Take error vector if
                                                    //  they do not match

//***************************************************************************
//                            Setup PLLs
//
//  The PLL setup section configures PLL1 and PLL2 to run at 125MHz and 
//  100MHz, respectively.  CLK_OUT = ((CLK_REF * (M / N)) / K).  With a 
//  CLK_REF of 50MHz, the values of PLL1 will be set to N=1, M=10, K=4 to 
//  make its output 125MHz.  Similarly, PLL2 will be set to N=1, M=12, M=3.
//  Since we are using SDR SDRAM, PLL2 needs to be setup for twice our 
//  desired SDRAM frequency (See ARM-based Excalibur Hardware Reference 
//  Manual).  After the PLLs are setup, they are both started by writing
//  the recommended value to CTRL, and a logic 1 to the P bit of the 
//  registers CLK_PLL1_CTRL and CLK_PLL2_CTRL.  The bypass bits are cleared
//  for both PLLs, then we wait for them to lock.  The final step is to clear 
//  the "lock change" bits after the PLLs are locked.  Since this is an 
//  expected change in lock status (we just started the PLLs), we dont want 
//  to take the interrupt that these bits cause.
//
//***************************************************************************


//Load the M, N, and K counters for PLL1 and PLL2.

    ldr     r0, =(EXC_REGISTERS_BASE + 0x300)       //-Load address of CLK_PLL1_NCNT
    ldr     r1, =0x40000                            //-N=1
    str     r1, [r0]                                //-Load CLK_PLL1_NCNT


    ldr     r0, =(EXC_REGISTERS_BASE + 0x304)       //-Load address of CLK_PLL1_MCNT
    ldr     r1, =0x20505                            //-M=10
    str     r1, [r0]                                //-Load CLK_PLL1_MCNT


    ldr     r0, =(EXC_REGISTERS_BASE + 0x308)       //-Load address of CLK_PLL1_KCNT
    ldr     r1, =0x20101                            //-K=4
    str     r1, [r0]                                //-Load CLK_PLL1_KCNT


    ldr     r0, =(EXC_REGISTERS_BASE + 0x310)       //-Load address of CLK_PLL2_NCNT
    ldr     r1, =0x40000                            //-N=1
    str     r1, [r0]                                //-Load CLK_PLL2_NCNT

    ldr     r0, =(EXC_REGISTERS_BASE + 0x314)       //-Load address of CLK_PLL2_MCNT  
    ldr     r1, =0x20606                            //-M=12
    str     r1, [r0]                                //-Load CLK_PLL2_MCNT

    ldr     r0, =(EXC_REGISTERS_BASE + 0x318)       //-Load address of CLK_PLL2_KCNT 
    ldr     r1, =0x10201                            //-K=3
    str     r1, [r0]                                //-Load CLK_PLL2_KCNT


//Set CTRL field in PLL control registers and start the PLLs.  The value written to 
//  CLK_PLLx_CTRL is dependent upon the frequencies involved.

    ldr     r0, =(EXC_REGISTERS_BASE + 0x30C)       //-Load address of CLK_PLL1_CTRL
    ldr     r1, =0x01035
    str     r1, [r0]                                //-Start PLL1

    ldr     r0, =(EXC_REGISTERS_BASE + 0x31C)       //-Load address of CLK_PLL2_CTRL
    str     r1, [r0]                                //-Start PLL2


//Clear both PLLs' bypass bits

    ldr     r0, =(EXC_REGISTERS_BASE + 0x320)       //-Load address of CLK_DERIVE
    ldr     r1, =0x10                               //-Write 0x10 to it
    str     r1, [r0]                                //  to clear bits 12, 13


//Wait for PLLs to lock

    ldr     r0, =(EXC_REGISTERS_BASE + 0x324)       //-Load address of CLK_STATUS
PLL_CHECK:
    ldr     r1, [r0]                                //-Load value of CLK_STATUS
    cmp     r1, #0x3F                               //-Check low 7 bits are '1'
    bne     PLL_CHECK                               //-Loop until they are


//Since the lock change bits just went high, we need to clear them to prevent
//a resulting interrupt.  r0 should still contain the address of CLK_STATUS.

    ldr     r1, =0xC                                //-Write '1's to bits 2, 3
    str     r1, [r0]                                //  of CLK_STATUS


//***************************************************************************
//                Setup Memory Map and Copy Code to SRAM
//
//  In this section, we prepare the system to run software code out of SRAM.  
//  Upon entering this section, the boot code running is running out of Flash 
//  memory on EBI0.  This section performs the following steps.
//
//  -- Map EBI0 (Flash) to 0x40000000 with a size of 4MB
//  -- Branch to newly mapped copy of EBI0 at 0x40000000
//  -- Turn off default boot mapping as we no longer need an alias of EBI0 
//     at address 0x0
//  -- Map SRAM0 to 0x0 with a size of 128KB
//  -- Map SRAM1 to 0x20000 with a size of 128KB
//  -- Copy code from Flash on EBI0 at 0x40000000 to SRAM0 at address 0x0.
//  --   Note : This example copies 128K of data from Flash to SRAM0.  This
//  --          fills all of SRAM0 in an EPXA10 as this example is
//  --          intended to be universal.  Normally, only the amount of 
//  --          data that is needed would be copied.
//  -- Branch to new copy of code residing in SRAM0
//  -- Map SDRAM0 to 0x10000000 with a size of 128MB
//
//  At the end of this section, code is running out of SRAM0.  
//  
//***************************************************************************

SETUP_MEM_MAP:

MAP_EBI0:
    ldr     r0, =(EXC_REGISTERS_BASE + 0xC0)        //-Map EBI0
    ldr     r1, =0x40000A83                         //  by loading register
    str     r1, [r0]                                //  MMAP_EBI0

BRANCH_TO_EBI0:
    ldr     r0, =0x40000000                         //-Branch to where EBI0
    add     pc, pc, r0                              //  was just mapped.
    nop                                             //-NOP is not executed as
    												//  pipeline is flushed
    												//  when pc is altered.

TURN_OFF_BOOT_MAP:
    ldr     r0, =(EXC_REGISTERS_BASE + 0x0)         //-Turn off boot mapping
    ldr     r1, =0x1                                //  by loading register
    str     r1, [r0]                                //  BOOT_CR

MAP_SRAM0:
    ldr     r0, =(EXC_REGISTERS_BASE + 0x90)        //-Map SRAM0
    ldr     r1, =0x20000803                         //  by loading register
    str     r1, [r0]                                //  MMAP_SRAM0

MAP_SRAM1:
    ldr     r0, =(EXC_REGISTERS_BASE + 0x94)        //-Map SRAM1
    ldr     r1, =0x20020803                         //  by loading register
    str     r1, [r0]                                //  MMAP_SRAM1

COPY_CODE_TO_SRAM0:
    ldr     r9, =0x20000000                         //-Load address of SRAM0
    ldr     r10, =0x40000000                        //-Load address of EBI0
    add     r11, r10, #0x20000                      //-Load address of last
                                                    //  word in flash to copy
COPY_8_WORDS:
    ldmia   r10!, {r0-r7}                           //-Load 8 words from flash
    stmia   r9!, {r0-r7}                            //-Store 8 words to SRAM0
    cmp     r10, r11                                //-Repeat until SRAM0 is
    blo     COPY_8_WORDS                            //  full

BRANCH_TO_SRAM0:
    ldr     r0, =0x20000000                         //-Branch to SRAM0 where
    ldr     r1, =0x40000000                         //  boot code was copied
    sub     r0, r1, r0
    sub     pc, pc, r0
    nop                                             //-NOP is not executed as

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲天堂a在线| 国产成人综合亚洲网站| 国产精品国产三级国产普通话99 | 日本一区二区三区dvd视频在线| 欧美三级中文字幕在线观看| 波多野结衣中文字幕一区二区三区| 久久爱另类一区二区小说| 亚洲成a天堂v人片| 亚洲色图一区二区三区| 国产欧美日韩综合精品一区二区| 日韩欧美国产一区二区在线播放| 欧美日韩性生活| 欧美日韩亚洲国产综合| 日本二三区不卡| 色狠狠av一区二区三区| 99久久综合99久久综合网站| 国产传媒欧美日韩成人| 国产激情一区二区三区四区| 国产精品99久久久久久有的能看| 狠狠网亚洲精品| 国产一区在线观看视频| 国产毛片精品一区| 国产大陆亚洲精品国产| 国产91丝袜在线18| 欧美在线free| 成人app在线观看| 丁香天五香天堂综合| 国产91丝袜在线观看| 国产成人亚洲综合a∨婷婷图片| 国产专区欧美精品| 国产成人精品亚洲午夜麻豆| 国产sm精品调教视频网站| 成人动漫在线一区| 99久久国产综合精品女不卡| 91麻豆福利精品推荐| 欧美伊人精品成人久久综合97| 欧洲亚洲国产日韩| 欧美喷水一区二区| 日韩欧美在线123| 久久蜜臀中文字幕| 国产欧美一区二区精品性色 | 国产一区二区看久久| 国内欧美视频一区二区 | 国产精品少妇自拍| 亚洲欧洲美洲综合色网| 一区二区三区中文免费| 天天综合网天天综合色| 精品影视av免费| 国产成人av一区二区| 91麻豆国产精品久久| 在线看日本不卡| 日韩欧美在线观看一区二区三区| 精品少妇一区二区三区视频免付费| 久久精品视频一区二区| 成人免费在线观看入口| 亚洲成av人片在线观看| 国产一区亚洲一区| 91日韩在线专区| 欧美一区二区在线不卡| 国产午夜精品福利| 樱桃视频在线观看一区| 美女久久久精品| 91在线看国产| 欧美日韩亚洲另类| 久久久久久久久久久久久夜| 亚洲欧美日韩久久精品| 美国av一区二区| 97精品久久久午夜一区二区三区| 欧美日韩一级片网站| 久久久久99精品一区| 亚洲午夜私人影院| 国产精品一区在线观看你懂的| 色老汉一区二区三区| 精品国产麻豆免费人成网站| 国产精品国产三级国产aⅴ入口 | 欧美日韩1区2区| 成人免费在线播放视频| 日本美女视频一区二区| 99久久精品国产精品久久| 日韩一区二区视频| 亚洲免费观看高清完整版在线观看熊 | 图片区日韩欧美亚洲| 国产在线播精品第三| 欧美系列亚洲系列| 欧美激情在线观看视频免费| 亚洲超碰精品一区二区| 成人理论电影网| 日韩三级视频在线看| 亚洲日本免费电影| 精品一二三四区| 精品视频资源站| 中文av字幕一区| 蜜臀va亚洲va欧美va天堂| 99精品久久免费看蜜臀剧情介绍| 精品国产乱码久久| 亚洲国产日韩在线一区模特| 国产精品一品二品| 日韩欧美国产三级| 亚洲高清免费观看高清完整版在线观看| 国产美女av一区二区三区| 欧美高清激情brazzers| 亚洲人被黑人高潮完整版| 国产高清不卡二三区| 8v天堂国产在线一区二区| 亚洲激情校园春色| 成人动漫一区二区三区| 精品国产免费一区二区三区四区| 亚洲成a人v欧美综合天堂| 日本韩国一区二区三区| 国产精品区一区二区三| 韩国精品主播一区二区在线观看| 在线成人av网站| 午夜影视日本亚洲欧洲精品| 91丝袜高跟美女视频| 欧美国产欧美亚州国产日韩mv天天看完整 | 大美女一区二区三区| 日韩免费一区二区三区在线播放| 亚洲高清视频在线| 在线观看亚洲a| 亚洲美女在线国产| 91香蕉视频污在线| 国产精品传媒在线| 波多野结衣在线aⅴ中文字幕不卡| 久久精品人人爽人人爽| 韩国v欧美v日本v亚洲v| 精品国产乱码久久久久久夜甘婷婷 | 国产美女精品在线| 亚洲精品在线观| 99久久综合色| 国产欧美精品国产国产专区| 国产成人av电影在线| 国产欧美日韩在线观看| 成人午夜精品在线| 中文字幕在线一区免费| caoporen国产精品视频| 亚洲视频 欧洲视频| 日本二三区不卡| 亚洲一区二区精品久久av| 欧美日韩欧美一区二区| 日本91福利区| 精品奇米国产一区二区三区| 九九国产精品视频| 国产清纯在线一区二区www| 国产精品 欧美精品| 国产精品免费aⅴ片在线观看| 不卡影院免费观看| 日韩理论片在线| 在线免费观看视频一区| 午夜成人免费电影| 欧美一区二区三区喷汁尤物| 美腿丝袜亚洲色图| 国产午夜一区二区三区| 91在线视频18| 亚洲高清免费一级二级三级| 91精品国产欧美一区二区| 精品一二三四在线| 中日韩免费视频中文字幕| 91免费版在线| 亚洲一级二级三级在线免费观看| 欧美日韩在线播| 美女一区二区视频| 国产亚洲va综合人人澡精品| 色综合一个色综合| 午夜精品久久久久久久久久| 精品久久久久久久久久久久久久久 | 欧美四级电影网| 久久精品国产99国产精品| 中文幕一区二区三区久久蜜桃| 色婷婷av一区二区三区大白胸 | 91精品国产色综合久久久蜜香臀| 看国产成人h片视频| 国产精品污网站| 欧美三级欧美一级| 国内精品久久久久影院薰衣草| 综合久久国产九一剧情麻豆| 欧美精品99久久久**| 成人永久免费视频| 香蕉加勒比综合久久| 久久精品夜色噜噜亚洲a∨| 色天天综合久久久久综合片| 男女男精品网站| 国产精品日韩精品欧美在线| 欧美性猛交xxxx乱大交退制版| 蜜乳av一区二区三区| 最新热久久免费视频| 777欧美精品| 欧美色窝79yyyycom| 精品亚洲porn| 亚洲黄色录像片| 久久综合国产精品| 欧美日韩在线精品一区二区三区激情| 国产专区综合网| 亚洲成人久久影院| 国产人妖乱国产精品人妖| 欧美酷刑日本凌虐凌虐| 不卡的av中国片| 久久国产精品无码网站| 亚洲一区二区三区四区五区黄| 久久久久久久电影| 制服丝袜日韩国产|