How to download gif Image on STM board??

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • How to download gif Image on STM board??

      Hello, everyone.
      I'm developing gui using the sm32f4 board. ( IDE: IAR / board: STM32F469BE / development language : C )


      1. At first, I used the gif file by converting it into a c file using Bin2C.exe.
      2. So, I converted the file logo_ani.gif to logo_ani.c and included it in my project.

      Source Code

      1. static const unsigned char _aclogo_ani[139961UL + 1] = {
      2. 0x47, 0x49, 0x46, 0x38, 0x39, 0x61, 0xE0, 0x01, 0x20, 0x03, 0xD5, 0x3F, 0x00, 0x89, 0x89, 0x89, 0xCA, 0xCA, 0xCA, 0x4B, 0x45, 0x2D, 0xAE, 0x8C, 0x29, 0x22, 0x22, 0x21, 0xFB, 0xFB, 0xFB, 0xEB, 0xEB, 0xEB, 0xEA, 0xD5, 0x5F, 0x09, 0x09, 0x09,
      3. ...
      4. };



      Source Code

      1. void sys_Loading(void){
      2. ...
      3. _ShowMovie((char *)_aclogo_ani, sizeof(_aclogo_ani));
      4. ...
      5. }


      Source Code

      1. static void _ShowMovie(const char *pFile, uint32_t FileSize){
      2. GUI_GIF_IMAGE_INFO ImageInfo = {0};
      3. GUI_GIF_INFO GifInfo = {0};
      4. int i;
      5. int j;
      6. int XPos;
      7. int YPos;
      8. GUI_Clear();
      9. GUI_GIF_GetInfo(pFile, FileSize, &GifInfo);
      10. XPos = (GifInfo.xSize >= 480) ? 0 : 160 - (GifInfo.xSize / 2);
      11. YPos = (GifInfo.ySize >= 800) ? 0 : 150 - (GifInfo.ySize / 2);
      12. while(1){
      13. for(j=0; j< GifInfo.NumImages; j++)}
      14. GUI_GIF_DrawSub(pFile, FileSize, XPos, YPos, j);
      15. GUI_GIF_GetImageInfo(pFile, FileSize, &ImageInfo, j);
      16. GUI_Delay(ImageInfo.Delay ? ImageInfo.Delay * 10 : 100);
      17. }
      18. ...
      19. if(...)
      20. return;
      21. }
      22. }
      Display All
      • But now I have to download and use gif images in external memory due to the problem of program output file size getting too big.
      • Currently, image files are downloading image.bin files through ST-LINK Utility.
      • In the case of gif, how can I know if I can download to the board?
      • Could i make bin file (array of gif : _aclogo_ani[139961UL + 1] ) and download on my board with STM32Cube Programmer?


      Thank you for reading through