This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

[nRF52832] Unable to configure InterruptIn + PullDown on P0_1

Hello !

I am currently working on a custom board on which I don't need 32.768kHz. I want to use P0_1 as an interruption pin connected to a pushbutton. The button is connected to VCC so when it's pressed it imposes a high logical level on the GPIO. I configured configured the GPIO to enable the internal pull-down so the low logical level is supposed to be forced when pushbutton is not pressed.

bool pressed = false;
 
void pushbutton1_handler( void )
{
   pressed = true;
}
 
InterruptIn bp1( P0_1 );
 
int main( void )
{
   bp1.rise( &pushbutton1_handler );
   bp1.mode( PullDown );
 
   while(1) {
 
      if( pressed == true ) {
         LOG("pressed\r\n");
         pressed = false;
      }
   }
}

I run this code and measure the voltage on P0_1, which is supposed to be grounded, but I measure 3.3V

Is there a known issue related to this situation ?

Thanks

Related