Skip to content

Commit d3fa3cd

Browse files
committed
Adjsut blackout time.
1 parent ade8a19 commit d3fa3cd

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

examples/device/audio_4_channel_mic/src/tusb_config.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,12 +126,12 @@ extern "C" {
126126
#define CFG_TUD_AUDIO_ENABLE_TYPE_I_ENCODING 1
127127
#define CFG_TUD_AUDIO_FUNC_1_CHANNEL_PER_FIFO_TX 2 // One I2S stream contains two channels, each stream is saved within one support FIFO - this value is currently fixed, the driver does not support a changing value
128128
#define CFG_TUD_AUDIO_FUNC_1_N_TX_SUPP_SW_FIFO (CFG_TUD_AUDIO_FUNC_1_N_CHANNELS_TX / CFG_TUD_AUDIO_FUNC_1_CHANNEL_PER_FIFO_TX)
129-
#define CFG_TUD_AUDIO_FUNC_1_TX_SUPP_SW_FIFO_SZ 4 * (CFG_TUD_AUDIO_EP_SZ_IN / CFG_TUD_AUDIO_FUNC_1_N_TX_SUPP_SW_FIFO)
129+
#define CFG_TUD_AUDIO_FUNC_1_TX_SUPP_SW_FIFO_SZ 4 * (CFG_TUD_AUDIO_EP_SZ_IN / CFG_TUD_AUDIO_FUNC_1_N_TX_SUPP_SW_FIFO) // Minimum 4*EP size is needed for flow control
130130

131131
#else
132132

133133
#define CFG_TUD_AUDIO_FUNC_1_EP_IN_SZ_MAX CFG_TUD_AUDIO_EP_SZ_IN
134-
#define CFG_TUD_AUDIO_FUNC_1_EP_IN_SW_BUF_SZ 4 * CFG_TUD_AUDIO_EP_SZ_IN
134+
#define CFG_TUD_AUDIO_FUNC_1_EP_IN_SW_BUF_SZ 4 * CFG_TUD_AUDIO_EP_SZ_IN // Minimum 4*EP size is needed for flow control
135135

136136
#endif
137137

src/class/audio/audio_device.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2645,11 +2645,11 @@ static uint16_t audiod_tx_packet_size(const uint16_t* norminal_size, uint16_t da
26452645
packet_size = norminal_size[2];
26462646
if(norminal_size[0] == norminal_size[1])
26472647
{
2648-
// nav = INT(nav) + 1
2649-
ctrl_blackout = 2;
2648+
// nav > INT(nav), eg. 44.1k, 88.2k
2649+
ctrl_blackout = 0;
26502650
} else
26512651
{
2652-
// nav = INT(nav)
2652+
// nav = INT(nav), eg. 48k, 96k
26532653
ctrl_blackout = 10;
26542654
}
26552655
} else

0 commit comments

Comments
 (0)