smartdevicelink / sdl_core

SmartDeviceLink In-Vehicle Software and Sample HMI
BSD 3-Clause "New" or "Revised" License
241 stars 245 forks source link

Microphone format not set, settings from PerformAudioPassThru request ignored by OnAudioPassThru notification #491

Closed chrisdrehernuance closed 4 years ago

chrisdrehernuance commented 8 years ago

The OnAudioPassThru notification sends microphone audio data from the headunit to the mobile device as binary PCM data (preceded by a wav file header). Unfortunately, this data does not match the PCM format requested in the preceding PerformAudioPassThru request from the phone.

For example, PerformAudioPassThru can request microphone audio data in a format of 8-bit PCM at 22KHz but OnAudioPassThru will return data in the OS's default format (ex: 16-bit 44KHz).

Recommend updating the file from_mic_to_file_recorder_thread.cc to set the sampling Hz, the bits-per-sample, and number of channels.

LitvinenkoIra commented 6 years ago

Priority Low. Offer for enhancement, not a defect.

Jack-Byrne commented 6 years ago

@chrisdrehernuance That audio format might not be supported by the head unit. Please check the audioPassThruCapabilities struct in the Register App Interface response. Also having multiple supported audioPassThruCapabilities is an accepted proposal. Please refer to this proposal which will be implemented into core in the future. https://github.com/smartdevicelink/sdl_evolution/blob/master/proposals/0138-hmi-audiopassthru-capability.md

shoamano83 commented 6 years ago

Hi, I have fixed this issue internally and would like to contribute it. I know this ticket has been closed, but please verify my PR if you like: https://github.com/smartdevicelink/sdl_core/pull/2184. Thanks.

ShobhitAd commented 4 years ago

Closed via #2184