Students implement a novel synchronization primitive, the
orientation event, which allows multiple processes to block
until the mobile device has been put into a particular orien-
tation. For example, a process can block until the phone is
placed face down on a table. To accomplish this, they rst
write a user space daemon which reads device orientation
through a standard Android hardware abstraction library,
and then passes the data into the kernel through a new
system call. The orientation event interface is implemented
as a set of three new system calls: orientevt_open, ori-
entevt_close, and orientevt_wait. The daemon process
passing device orientation into the kernel functions as the
signal which wakes up any blocked process. Students test
this new interface by writing several small test programs.
Each test program forks multiple children, and each child
process blocks on an orientation event opened by its parent.
When the device is moved within the range of the desired
orientation, all child processes should be unblocked.