目录
UCB_DBG_ORIG and UCB_DBG_COPY Content
Introduction
TC3xx中,Debug interface的配置在UCB_DBG_ORIG (UCB18) 中,Debug的使能与否主要由PROCONDBG寄存器决定。此UCB为调试接口配置密码保护。
• Gate 1
− 通过OCDS模块控制对TriCore™调试的访问。
• Gate 2
− 通过DMU模块控制对TriCore™调试的访问。
• Gates 3 and 4
− 直接由HSM控制。
− 通过这两个门,HSM可以锁定对Host CPU的调试访问权限,也可以关闭HSM自身的调试支持。
− 锁定机制由 UCB_HSM_ORIG 和 UCB_HSM_COPY控制。
UCB_DBG_ORIG and UCB_DBG_COPY Content
The UCB_DBG (ORIG and COPY) contain the user defined debug protection. It is protected with the password PW0 to PW7. The protection configuration is transferred into the register DMU_HF_PROCONDBG.
使用Debug Password 保护调试接口设置
通过UCB_DBG (PROCONDBG)寄存器锁定调试接口
– 设置 Bit 0 (OCDSDIS)
- 0 = OCDS not locked
- 1 = OCDS locked → Needs to be set to disable debug facilities
– 设置 Bit 1 (DBGIFLCK)
- 0 = Debug interface not locked → In case OCDSDIS == 1: SSW* does not automatically unlock debug interface even if correct password was supplied → User has to perform “disable protection” command sequence in Host application code
- 1 = Debug interface locked → In case OCDSDIS == 1: SSW automatically unlocks debug interface if correct password was supplied
– 设置 debug password保护
通过正确的debug password来解锁
项目硬件接口保护方案
hexview
如下图所示为位置0xAF402400的ucb_dbg_origin的hex内容。
Lock using UDE
UCB_PFLASH configuration for flash read protection through Memtool
Unlock using UDE
Lock using Lauterbach
Unlock using Lauterbach