Sega Saturn - Problem to play song from the CD

Hi guys, I'm learning how to code for Saturn... I'm using Jo engine(http://www.jo-engine.org/) everything looks fine... I'm really having progress with my test, however I tried to use the audio library and I can't run the musics from the CD.

This is my test:



This is my function to call the audio from the CD:

///Function for music
void play_music(void)
{
jo_audio_init();
jo_audio_play_cd_track(2, 2, 1);
}

And this is the Wave inside the CD folder:

[​IMG]

I've already tried to get in touch with the guy, but I had no answer... any help with this I would appreciate.
I also read all the documentation and my code looks fine... I just need to fix it to get all the functions working!!! hehe tks guys!
Not sure if this is the issue but from what I can make out between your "Part 2 Video" and picture the audio track is located in the wrong folder. In your "Part 1 Video" the audio track is in the correct folder. Try placing "track1.wav" in the same folder as your Iso/Cue then mount the Cue in a virtual drive and run it in SSF or rip it to Bin/Cue for use with Yabause.

Also make sure the audio is included on the .cue file ...

FILE "sl_coff.iso" BINARY
TRACK 01 MODE1/2048
INDEX 01 00:00:00
POSTGAP 00:02:00
FILE "track1.wav" WAVE
TRACK 02 AUDIO
PREGAP 00:02:00
INDEX 01 00:00:00
Tks for your help bro, I tried what you said but still the same, the weird thing is that I tried with a PCM audio and it worked... I'll do more tests and I post the solution here when I find it.
Stripped down the Audio Demo to force auto play, should work for the moment...

#include <jo/jo.h>

void play_music(void)
{
static int is_cd_playing = 0;

if (!is_cd_playing)
{
jo_audio_play_cd_track(2, 2, 1);
is_cd_playing = 1;
}
}


void jo_main(void)
{
jo_core_init(JO_COLOR_DarkGray);
jo_core_add_callback(play_music);
jo_core_run();
}
I've just found the solution, the problem was not in the code... I took my ISO and my WAV file and I used Sega Cue Maker to prepare the Cue file... then I emulated it in a virtual drive, and it worked! Now I can keep working in my game... thank you man for your help!
Yes, tested the code, works fine. Sometimes it's the little things that get ya.

Good luck with your project! :D

Original thread: https://assemblergames.com/threads/sega-saturn-problem-to-play-song-from-the-cd.62372/