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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? cstartup.asm

?? Audio output from sound file for MCU.
?? ASM
字號:
;==============================================================================
; Cyan Technology Ltd
;
; FILE
;  cstartup.asm - Assembler startup for C programs.
;
; DESCRIPTION
;  Defines C segments. Contains initial code called before C is started
;==============================================================================

                   MODULE   cstartup
                  .ALL

;
; C reserves DATA address 0 for the NULL pointer. The value H'DEAD is put in
; here so that it is easier to spot the effect of a NULL pointer during
; debugging. User memory for constants grows upwards from H'0001. The first
; address is given the equate symbol $??LO_ADDR.
;
                  .SEG     C_RESERVED1
                  ORG      0xe000
                  dc       H'DEAD
$??LO_ADDR        EQU      $

;
; DATA addresses H'EFE0-H'EFFF are used for scratchpad RAM in interrupt mode.
; DATA addresses H'EFC0-H'EFDF are used for scratchpad RAM in user mode.
; DATA addresses H'EFB8-H'EFBF are used for register storage in interrupt mode.
; Then follows the interrupt stack, user stack and user heap.
; User memory for variables grows downwards from the end of the user stack.
; This version of cstartup only contains one area of scratchpad RAM
; which constrains users not to write re-entrant re-interruptable
; code.
; The interrupt stack must start at IY-38 to be compatible with the C compiler.
;
                  .SEG     C_RESERVED2
                  ORG      H'EFB8

$??HI_ADDR        DEQU     $
                  ds       8           ; Interrupt register storage

                  ds       32          ; User Scratchpad
IY_SCRATCH        DEQU     $

$?irq_scratchpad? DEQU     $
                  ds       32          ; Interrupt Scratchpad

;
; The registers that control the functional blocks of the eCOG1 are located
; at addresses H'FEA0 to H'FFCF. The C header file <ecog1.h> declares an
; external structure that descibes the registers. This variable is defined
; below.
;
                  .SEG     REGISTERS
                  ORG      H'FEA0
$fd:
$rg               ds       304

;
; C requires the following segments:
;     CONST  - Constants in ROM. For example:
;                 const char c = 'c' ;
;                 printf( "Hello World!" ) ;
;     VAR    - Variables in RAM. These are set to zero by the cstartup code.
;              For example:
;                 int i ;              (in file scope)
;                 static int i ;       (in function scope)
;     INIT   - Initialisd variables in RAM. For example:
;                 int i = 9 ;          (in file scope)
;                 static int i = 9 ;   (in function scope)
;     INITC  - Initialisation data for the INIT segment
;     HEAP   - The heap. Required if malloc() etc. are used.
;     STACK  - The stack. Always required.
;
; The memory allocated to each segment is defined by the value of
; $??<segment_name>_SIZE as set below. These sizes can be set manually or, if
; the appropriate line is tagged with !PACK and the -pack option is specified
; to ECOGCL, ECOGCL will write in the size actually required for the segment.
; The sizes of the STACK and HEAP segments must be set by the user.
;
$??ISTACK_SIZE    =        H'0040
$??STACK_SIZE     =        H'0100
$??HEAP_SIZE      =        H'0080

; ROM segments
$??INITC_SIZE     =        h'0000  ; !PACK
$??CONST_SIZE     =        h'009d  ; !PACK

; RAM segments
$??INIT_SIZE      =        h'0000  ; !PACK
$??VAR_SIZE       =        h'0008  ; !PACK


; -- Locate DATA segments in memory --
;
; Segments are allocated sequentially by the ??ALLOCATE macro. They may be
; set at fixed addresses by setting ADDR prior to calling ??ALLOCATE.
;
??ALLOCATE        MACRO    seg
                  .SEG     &seg
                  ORG      ADDR
$??&seg!_LO       = ADDR
ADDR              = ADDR + $??&seg!_SIZE
$??&seg!_HI       = ADDR-1
                  ENDMAC

; Allocate DATA ROM
ADDR              = $??LO_ADDR
                  ??ALLOCATE INITC
                  ??ALLOCATE CONST

; Allocate DATA RAM
ADDR              = $??HI_ADDR - $??VAR_SIZE - $??INIT_SIZE
ADDR              = ADDR - $??ISTACK_SIZE - $??STACK_SIZE - $??HEAP_SIZE
                  ??ALLOCATE INIT
                  ??ALLOCATE VAR
                  ??ALLOCATE HEAP
                  ??ALLOCATE STACK
                  ??ALLOCATE ISTACK


; -- Memory initialisation macros --
;
; Segments may be initialised by filling with a constant value using the
; ??SEGFILL macro.  Two symbols are passed, the segment name and the value to
; fill with.  A third symbol (the size) is assumed.
;
??SEGFILL         MACRO    seg, value
                  LOCAL    fill_loop
                  IF       $??&seg!_SIZE
                  ld       x, #$??&seg
                  ld       al, #$??&seg!_SIZE
                  ld       ah, &value
&fill_loop:       st       ah, @(0,x)
                  add      x, #1
                  sub      al, #1
                  bne      &fill_loop
                  ENDIF
                  ENDMAC

;
; Segments may be initialised by copying an initialisation segment with
; the ??SEGCOPY macro. Two symbols are passed, the source and destination
; segment names.
;
??SEGCOPY         MACRO    src, dest
                  IF       $??&src!_SIZE NE $??&dest!_SIZE
                  .ERR     "Copy segments different sizes"
                  ENDIF
                  IF       $??&src!_SIZE
                  ld       x, #$??&src
                  ld       y, #$??&dest
                  ld       al, #$??&src!_SIZE
                  bc
                  ENDIF
                  ENDMAC

;
; Fills a block of memory with a value. Three values are passed, the start
; address for the block, the number of addresses to write to and the value
; to be written.
;
??MEMFILL         MACRO    start, length, value
                  LOCAL    fill_loop
                  ld       x, &start
                  ld       al, &length
                  ld       ah, &value
&fill_loop:       st       ah, @(0,x)
                  add      x, #1
                  sub      al, #1
                  bne      &fill_loop
                  ENDMAC


;
; Input argument for main().
;
                  .SEG     CONST
argv              dc       0,0         ; NULL as two-word byte address 


;
; Start of Code.
;
                  .CODE
                  ORG      H'40

$?cstart_code:
        bra $ecog1ConfigMMU    ; configure MMU and Cache Banks

$ecog1ConfigContinue:

;
; Initialise segments. The HEAP and STACK are filled with H'9999 and H'aaaa
; respectively so that their maximum runtime extents can be checked. The
; INIT segment is set from the ROM initialisers in the INITC segment. The non
; initialised RAM segment VAR is set to zero (compiler puts 0 initialised
; variables in these segments as well as uninitialised ones,x).
;
                  ??SEGFILL HEAP, #h'9999
                  ??SEGFILL STACK, #h'AAAA
                  ??SEGFILL ISTACK, #h'BBBB
                  ??SEGCOPY INITC, INIT
                  ??SEGFILL VAR, #h'0

; Set interrupt stack pointer.
                  ld y, #IY_SCRATCH

; Set user mode flag to allow interupts.
                  st flags, @(-1,y)
                  ld al, @(-1,y)
                  or al, #h'10
                  st al, @(-1,y)
                  ld flags, @(-1,y)

; Set usermode stack pointer
                  ld y, #$??STACK_HI

; Call ecog1Config to setup eCOG1 peripherals
; Defined in module produced by configuration compiler
                  bsr $ecog1Config
                
; Call main, setting argc and argv[0] to 0.
                  ld ah, #argv
                  ld al, #0
                  bsr $main

;
; Main may exit by returning or by explicitly calling $exit. In either case
; exit code will be in AL.
;
$exit:
                  brk                   ; Alert the user if in debug mode
                  bra 0                 ; Restart program

;
; This is the minimal interrupt routine. The contents of FLAGS is restored
; as the program counter is restored using rti.
;
$minimal_handler:
                  st flags,@(-33,y)     ; Store Flags
                  st al, @(-34,y)       ; Store AL

                  ld al, @(-33,y)       ; Put Flags into AL
                  or al, #h'0010        ; Set usermode
                  st al, @(-33,y)       ; Store the value to be restored to Flags

                  brk                   ; Alert the user if in debug mode

                  ld al, @(-34,y)       ; Restore AL
                  rti @(-33,y)          ; Restore PC and Flags

;
; The address exception can happen often during development. A handler
; is put here to catch the exception.
;
$address_error:
                  st flags,@(-33,y)     ; Store Flags
                  st al, @(-34,y)       ; Store AL

                  ld al, @(-33,y)       ; Put Flags into AL
                  or al, #h'0010        ; Set usermode
                  st al, @(-33,y)       ; Store the value to be restored to Flags

                  brk                   ; Alert the user if in debug mode

                  ld al, #h'a
                  st al, @h'ff69        ; Clear status in mmu.address_exception

                  ld al, #h'200
                  st al, @h'ff7a        ; Clear status in emi.ctrl_sts

                  ld al, @(-34,y)       ; Restore AL
                  rti @(-33,y)          ; Restore PC and Flags

; End of startup code
$??CSTARTUP_END      EQU      $

                  ENDMOD

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
99久久久免费精品国产一区二区 | 色综合久久中文综合久久97| 久久你懂得1024| 韩国三级在线一区| 欧美高清在线精品一区| 9i在线看片成人免费| 一区二区在线观看视频| 欧美嫩在线观看| 蜜桃视频在线观看一区| 中文字幕乱码亚洲精品一区| 色综合久久综合网97色综合| 亚洲第一av色| 久久色在线观看| 99精品在线免费| 亚洲成a人在线观看| 欧美精品一区二区三| 成人午夜视频在线观看| 视频一区二区欧美| 欧美一区二区女人| 不卡欧美aaaaa| 亚洲第一狼人社区| 国产亚洲欧洲997久久综合| 91麻豆高清视频| 日本欧美久久久久免费播放网| 精品欧美一区二区三区精品久久 | 亚洲国产日韩av| 欧美成人a视频| 91麻豆蜜桃一区二区三区| 日韩精品1区2区3区| 国产女同互慰高潮91漫画| 在线观看亚洲a| 国产在线播放一区| 一区二区三区四区在线播放| 欧美成人a∨高清免费观看| 91视频在线观看免费| 日日嗨av一区二区三区四区| 免费观看在线综合色| 亚洲欧美日韩在线播放| 精品不卡在线视频| 欧美三级日本三级少妇99| 国产成人免费视频| 看电视剧不卡顿的网站| 一区二区三区在线视频免费观看| 26uuu久久天堂性欧美| 欧美区一区二区三区| 99视频热这里只有精品免费| 久久99精品一区二区三区| 亚洲综合成人在线视频| 亚洲国产成人午夜在线一区| 精品少妇一区二区| 欧美日韩电影在线| 色综合久久久久| fc2成人免费人成在线观看播放| 激情小说亚洲一区| 日韩国产欧美在线观看| 一区二区三区小说| 亚洲乱码中文字幕综合| 国产精品欧美一区二区三区| 久久久精品国产99久久精品芒果| 日韩欧美电影在线| 91精品国产高清一区二区三区蜜臀| 97se亚洲国产综合自在线观| 国产成人自拍在线| 国产一区二区福利视频| 国产专区欧美精品| 国产一区二区视频在线| 国产精品综合在线视频| 狠狠色丁香久久婷婷综合_中 | 一本大道久久a久久综合婷婷 | 亚洲曰韩产成在线| 亚洲柠檬福利资源导航| 亚洲图片欧美激情| 国产精品久久久久影院| 国产精品视频看| 国产精品不卡视频| 综合久久久久久久| 亚洲美女视频在线| 一区二区三区色| 亚洲综合激情小说| 亚洲愉拍自拍另类高清精品| 一区二区三区影院| 午夜精品一区二区三区免费视频| 亚洲国产精品影院| 日韩精品1区2区3区| 久久精品噜噜噜成人88aⅴ | 不卡电影一区二区三区| av中文字幕一区| 91捆绑美女网站| 精品视频全国免费看| 欧美日韩在线三级| 日韩免费视频一区二区| 久久午夜国产精品| 中文字幕亚洲成人| 亚洲成人久久影院| 蜜桃av一区二区三区| 国产精品1区二区.| 99久久久精品| 欧美日韩国产精选| 欧美mv和日韩mv的网站| 国产精品久久久久天堂| 一区二区三区 在线观看视频| 丝袜国产日韩另类美女| 极品销魂美女一区二区三区| 国产91丝袜在线播放九色| 色狠狠一区二区| 日韩三级在线观看| 国产精品无遮挡| 亚洲国产精品久久久久婷婷884| 久久精品国产在热久久| 不卡区在线中文字幕| 欧美丰满一区二区免费视频| 国产清纯美女被跳蛋高潮一区二区久久w | 91久久精品一区二区| 欧美一二三在线| 亚洲视频一二三| 男女男精品网站| 99免费精品视频| 精品久久久三级丝袜| 亚洲四区在线观看| 久久精品免费看| 欧美亚洲高清一区| 久久九九99视频| 亚洲成人免费观看| www.亚洲激情.com| 欧美草草影院在线视频| 亚洲女同ⅹxx女同tv| 国产在线精品一区二区| 欧美美女一区二区| 中文字幕一区在线| 国模娜娜一区二区三区| 欧美日韩亚洲综合在线 欧美亚洲特黄一级| 亚洲精品一区二区三区蜜桃下载| 亚洲一区在线观看免费| 国产91丝袜在线播放0| 日韩欧美一级特黄在线播放| 亚洲在线视频免费观看| www.在线成人| 久久久久久久久97黄色工厂| 水野朝阳av一区二区三区| 一本色道a无线码一区v| 国产色产综合色产在线视频| 久久国产三级精品| 69p69国产精品| 午夜伊人狠狠久久| 欧美视频日韩视频在线观看| 综合久久久久综合| 成人av电影在线| 久久一二三国产| 韩国三级在线一区| 日韩欧美美女一区二区三区| 五月婷婷久久综合| 欧美色图一区二区三区| 亚洲人成网站色在线观看| 色系网站成人免费| 免费看日韩a级影片| 99久久夜色精品国产网站| 久久亚区不卡日本| 久久精品国产99国产| 欧美一卡2卡三卡4卡5免费| 五月激情综合网| 欧美精品18+| 亚洲成人av一区| 91精品国产欧美一区二区 | 久久精品这里都是精品| 国产在线观看免费一区| 精品精品国产高清a毛片牛牛| 免费成人在线影院| 欧美精品一区二区三区很污很色的| 麻豆免费精品视频| 精品国产青草久久久久福利| 美女在线视频一区| 久久婷婷成人综合色| 国产黄人亚洲片| 中文字幕电影一区| 91浏览器入口在线观看| 亚洲成人av一区| 欧美成人一区二区三区片免费| 性欧美疯狂xxxxbbbb| 欧美在线观看视频一区二区三区| 一区二区激情视频| 欧美人与性动xxxx| 首页欧美精品中文字幕| 日韩欧美一级二级三级| 国产aⅴ综合色| 亚洲精品一卡二卡| 欧美一区二区视频在线观看| 精品午夜久久福利影院| 国产精品乱人伦中文| 日本高清无吗v一区| 日本欧美一区二区| 国产日韩精品久久久| 色综合天天狠狠| 久久国产精品色| 国产精品久久久久一区| 69精品人人人人| 高清成人免费视频| 午夜激情一区二区| 久久久国产午夜精品| 在线一区二区三区做爰视频网站| 蜜臂av日日欢夜夜爽一区|