Added functionality for interrupt