-
Notifications
You must be signed in to change notification settings - Fork 29
Open
Description
Hi Ole,
I hope you'll read this after so many years. It's not an issue, just a doubt I can't find an answer to and I don't know how to get in touch directly.
I'm using this library to learn Arduino and I don't fully understand a couple of point in the code for the method read_data() in dht_nonblocking.cpp, specifically the part regarding blocking interrupts.
I do understand how it works but not why it's programmed the way it is:
- Why is a
DHT_interruptobject used to call the functionsnoInterrupt()andinterrupt()through the constructor and destructor? Isn't it the same to just call the functions directly? - Why does the same object need to be declared as
volatile? The class doesn't have any member so what does the qualifier achieve?
Thank you.
Med venlig hilsen.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels