Interrupt from sleep mode


i have arduino uno connected breadboard on pin #3 , 10k resistor , 3.3v pin.

i installed button in between them can represent break in connection fire interrupt.
trouble button not seem fire interrupt @ all. if remove 3.3v wire floats on pin #3 wakes up.
any ideas why cannot seem recognize break in connection?




sketch attached

you need switch pin ground if using pull-up resistor, not break link pull-up.

the point avoid pin floating ever, since isn't defined if floating, behaviour unpredicatable.

so pin 3 connected 5v via resistor, add button between pin 3 , gnd.

you lose resistor , declare pin internal pull-up enabled:
code: [select]

void setup ()
{
  pinmode (3, input_pullup) ;
  ...
}


Arduino Forum > Using Arduino > General Electronics > Interrupt from sleep mode


arduino

Comments

Popular posts from this blog

Error: ‘for’ loop initial declarations are only allowed in C99 or C11 mode - Raspberry Pi Forums

class MPU6050 has no member named begin

missing filename after '-o'