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

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

?? start12.c

?? 飛思卡爾HCS12的OS移植(ucosII),實現了三個任務,IDE:CODEWARRIOR
?? C
?? 第 1 頁 / 共 2 頁
字號:
/*****************************************************
      start12.c - standard startup code
   The startup code may be optimized to special user requests
 ----------------------------------------------------
   Copyright (c) Metrowerks, Basel, Switzerland
               All rights reserved

Note: ROM libraries are not implemented in this startup code
Note: C++ destructors of global objects are NOT yet supported in the HIWARE Object File Format.
      To use this feature, please build your application with the ELF object file format.
 *****************************************************/
/*lint -esym(750, __NO_FLAGS_OFFSET, __NO_MAIN_OFFSET, __NO_STACKOFFSET_OFFSET) */
/* these macros remove some unused fields in the startup descriptor */
#define __NO_FLAGS_OFFSET       /* we do not need the flags field in the startup data descriptor */
#define __NO_MAIN_OFFSET        /* we do not need the main field in the startup data descriptor */
#define __NO_STACKOFFSET_OFFSET /* we do not need the stackOffset field in the startup data descriptor */

/*#define __BANKED_COPY_DOWN : allow to allocate .copy in flash area */
#if defined(__BANKED_COPY_DOWN) && (!defined(__HCS12X__) || !defined(__ELF_OBJECT_FILE_FORMAT__))
#error /* the __BANKED_COPY_DOWN switch is only supported for the HCS12X with ELF */
       /* (and not for the HC12, HCS12 or for the HIWARE object file format) */
#endif

#include "hidef.h"
#include "start12.h"

/***************************************************************************/
/* Macros to control how the startup code handles the COP:                 */
/* #define _DO_FEED_COP_  : do feed the COP                                */
/* #define _DO_ENABLE_COP_: do enable the COP                              */
/* #define _DO_DISABLE_COP_: disable the COP                               */
/* Without defining any of these, the startup code does NOT handle the COP */
/***************************************************************************/
/* __ONLY_INIT_SP define:                                                  */
/* This define selects an shorter version of the startup code              */
/* which only loads the stack pointer and directly afterwards calls        */
/* main. This version does however NOT initialized global variables        */
/* (So this version is not ANSI compliant!)                                */
/***************************************************************************/
/* __FAR_DATA define:                                                      */
/* By default, the startup code only supports to initialize the default    */
/* kind of memory. If some memory is allocated far in the small or banked  */
/* memory model, then the startup code only supports to initialize this    */
/* memory blocks if __FAR_DATA is defined. If __FAR_DATA is not defined,   */
/* then the linker will issue a message like                               */
/* "L1128: Cutting value _Range beg data member from 0xF01000 to 0x1000"   */
/* and this startup code writes to the cutted address                      */
/***************************************************************************/
/* __BANKED_COPY_DOWN define:                                              */
/* by default, the startup code assumes that the startup data structure    */
/* _startupData, the zero out areas and the .copy section are all 				 */
/* allocated in NON_BANKED memory. Especially the .copy section can be     */
/* if there are many or large RAM areas to initialize.                     */  
/* for the HCS12X, which also copies the XGATE RAM located code via .copy  */
/* section, the startup code supports to allocate .copy in a banked flash  */
/* The placement of .copy in the prm file has to be adapted when adding or */
/* removing the this macro.                                                */
/* Note: This macro is only supported for the HCS12X and when using ELF    */
/***************************************************************************/

#ifdef __cplusplus
#define __EXTERN_C  extern "C"
#else
#define __EXTERN_C
#endif

__EXTERN_C void main(void); /* prototype of main function */

#ifndef __ONLY_INIT_SP
#pragma DATA_SEG __NEAR_SEG STARTUP_DATA /* _startupData can be accessed using 16 bit accesses. */
/* This is needed because it contains the stack top, and without stack, far data cannot be accessed */
/*lint -e1065 */
struct _tagStartup _startupData;  /*   read-only: */
                                  /*   _startupData is allocated in ROM and */
                                  /*   initialized by the linker */
/*lint +e1065 */
#pragma DATA_SEG DEFAULT
#endif /* __ONLY_INIT_SP */

#if defined(FAR_DATA) && (!defined(__HCS12X__) || defined(__BANKED_COPY_DOWN))
#include "non_bank.sgm"
/* the init function must be in non banked memory if banked variables are used */
/* because _SET_PAGE is called, which may change any page register. */

__EXTERN_C void _SET_PAGE(void);  /* the inline assembler needs a prototype */
                                  /* this is a runtime routine with a special */
                                  /* calling convention, do not use it in c code! */
#else
#include "default.sgm"
#endif /* defined(FAR_DATA) && (!defined(__HCS12X__) || defined(__BANKED_COPY_DOWN)) */


/* define value and bits for Windef Register */
#ifdef HC812A4
#define WINDEF (*(volatile unsigned char*) 0x37)
#if defined( __BANKED__) || defined(__LARGE__) || defined(__PPAGE__)
#define __ENABLE_PPAGE__ 0x40
#else
#define __ENABLE_PPAGE__ 0x0
#endif
#if defined(__DPAGE__)
#define __ENABLE_DPAGE__ 0x80
#else
#define __ENABLE_DPAGE__ 0x0
#endif
#if defined(__EPAGE__)
#define __ENABLE_EPAGE__ 0x20
#else
#define __ENABLE_EPAGE__ 0x0
#endif
#endif  /* HC812A4 */

#ifdef _HCS12_SERIALMON
      /* for Monitor based software remap the RAM & EEPROM to adhere
         to EB386. Edit RAM and EEPROM sections in PRM file to match these. */
#define ___INITRM      (*(volatile unsigned char *) 0x0010)
#define ___INITRG      (*(volatile unsigned char *) 0x0011)
#define ___INITEE      (*(volatile unsigned char *) 0x0012)
#endif

#if defined(_DO_FEED_COP_)
#define __FEED_COP_IN_HLI()  } __asm movb #0x55, _COP_RST_ADR; __asm movb #0xAA, _COP_RST_ADR; __asm {
#else
#define __FEED_COP_IN_HLI() /* do nothing */
#endif

#ifndef __ONLY_INIT_SP
#if (!defined(FAR_DATA) || defined(__HCS12X__)) && (defined( __BANKED__) || defined(__LARGE__) || defined(__BANKED_COPY_DOWN))
static void __far Init(void)
#else
static void Init(void)
#endif
 {
/* purpose:     1) zero out RAM-areas where data is allocated   */
/*              2) copy initialization data from ROM to RAM     */
/*              3) call global constructors in C++              */
/*   called from: _Startup, LibInits                            */
   __asm {
ZeroOut:
#if defined(__HIWARE_OBJECT_FILE_FORMAT__) && defined(__LARGE__)
             LDX   _startupData.pZeroOut:1  ; in the large memory model in the HIWARE format, pZeroOut is a 24 bit pointer
#else
             LDX   _startupData.pZeroOut    ; *pZeroOut
#endif
             LDY   _startupData.nofZeroOuts ; nofZeroOuts
             BEQ   CopyDown                 ; if nothing to zero out

NextZeroOut: PSHY                           ; save nofZeroOuts
#if defined(FAR_DATA)
             LDAB  1,X+                     ; load page of destination address
             LDY   2,X+                     ; load offset of destination address
#if defined(__HCS12X__)
             STAB  __GPAGE_ADR__
#else /* defined(__HCS12X__) */
             __PIC_JSR(_SET_PAGE)           ; sets the page in the correct page register
#endif /* defined(__HCS12X__) */
#else   /* FAR_DATA */
             LDY   2,X+                     ; start address and advance *pZeroOut (X = X+4)
#endif  /* FAR_DATA */

#if defined(__HCS12X__) && defined(FAR_DATA)
             PSHX
             LDX   0,X                      ; byte count
#if defined(__OPTIMIZE_FOR_SIZE__)
             CLRA
NextWord:    GSTAA 1,Y+                     ; clear memory byte
             __FEED_COP_IN_HLI()            ; feed the COP if necessary /*lint !e505 !e522 asm code */
             DBNE  X, NextWord              ; dec byte count
#else
             LDD #0
             LSRX
             BEQ   LoopClrW1                ; do we copy more than 1 byte?
NextWord:    GSTD 2,Y+                      ; clear memory word
             __FEED_COP_IN_HLI()            ; feed the COP if necessary /*lint !e505 !e522 asm code */
             DBNE  X, NextWord              ; dec word count
LoopClrW1:
             BCC   LastClr                  ; handle last byte
             GSTAA 1,Y+											; handle last byte
LastClr:
#endif
             PULX
             LEAX  2,X
#elif defined(__OPTIMIZE_FOR_SIZE__)               /* -os, default */
             LDD   2,X+                     ; byte count
NextWord:    CLR   1,Y+                     ; clear memory byte
             __FEED_COP_IN_HLI()            ; feed the COP if necessary /*lint !e505 !e522 asm code */
             DBNE  D, NextWord              ; dec byte count
#else /* __OPTIMIZE_FOR_TIME__ */
             LDD   2,X+                     ; byte count
             LSRD                           ; /2 and save bit 0 in the carry
             BEQ   LoopClrW1                ; do we copy more than 1 byte?
             PSHX
             LDX   #0
LoopClrW:    STX   2,Y+                     ; Word-Clear
             __FEED_COP_IN_HLI()            ; feed the COP if necessary /*lint !e505 !e522 asm code */
             DBNE  D, LoopClrW
             PULX
LoopClrW1:
             BCC   LastClr                  ; handle last byte
             CLR   1,Y+
LastClr:
#endif /* __OPTIMIZE_FOR_SIZE__/__OPTIMIZE_FOR_TIME__ */
             PULY                           ; restore nofZeroOuts
             DEY                            ; dec nofZeroOuts
             BNE  NextZeroOut
CopyDown:
#if defined(__BANKED_COPY_DOWN)
             LDAA  _startupData.toCopyDownBeg:0 ; get PAGE address of .copy section
             STAA	 __PPAGE_ADR__          ; set PPAGE address
             LDX   _startupData.toCopyDownBeg:1 ; load address of copy down desc.
#elif defined(__ELF_OBJECT_FILE_FORMAT__)
             LDX   _startupData.toCopyDownBeg ; load address of copy down desc.
#else
             LDX   _startupData.toCopyDownBeg:2 ; load address of copy down desc.
#endif
NextBlock:
             LDD   2,X+                     ; size of init-data -> D
             BEQ   funcInits                ; end of copy down desc.
#ifdef FAR_DATA
             PSHD                           ; save counter
             LDAB  1,X+                     ; load destination page
             LDY   2,X+                     ; destination address
#if defined(__HCS12X__)
             STAB  __GPAGE_ADR__
#else  /* __HCS12X__ */
             __PIC_JSR(_SET_PAGE)           ; sets the destinations page register
#endif /* __HCS12X__ */
             PULD                           ; restore counter
#else  /* FAR_DATA */
             LDY   2,X+                     ; load destination address
#endif /* FAR_DATA */

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩美女视频在线| 色狠狠色狠狠综合| 亚洲精品五月天| 欧美电影免费观看高清完整版在| 国产一区欧美一区| 天天做天天摸天天爽国产一区 | 国产成人综合视频| 亚洲一区中文在线| 国产精品亲子乱子伦xxxx裸| 日韩免费一区二区三区在线播放| 成人99免费视频| 另类小说综合欧美亚洲| 亚洲香蕉伊在人在线观| 国产欧美一区二区精品婷婷 | 日韩欧美卡一卡二| 欧美日韩免费观看一区三区| 99久久精品国产毛片| 国产成人99久久亚洲综合精品| 美女高潮久久久| 午夜精品久久久久久久久久 | 久久精品国产99国产| 午夜日韩在线观看| 亚洲伊人伊色伊影伊综合网| 中文字幕日韩精品一区| 国产精品免费丝袜| 欧美国产成人在线| 亚洲欧美中日韩| 一区二区三区日韩欧美精品| 亚洲激情自拍偷拍| 亚洲激情图片小说视频| 亚洲色图视频免费播放| 亚洲精品国产品国语在线app| 亚洲男女毛片无遮挡| 亚洲国产欧美在线| 久久精品国产免费| 国产一区二区免费在线| 99麻豆久久久国产精品免费| 色先锋aa成人| 日韩三级在线免费观看| 久久婷婷国产综合精品青草| 久久久久国产精品免费免费搜索| 亚洲欧洲日韩av| 婷婷成人综合网| 国产黄色成人av| 一本色道综合亚洲| 在线播放中文字幕一区| 久久久另类综合| 亚洲国产精品视频| 丁香激情综合五月| 91精品国产综合久久国产大片| 国产肉丝袜一区二区| 亚洲国产视频一区| 丰满白嫩尤物一区二区| 欧美一区二区三区影视| 亚洲欧美一区二区三区极速播放 | 国产99久久久久久免费看农村| 欧美午夜精品久久久久久超碰| 久久久久久久精| 日韩精品高清不卡| 色吧成人激情小说| 国产精品免费丝袜| 国产精品亚洲а∨天堂免在线| 欧美色区777第一页| 中文字幕一区二区不卡 | 欧美日韩一区二区三区在线| 国产午夜精品理论片a级大结局| 午夜精品视频在线观看| 欧美自拍偷拍一区| 亚洲欧美区自拍先锋| 99久久精品国产毛片| 亚洲一区二区中文在线| 精品国产乱码久久久久久夜甘婷婷| 99亚偷拍自图区亚洲| 亚洲图片欧美视频| 不卡欧美aaaaa| 色综合久久久久| 亚洲日本护士毛茸茸| 91污片在线观看| 樱桃国产成人精品视频| 在线观看视频91| 日本三级亚洲精品| 精品欧美乱码久久久久久1区2区| 日韩电影在线观看电影| 欧美一区二区精品在线| 久久99精品国产91久久来源| 久久久99久久| 国产精品66部| 亚洲免费观看高清完整版在线观看| av不卡在线观看| 夜色激情一区二区| 欧美不卡一区二区三区| jlzzjlzz国产精品久久| 午夜精品福利在线| 国产亚洲短视频| 欧美日韩精品三区| 国产乱妇无码大片在线观看| 国产精品网站一区| 欧美乱熟臀69xxxxxx| 国产一区二区三区在线观看精品 | 日本中文一区二区三区| 久久久久88色偷偷免费| 欧美亚洲尤物久久| 国产精品99久久久久| 亚洲国产视频一区二区| 中文字幕视频一区| 精品国产精品网麻豆系列| 在线亚洲一区二区| 东方aⅴ免费观看久久av| 奇米四色…亚洲| 亚洲综合视频网| 综合欧美亚洲日本| 久久久久久久久蜜桃| 欧美精品高清视频| 欧美猛男男办公室激情| www.欧美日韩国产在线| 亚洲综合一二区| 亚洲精品菠萝久久久久久久| 久久久久久免费| 欧美大片顶级少妇| 日韩一卡二卡三卡| 91精品国产美女浴室洗澡无遮挡| 一本大道久久a久久综合| 成人的网站免费观看| 国产精品一区二区在线播放 | 91在线视频官网| 丰满亚洲少妇av| 94-欧美-setu| 一本色道久久综合亚洲91| 91年精品国产| 色婷婷av一区二区三区软件| 色婷婷综合激情| 在线一区二区视频| 欧美精选一区二区| 日韩一区二区三区电影| 久久丝袜美腿综合| 国产精品视频免费| 一区二区三区中文免费| 亚洲成人精品在线观看| 日本欧美大码aⅴ在线播放| 久久99久久99小草精品免视看| 久久99精品久久只有精品| 国产成人亚洲综合a∨婷婷图片 | 另类小说欧美激情| 国产成人在线免费观看| 91麻豆国产精品久久| 欧美日韩亚洲综合在线| 日韩一区二区三区视频在线观看| 2020国产精品自拍| 亚洲黄色在线视频| 天天影视网天天综合色在线播放| 蜜臀av一区二区三区| aa级大片欧美| 日韩一区二区视频在线观看| 日本一区二区三级电影在线观看 | 中文字幕欧美日本乱码一线二线| 亚洲精品久久久久久国产精华液| 日韩avvvv在线播放| 色婷婷久久久综合中文字幕 | 欧美精品在线视频| 国产精品国产自产拍高清av王其| 午夜国产精品影院在线观看| 国产99精品国产| 精品成人私密视频| 五月天婷婷综合| 在线免费视频一区二区| 国产三级一区二区| 国精品**一区二区三区在线蜜桃| 欧美三级三级三级爽爽爽| 中文字幕av资源一区| 蜜桃一区二区三区四区| 风间由美一区二区av101| 亚洲精品一区二区精华| 久久99久久久久久久久久久| 欧美在线视频不卡| 亚洲综合在线五月| 欧美性欧美巨大黑白大战| 亚洲美女视频在线| 不卡av电影在线播放| 26uuu亚洲综合色| 国产精品 欧美精品| 国产精品美女一区二区三区| 国产麻豆一精品一av一免费| 精品久久国产字幕高潮| 国产在线播放一区二区三区| 久久午夜色播影院免费高清| 国产精品自拍一区| 中文字幕日韩一区| 精品1区2区3区| 精品一区二区三区在线播放 | 国产精品狼人久久影院观看方式| 粉嫩一区二区三区在线看| 亚洲天堂免费看| 欧美日韩激情一区二区三区| 偷拍与自拍一区| 国产日韩欧美制服另类| 欧美在线啊v一区| 国产一区福利在线| 一区二区三区高清| 精品对白一区国产伦| av成人免费在线|