TC1796 can't disable global interrupts

OP #2768352
Hello, using TC1796 microprocessor, can't disable and enable interrupts 
around critical sections of code.

Referring to the Tricore Architecture Volume 1 manual:
The processor is running in User-1. In this mode you should be able to 
disable and enable interrupts.
checked in debugger, register PSW.IO = 0x01, User-1 Mode, "Tasks at this 
level may disable interrupts." (quoting the above manual)

Using the following C code to enable/disable interrupts:
asm volatile ("enable" : : : "memory");
asm volatile ("disable" : : : "memory");
Stepping through these lines of assembler in the debugger, register 
ICR.IE (Global Interrupt Enable) is always set.

Why are global interrupts not being disabled?
Moderator (Company: Titel)
Peter .. wrote:
> Stepping through these lines of assembler in the debugger, register
> ICR.IE (Global Interrupt Enable) is always set.
What debugger do you have?

> Why are global interrupts not being disabled?
Maybe the debugger needs an interrupt itself and so you cannot disable 
global interrupts during debugging...
OP
Using the debugger "Trace32 Powerview for Tricore", ver 
R.2011.06.000032911.

I've been reading up on the Core Debug Controller in the Tricore 
Architecture Volume 1 manual (v1.3).  Ummm, doesn't say anything about 
using an interrupt for debugging.

When I find the solution I'll post it here...
OP
Also checked the TC1796 errata.  Only related issue is CPU_TC.083 
"Interrupt may be taken following DISABLE instruction" where the 
workaround is add a nop after disable.  Checked and already have this in 
my code.

Reply

A question of your own? This thread is over 14 years old. Ask it in a thread of its own – more people read along there, and it gets answered more often and sooner.

Start a new thread

A fix, an addition or feedback on this thread? Then reply here.

Formatting
  • [c]C-Code[/c]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]
  • [[Title]] – link to an article
  • Link to another post: right-click its post ID (#8078628), copy the address, paste it into the text

More about formatting

Post long source code as an attachment, not in the text.

Already registered? Log in

Not shown to anyone. We send you a link; your post appears once you confirm it there.

By submitting you create a free account and accept the terms of use.