What Is The Etymology of the Terms Level-Trigger and Edge-Trigger?

Problem scenario
You have read about level-trigger and edge-trigger notification mechanisms in Linux. Why are they called level-trigger and edge-trigger? Where do they get their names?

Answer
Electronics and processing electric signals. Edges represent changes to a state. A level state represents the lack of a change. Here is a diagram:

This answer was adapted from the following postings:
https://hackernoon.com/photos/QdWX77c6s5Skk99abuNLlG6AEZZ2-9w23y8s
http://venkateshabbarapu.blogspot.com/2013/03/edge-triggered-vs-level-triggered.html

FFR
Notification mechanisms are components of input and output in Linux. There are two main types of notification mechanisms in this context.

A level-triggered notification is comes from a file descriptor that "is considered to be ready if it is possible to perform an I/O system call without blocking." (Taken from page 1329 of The Linux Programming Interface.)

An edge-triggered notification is a notification that "is provided if there is I/O activity (e.g., new input) on a file descriptor since it was last monitored." (Taken from page 1329 of The Linux Programming Interface.)

Level-triggered notifications are used by the select and poll system calls (according to page 1329 of The Linux Programming Interface). LT notifications are also used by the epoll "I/O event notification facility" (as taken from the man page for epoll).

Edge-tiggered notifications are used by signal-drive I/O and the epoll "I/O event notification facility" (as taken from the man page for epoll) in Linux (according to page 1329 of The Linux Programming Interface).

Leave a comment

Your email address will not be published. Required fields are marked *