⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 stddefs.cfg

📁 flash programming STI 5.5.1.4 DCU3
💻 CFG
字号:
###############################################################################
##
## stddefs.cfg : some standard definitions of simulator resources
##
###############################################################################


K = 1024
M = (K*K)

DebugTrapHandlerSize = 1024

proc PlaceDebugTrapHandler segment=$1 {
  memory TRAPHANDLER ((addressof -q (segment))+(sizeof -q (segment))-(DebugTrapHandlerSize)) (DebugTrapHandlerSize) DEBUG
}

## procedure to clear C2 system channel internal memory
proc ST20C2MemoryInit {
  mint = 0x80000000
  trapstart = mint+0x40 

  ## clear all words below trapstart to MOSTNEG INT

  ## only the linker has alias built in, it must not see pokes
  if (((clsymbol alias) != 3)) {
    for (i = mint; i < trapstart; i = i + 4) {
      poke (i) (mint)
    }
  }
}


## procedure to clear C1 system internal memory
proc ST20C1MemoryInit {

  ## clear the  words in system memory to MOSTNEG INT.
  ##  N.B. Leave the first 7 words alone for now as these are
  ##       used by the bootstrap poking code and will be cleared
  ##       explicitly by the bootstrap code 
  ## Not done at link time
  ## only the linker has alias built in, it must not see pokes
  if (((clsymbol alias) != 3)) {
      for (i = 0x8000001c; i < 0x8000003c; i = i + 4) {
      poke (i,0x80000000)
    }
  }
}

## Address and size of available external RAM memory
##

proc c1hw {
  chip ST20C1SIM
  ST20C1MemoryInit  
  bootiptr 0x70000000
  PlaceDebugTrapHandler EXTERNAL
}

proc c1 {
  c1hw
  stack EXTERNAL 
  heap EXTERNAL 
}

proc c2hw_common chipname=$1 {
  chip (chipname)
  ST20C2MemoryInit
  PlaceDebugTrapHandler EXTERNAL
}

proc c2hw {
  c2hw_common "ST20C2SIM"
}

proc c2hw_bank0 {
  c2hw_common "ST20C2SIM_BANK0"
}

proc c2hw_bank1 {
  c2hw_common "ST20C2SIM_BANK1"
}

proc c2_common {
  stack EXTERNAL 
  heap EXTERNAL 
}
proc c2 {
  c2hw
  c2_common
}

proc c2_bank0 {
  c2hw_bank0
  c2_common
}

proc c2_bank1 {
  c2hw_bank1
  c2_common
}

target c1 st20sim "st20sim -q -p c1hw" "reset; c1hw"
target c2 st20sim "st20sim -q -p c2hw" "reset; c2hw"

target c2_bank0 st20sim "st20sim -q -p c2hw_bank0" "reset; c2hw_bank0"
target c2_bank1 st20sim "st20sim -q -p c2hw_bank1" "reset; c2hw_bank1"


⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -