Continuesly app run in background

I want to play an audio continuesly when app is on background mode. I did the following thing. But it is not working. Why?

constructor(
  private backgroundMode: BackgroundMode,
  private nativeAudio: NativeAudio) {
  this.backgroundMode.on("activate").subscribe(() => {
	this.nativeAudio.preloadComplex('newAlarm', 'assets/media/alert.MP3', 1, 1, 0);
	setInterval(this.alarm, 10000);
  });
  this.backgroundMode.enable();
}

alarm = () => {
  this.nativeAudio.play('newHire');
}

I did this like the examples in this link.

https://www.javascripttuts.com/mixing-local-notifications-and-background-geolocation-in-ionic/