Skip to content

Commit

Permalink
Fix CI.
Browse files Browse the repository at this point in the history
  • Loading branch information
HiFiPhile committed Nov 19, 2023
1 parent af6ef30 commit 65225c0
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 4 deletions.
1 change: 1 addition & 0 deletions examples/device/uac2_speaker_fb/skip.txt
Expand Up @@ -5,3 +5,4 @@ mcu:SAMD11
mcu:SAME5X
mcu:SAMG
board:stm32l052dap52
family:broadcom_64bit
4 changes: 3 additions & 1 deletion examples/device/uac2_speaker_fb/src/main.c
Expand Up @@ -347,7 +347,9 @@ bool tud_audio_set_itf_cb(uint8_t rhport, tusb_control_request_t const * p_reque

void tud_audio_feedback_params_cb(uint8_t func_id, uint8_t alt_itf, audio_feedback_params_t* feedback_param)
{
// Set feedback methode to fifo counting
(void)func_id;
(void)alt_itf;
// Set feedback method to fifo counting
feedback_param->method = AUDIO_FEEDBACK_METHOD_FIFO_COUNT;
feedback_param->sample_freq = current_sample_rate;
}
Expand Down
6 changes: 3 additions & 3 deletions src/class/audio/audio_device.c
Expand Up @@ -1896,7 +1896,7 @@ static bool audiod_set_interface(uint8_t rhport, tusb_control_request_t const *
{
/* Start with max value to allow quick FIFO filling */
tud_audio_n_fb_set(func_id, audio->feedback.max_value);
/* Initialize the threshhold level to half filled */
/* Initialize the threshold level to half filled */
uint16_t fifo_lvl_thr;
#if CFG_TUD_AUDIO_ENABLE_DECODING
fifo_lvl_thr = tu_fifo_depth(&audio->rx_supp_ff[0]) / 2;
Expand All @@ -1905,8 +1905,8 @@ static bool audiod_set_interface(uint8_t rhport, tusb_control_request_t const *
#endif
audio->feedback.compute.fifo_count.fifo_lvl_thr = fifo_lvl_thr;
audio->feedback.compute.fifo_count.fifo_lvl_avg = ((uint32_t)fifo_lvl_thr) << 16;
uint64_t fb64 = ((uint64_t) fb_param.sample_freq) << 16;
uint32_t nominal = (uint32_t)(fb64 / frame_div);
/* Avoid 64bit division */
uint32_t nominal = ((fb_param.sample_freq / 100) << 16) / (frame_div / 100);
audio->feedback.compute.fifo_count.nom_value = nominal;
audio->feedback.compute.fifo_count.rate_const[0] = (audio->feedback.max_value - nominal) / fifo_lvl_thr;
audio->feedback.compute.fifo_count.rate_const[1] = (nominal - audio->feedback.min_value) / fifo_lvl_thr;
Expand Down
8 changes: 8 additions & 0 deletions src/portable/wch/ch32v307/dcd_usbhs.c
Expand Up @@ -135,6 +135,14 @@ void dcd_remote_wakeup(uint8_t rhport)
(void) rhport;
}

void dcd_sof_enable(uint8_t rhport, bool en)
{
(void) rhport;
(void) en;

// TODO implement later
}

void dcd_edpt0_status_complete(uint8_t rhport, tusb_control_request_t const *request) {
(void)rhport;

Expand Down

0 comments on commit 65225c0

Please sign in to comment.