EIMSK or how to disable/enable interrupts on Feather (nrf528

Please tell us which board you are using.
For CircuitPython issues, ask in the Adafruit CircuitPython forum.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
kotarak
 
Posts: 5
Joined: Fri Apr 02, 2021 11:40 am

EIMSK or how to disable/enable interrupts on Feather (nrf528

Post by kotarak »

Hey guys,
looking a way to write in the interrupt control register in order to temporary stop and then re-instate an interrupt without using attachInterrupt / detachInterrupt every time.

On the AVR chips this is usually done with EIMSK by masking bits like EIMSK &= 0b00000010; to disable it for example or EIMSK |= 0b00000001; to re-enable.

Is it possible to use such method on Feather Sense (nRF52840)?
the compiler doesn't recognize EIMSK.

User avatar
jevada
 
Posts: 194
Joined: Fri Dec 15, 2017 5:29 am

Re: EIMSK or how to disable/enable interrupts on Feather (nr

Post by jevada »

The standard Arduino way is interrupts() and noInterrupts(), see https://www.arduino.cc/reference/en/lan ... nterrupts/

Locked
Please be positive and constructive with your questions and comments.

Return to “Feather - Adafruit's lightweight platform”