NoInterrupts()

From Microduino Wiki
Jump to: navigation, search

noInterrupts()

  • Description

Forbid the interrupt (re enable interrupts()). Interrupt allows some important tasks run in the background, and it is able to interrupt by default. When forbidding the interrupt, some functions won’t be able to work, and information received during the communication maybe lost.

Interrupt can slightly affect the timing code, and it will also lose effect in specified code.

  • Parameter

No

  • Return

No

  • Example

void setup()
 
void loop()
{
noInterrupts();
//put key and time-sensitive code here 
  interrupts();
//write other code here 
}

[Return to Arduino Syntax Manual]