Implement left and right justifications for 24 to 32 bit PCM encoding

This commit is contained in:
Reinhard Panhuber
2021-02-18 19:25:08 +01:00
parent 681cfd0bf2
commit c098da9803
2 changed files with 20 additions and 2 deletions

View File

@@ -203,6 +203,18 @@
#endif
// In case PCM encoding/decoding of 24 into 32 bits, the adjustment needs to be defined
#define CFG_TUD_AUDIO_LEFT_JUSTIFIED
#define CFG_TUD_AUDIO_RIGHT_JUSTIFIED
#ifndef CFG_TUD_AUDIO_JUSTIFICATION_RX
#define CFG_TUD_AUDIO_JUSTIFICATION_RX CFG_TUD_AUDIO_LEFT_JUSTIFIED
#endif
#ifndef CFG_TUD_AUDIO_JUSTIFICATION_TX
#define CFG_TUD_AUDIO_JUSTIFICATION_TX CFG_TUD_AUDIO_LEFT_JUSTIFIED
#endif
//static_assert(sizeof(tud_audio_desc_lengths) != CFG_TUD_AUDIO, "Supply audio function descriptor pack length!");
// Supported types of this driver: