diff --git a/src/03-led-controller/main.c b/src/03-led-controller/main.c index fb5bf33..b34d646 100644 --- a/src/03-led-controller/main.c +++ b/src/03-led-controller/main.c @@ -54,12 +54,13 @@ int main(void) return 1; } - // 2. Add button to epoll + // Add buttons to epoll struct epoll_event ev[NBR_BTN]; - // CRITICAL: Sysfs GPIOs use EPOLLPRI (priority data) and EPOLLERR, not EPOLLIN! - + // EPOLLIN is working well as EPOLLPRI (which is more used for priority data) + // EPOLLERR is used to detect if there is an error + // EPOLLET is for edge triggered mode (non-blocking) for(int i=0; i