cancel
Showing results for 
Search instead for 
Did you mean: 

TouchGfx with QSPI + Audio

ankitmcgill
Associate II

Hi,

I am working on a project using STM32F7. So far I have touchgfx working with external QSPI for storing image resources. Everything is working good and expected so far.

Now I would like to add audio functionality. The aim is to play WAV files when a touchgfx button is present. I am planning to use x-cube audio framework for the audio part.

What I am not clear about are

  • touchgfx is using qspi in memory mapped mode. My image resources are converted to C format by touchgfx and saved onto the qspi as part of flashing. correct?
  • for audio playing WAV files, it would be easier if I core store them on the QSPI using fatfs. Can this be done since touchgfx is already using the qspi in memory mapped mode.
  • If not possible, can I store my wav files on the qspi as raw data. How do i do this?

thank you for the help

3 REPLIES 3
Romain DIELEMAN
ST Employee

Hi,

Have you been able to find a solution to this ? If not then this will put the post back up for more visibility 😅.

Concerning the qspi memory, unless I am mistaken you cant divide it into two sections, one memory mapped the other not.

/Romain

Hi Romain,

Unfortunately no. I have gone through touchgfx documentation as well and they dont have any information on this. I am not surprised, given touchgfx does not have any audio support. What I am surprised is that no one has run into this use case? Seems like a fairly common use case.

As a last resort, I was thinking of adding a SD card interface and use it for audio storage (and qspi for touchgfx storage). Shold work, its just seems very wasteful.

Write the DISKIO layer for FATFS to read from addressable memory space, like it would for a RAMDRIVE. Have FATFS do READ ONLY

Build a disk image with something like WINIMAGE, and write that binary image deeper into QSPI, ie at 0x90100000 (or wherever) outside of the scope of data you told the linker you had in the linker script / scatter file.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..