Hello! I'm trying to use the PCF8523 SQ pin on the data logging shield to generate an interrupt to wake up my UNO, I currently have the SQ pin connected to a digital pin as an input. It says in the tutorial that "The output is open drain so a pullup (either physical resistor or enabled in software)."
Can someone please elaborate on either options (where does the physical resistor go, or how can the pullup be enabled in software)? What are the pro's and con's for each?
Thank you!
Pull-Up Options for Alarm Using Data Logging Shield RTC
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
- schum
- Posts: 6
- Joined: Wed Feb 23, 2022 11:42 pm
- adafruit_support_bill
- Posts: 88092
- Joined: Sat Feb 07, 2009 10:11 am
Re: Pull-Up Options for Alarm Using Data Logging Shield RTC
The simplest way is to enable the internal pullup on your interrupt pin by setting it to INPUT_PULLUP via the PinMode command:
https://www.arduino.cc/en/Reference/PinMode
Then attach the interrupt via the AttachInterupt command.
https://www.arduino.cc/reference/en/lan ... interrupt/
This requires no additional components. You can just connect the SQ pin to the interrupt pin.
(Available interrupt pins on the UNO are pins 2 and 3)
https://www.arduino.cc/en/Reference/PinMode
Then attach the interrupt via the AttachInterupt command.
https://www.arduino.cc/reference/en/lan ... interrupt/
This requires no additional components. You can just connect the SQ pin to the interrupt pin.
(Available interrupt pins on the UNO are pins 2 and 3)
- schum
- Posts: 6
- Joined: Wed Feb 23, 2022 11:42 pm
Re: Pull-Up Options for Alarm Using Data Logging Shield RTC
I will try that and report back, thanks again!
Please be positive and constructive with your questions and comments.