Added onScanStart/onScanEnd function support

Enables the option to add visualization calls while script listens & processes buffer