QE128 vs Interrupt Vector Redirection

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

QE128 vs Interrupt Vector Redirection

1,514 次查看
pbouf
Contributor I

The HCS08 Reference Manual specifies (HCS08RMV1.pdf section 4.5.5) that the interrupt vector table is relocated to a lower memory location (just below the protected FLASH area) when a region of FLASH is protected.

 

I know this applies to the QE8 but does it also apply to the QE64 and QE128 ? The MC9S08QE128RM.pdf document does not mention the relocation of the interrupt vector table.

 

Pierre

标签 (1)
0 项奖励
回复
3 回复数

568 次查看
tonyp
Senior Contributor II

No, QE64, QE96, and QE128 (that is, all the MMU versions) do not have vector redirection.

0 项奖励
回复

568 次查看
pbouf
Contributor I

Does anyone have a suggestion on how I can managed to use interrupts in my I2C bootloader and also in the application code ?

 

 

0 项奖励
回复

568 次查看
tonyp
Senior Contributor II

Just because there is no automatic vector redirection doesn't mean you can't emulate it yourself.

 

For each vector you'll have to add code like the example below:

 

;in your application

 

RedirectedVswi  dw SwiHandler

 

;in your bootloader code

ToSWI brset  BOOTMODE.,Flags,LocalSWI

      lda    RedirectedVswi+1

      psha

      lda    RedirectedVswi

      psha

      rts

 

LocalSWI

               ...

               rti

 

; in actual vector area (in bootloader)

Vswi dw ToSWI

 

P.S. Just edited to show how to work with two ISRs depending on which code is running.  BOOTMODE. flag should be set in bootmode and cleared in application.  Flags should be shared by both codes.

 

0 项奖励
回复