Refactored sequencer implementation.
Implemented sequencer callbacks.