Added code for blown frame detection.