Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wav on 16 bit format. #10

Open
gioreva opened this issue Sep 18, 2020 · 0 comments
Open

wav on 16 bit format. #10

gioreva opened this issue Sep 18, 2020 · 0 comments

Comments

@gioreva
Copy link

gioreva commented Sep 18, 2020

I am trying to change to play, 16bit wav, which are more readily available.

I can not understand why crashes after the first buffer and stops forward.

void Audio_Handler (void){
  if (__SampleIndex < __NumberOfSamples - 1)  {
    analogWrite(A0, __WavSamples[__SampleIndex+=2]<<2);
    TC5->COUNT16.INTFLAG.bit.MC0 = 1;      // Clear the interrupt
  }  else  {
    __SampleIndex = 0;
    TC5->COUNT16.INTFLAG.bit.MC0 = 1;
	}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant