I'm still stuck on this.
I don't know where to put the audio file. I get no error messages in Chrome Inspect but the audio just does not play.
My code looks like this:
.controller( 'SoundCtrl', function( $scope, $timeout ) {
$scope.sound_on = false;
var media = new Media( '/android_asset/www/'+'100bpm.wav');
$scope.soundPlayer = function() {
console.log( "in soundPlayer" );
if( $scope.sound_on == false ) {
$scope.sound_on = true;
media.setVolume( '1.0' );
media.play();
console.log( "sound on" );
console.log( media );
/*$timeout(function(){
$scope.sound_on=false;
console.log("should change");
}, 12600);*/
} else {
media.stop();
$scope.sound_on = false;
console.log( "sound off" );
}
}
});