STMicroelectronics / STM32CubeH7

STM32Cube MCU Full Package for the STM32H7 series - (HAL + LL Drivers, CMSIS Core, CMSIS Device, MW libraries plus a set of Projects running on all boards provided by ST (Nucleo, Evaluation and Discovery Kits))
https://www.st.com/en/embedded-software/stm32cubeh7.html
Other
514 stars 307 forks source link

Oversensitive up/down touchscreen controls in BSP audio playback example #181

Closed TheseGoTo11 closed 3 years ago

TheseGoTo11 commented 3 years ago

Describe the set-up STM32H735G-DK discovery kit (may affect others with touch screens too) STM32CubeIDE1.7.0 BSP example project. Source code here.

Describe the bug When using the "audio play" screen of the example, the touch screen controls for increasing or decreasing frequency and volume are oversensitive. It is extremely difficult (luck, really) to select a specific rate or volume level.

How To Reproduce Navigate to the "audio play" screen of the example. Attempt to raise or lower the playback frequency to a specific value. (Allowed values are 96000, 48000, 44100, 32000, 22050, 16000, 11025, 8000.)

Additional context The problem seems to be that when an up/down control is touched, audio_play.c quickly receives multiple up/down actions, causing a single touch of the control triangles to make unpredictable changes (wild swings) to the frequency or volume. The code that interprets the touch screen presses is here.

If the code would ignore repeated values returned by AudioPlay_GetTouchPosition(), then the controls could operate predictably by tapping the touch screen. I have already written and tested a simple fix for this, and can submit a pull request if desired.

RKOUSTM commented 3 years ago

Hi @TheseGoTo11,

Thank you for your contribution. This request will be forwarded to our development teams for deeper analysis. We will be back to you as soon as they provide me with their answer.

This duplicated issue will remain closed. The pull-request #182 that you reported will be kept open to track the point.

Thank you for you again for your contribution.

With regards,

RKOUSTM commented 3 years ago

Duplicate of #182