programming manually Breakpoint with PC9S12XDP512

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

programming manually Breakpoint with PC9S12XDP512

ソリューションへジャンプ
2,065件の閲覧回数
JNo
Contributor I

Hello,

 

I try to program an internal breakpoint in 68hcs12xDP512 without success.

I use BDI_access tool that can set only registers.

 

My Way is the following:

Set register DBGC1 (0x0020) to 0x99 in order to select  comparator B  // select break point     
Set register DBGBCTL (0x0028) to  0x81  in order to arm and validate equal comparison  // breakpoint classification
Set register DBGBA   (0x0029) to  0x7F  // breakpoint adress H      
Set register DBGBA   (0x002A) to  0xC0  // breakpoint adress M      
Set register DBGBA   (0x002B) to  0xC0   // breakpoint adress L     

 

When the program running and reach 0x7FC0C0, the microcontroller continue execution without breaking on my breakpoint.

 

I check with orther tool, the values of registers are correcly set.

 

Somebody have an idea on this problem ?


          

ラベル(1)
0 件の賞賛
返信
1 解決策
1,007件の閲覧回数
DPB
NXP Employee
NXP Employee

Hello JNo

 

It is important to first configure the breakpoint registers before setting the ARM bit.

Thus write DBGC1 first to 0x19 before writing to the other registers.

Then configure the other registers.

Then write DBGC1 to 0x99 to arm the module.

 

Also, to generate a breakpoint at an opcode address DBGBCTL should contain 0x31.

 

DPB 

元の投稿で解決策を見る

0 件の賞賛
返信
2 返答(返信)
1,008件の閲覧回数
DPB
NXP Employee
NXP Employee

Hello JNo

 

It is important to first configure the breakpoint registers before setting the ARM bit.

Thus write DBGC1 first to 0x19 before writing to the other registers.

Then configure the other registers.

Then write DBGC1 to 0x99 to arm the module.

 

Also, to generate a breakpoint at an opcode address DBGBCTL should contain 0x31.

 

DPB 

0 件の賞賛
返信
1,007件の閲覧回数
JNo
Contributor I

Thank you very much DPB.

Your solution works fine.

 

JNo

0 件の賞賛
返信