mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-02-21 03:40:47 +00:00
example: update le_audio_demo_util_source + mod_player for hxcmod update
This commit is contained in:
parent
8201da8822
commit
036e10079a
@ -47,6 +47,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
|
||||
- HID Host: omit Report ID in Set/Get Report and send report for report id == HID_REPORT_ID_UNDEFINED
|
||||
- POSIX: clear run loop exit flag
|
||||
- btstack_util: skip whitespace in btstack_atoi
|
||||
- hxcmod-player: update to fix GCC 11 warnings
|
||||
- esp32: use synchronous VHCI API with newer ESP32 variants (esp32, -c3, and -s3 use asynchronous API)
|
||||
|
||||
### Changed
|
||||
|
@ -174,7 +174,7 @@ static void le_audio_demo_source_setup_mod_player(void){
|
||||
btstack_assert(le_audio_demo_source_hxcmod_initialized != 0);
|
||||
}
|
||||
hxcmod_unload(&le_audio_demo_source_hxcmod_context);
|
||||
hxcmod_setcfg(&le_audio_demo_source_hxcmod_context, le_audio_demo_source_sampling_frequency_hz, 16, 1, 1, 1);
|
||||
hxcmod_setcfg(&le_audio_demo_source_hxcmod_context, le_audio_demo_source_sampling_frequency_hz, 1, 1);
|
||||
hxcmod_load(&le_audio_demo_source_hxcmod_context, (void *) &mod_data, mod_len);
|
||||
}
|
||||
|
||||
@ -260,7 +260,7 @@ void le_audio_demo_util_source_generate_iso_frame(le_audio_demo_source_generator
|
||||
break;
|
||||
case AUDIO_SOURCE_MODPLAYER:
|
||||
// mod player configured for stereo
|
||||
hxcmod_fillbuffer(&le_audio_demo_source_hxcmod_context, (unsigned short *) le_audio_demo_source_pcm, le_audio_demo_source_num_samples_per_frame, &le_audio_demo_source_hxcmod_trkbuf);
|
||||
hxcmod_fillbuffer(&le_audio_demo_source_hxcmod_context, le_audio_demo_source_pcm, le_audio_demo_source_num_samples_per_frame, &le_audio_demo_source_hxcmod_trkbuf);
|
||||
// stereo -> mono
|
||||
if (le_audio_demo_source_num_channels == 1) {
|
||||
uint16_t i;
|
||||
|
@ -49,7 +49,7 @@
|
||||
static modcontext mod_context;
|
||||
|
||||
static void audio_playback(int16_t * buffer, uint16_t num_samples){
|
||||
hxcmod_fillbuffer(&mod_context, (unsigned short *) buffer, num_samples, NULL);
|
||||
hxcmod_fillbuffer(&mod_context, buffer, num_samples, NULL);
|
||||
}
|
||||
|
||||
int btstack_main(int argc, const char * argv[]);
|
||||
@ -61,7 +61,7 @@ int btstack_main(int argc, const char * argv[]){
|
||||
int hxcmod_initialized = hxcmod_init(&mod_context);
|
||||
if (!hxcmod_initialized) return 10;
|
||||
|
||||
hxcmod_setcfg(&mod_context, 44100, 16, 1, 1, 1);
|
||||
hxcmod_setcfg(&mod_context, 44100, 1, 1);
|
||||
hxcmod_load(&mod_context, (void *) &mod_data, mod_len);
|
||||
|
||||
// setup audio playback
|
||||
|
Loading…
x
Reference in New Issue
Block a user