Code Examples
Table D−3. Code to Enable an Interrupt
C2xLP
SETC
INTM
LDP
#0
LACL
IMR
OR
#INTx
SACL
IMR
CLRC
INTM
Table D−4. Code to Clear the IFR Register
C2xLP
;write 1 to clear
SETC
INTM
LDP
#0
SPLK
#0FFFFh,IFR
CLRC
INTM
D.4.3 Context Save/Restore
The C28x automatically saves a number of registers on each interrupt. To per-
form a full context save, some additional code must be added. Table D−5
shows a typical full context save and restore for both processors.
C28x
OR
IER,#INTx
;operation is atomic and
;will not be interrupted.
C28x
;write 0 to clear
AND
IFR,#~INTx
;operation is atomic and
;will not be interrupted
Need help?
Do you have a question about the TMS320C28x and is the answer not in the manual?