1.8k views
in System Integration by

Further to my linker question - How to relocate the generated code to specific linker section? 

As we have moved to EW version 9 and my reported half screen fault with linker changes for QSPI use; I made no progress resolving this half screen chequer problem. I attempted RGBA8888 and RGB565 in multiple project with code merged in from multiple projects always returning back to the evalboard projects and working reference i already have with EW8.3.

This morning i downloaded the latest eval board project as per question - i note it has the linker settings as queried which confirms my implementation in part.

I generated 3 different example projects with RGBA8888 and RGB565 only to find they produce the same fault i experience with my migration of a large project.

With much tooing and froing thinking this was related to our large project or my implementation of EW 9 RTE etc drivers, I discovered if i comment out the linker settings for QSPI in the evalboard project supplied it works too.

In short can i assume this is proven in Atollic True Studio - the settings look ok and the project will run without an issue if all symbols are defined for the font and bitmap resource pragmas but the linker section is removed. As soon as the linker section is uncommented i get half screen problem.

The linker section i comment out:

.SectionEwResource :
  {
    . = ALIGN(4);
    *(.SectionEwResource)
    . = ALIGN(4);
  } >QSPI

1 Answer

0 votes
by

Hello,

yes, the Atollic True Studio project within our Build Environment is prepared for using the QSPI flash.

The project is compiled with 

EW_BITMAP_PIXEL_SECTION_NAME=.SectionEwResource
EW_FONT_PIXEL_SECTION_NAME=.SectionEwResource

and the linker file contains the following section

  /* The Embedded Wizard resource rodata goes into external FLASH */
  .SectionEwResource :
  {
    . = ALIGN(4);
    *(.SectionEwResource)
    . = ALIGN(4);
  } >QSPI

I just verified this on a STM32F769 Evalboard with the provided examples. Can you confirm that the examples are working on your environment?

In case there is a "half screen pixel garbage" on the screen, what is the reported message on the terminal (via serial connection)?

Additional remarks:

  • Please avoid any mixture between sources / libraries from version 8.x and 9.x - also do not make any mixture from sources of different color formats.
  • If you are using the template project for Atollic TrueSTUDIO, please make sure to use the provided PostProcess.

Best regards,

Manfred.

 

by

I have tested the hello world examples on both previously - this was my issue where i restarted my PC and then update the linker file etc. and they are fine.

We are looking at regenerating our GUI design in parts to see if one of the bitmaps can cause a problem.

Very sure it works correctly functionally - as long as the data is valid!  your function EwDecompress running to infinity as it seems means it is not escaping or giving up. There needs to be a size or max mem reference,  it may find the code its looking for in another area of memory - i.e. overrun.

aDest & aData are incremented with no limit check;  the algorithm assumes the curCode==257 will definately be found!

I have repeateble code in many projects and as you said as long as the provided data is valid. The data comes from the generator and the EwDecompress() code is part of you professional add on. 

Something to add is the GCC is using static library however i only added the professional add on so i could debug it - the results are the same with our large project with library or professional add on code.

Where can the provided data become invalid? if the source is from the generator?

Do you have a large project with many resources to the order of 2.2M that you can use on this platform so we can attempt to narrow down potentials?

by
Hello,

concerning EwDecompress(): This is not a generic decompression function. It is intended to be used only with generated resources. All generated resources are finite. Prerequisite is, that the data are read valid from the memory. If this is not reliable, other parts of the software will behave unpredictable too.

Concerning the problem: I assume that there is some other problem - EwDecompress is just the location where it is noticeable.

Unfortunately I still do not have a complete picture of your environment - Is it possible to have a short call?
by
unfortunately i have not been able to flash your hex files as the external loader for the eval board is failing  with a timeout.

I have been working on a cut down project which took our steps right back to a hello world project in terms of removing number of pages and back to a hello world project with our largest bitmap. Then to the original evalboard project only to find my original reported fault of the hello world project not working unless I comment out the linker file.

I have reset the environment, rebooted my PC and moved onto another eval board.

I would like to do this before we talk as i do not believe i have exhausted all variables on my side.

to add when cutting down a project we removed a toggle button that was out of screen area which made no difference to the result i.e. half checquer screen, but the fault (EwDecompress()) then moved to the bitmap load on  our startup screen. The bitmap is 800x480. But i have been unable to resolve anything further as previously mentioned something was fundamentally wrong as the hello world didnt work at the end of the test so i have to restart all of the shrinking complexity with new board.
by

The downloaded evalboard project have stopped working with the linker section included. Excluded they work. GCC command line works as delivered and the output confirms it is with RGBA8888.

The QSPI device add on driver to use in ST link:  MT25QL512A_STM32769I-EVAL

This is as per GCC command line 'make install' etc.

The 2 hex files linked (This is a binary...) worked.

To recap today:

  1. Changed Evalboard
  2. Imported the untouched/downloaded evalboard project into Atollic.
  3. Changed the path names etc to RGBA8888.
  4. Generated Hello World code for this colour format.
  5. Build and run in Atollic - half screen - FAIL
  6. Set Free RTOS = 0. exclude Free RTOS from the project.
  7. Build and run in Atollic - half screen - FAIL
  8. comment out EwSection in linker file
  9. Build and run in Atollic - display and touch events - PASS
  10. Open command line/ batch file StartGccBuildEnvironment - PASS (same project folder so the same code)
  11. delete all files in generated code folder.
  12. Copy our project generated into the generated code folder
  13. Build and run in Atollic - half screen - FAIL
  14. Open command line/ batch file StartGccBuildEnvironment - PASS (same project folder so the same code)
  15. repeated replacing generated code with some modified hello world i.e. adding the larger bitmaps
  16. same problems. GCC works for all. Atollic only works if linker section is commented out.

Unable to debug with this set of exercises as the code was untouched and professional add on was not added to the project.

 
by
Can you send us a non-working Atollic project (either sample or your minimized project) as a complete project, so that we are able to reproduce / debug the issue?

Ask Embedded Wizard

Welcome to the question and answer site for Embedded Wizard users and UI developers.

Ask your question and receive answers from the Embedded Wizard support team or from other members of the community!

Embedded Wizard Website | Privacy Policy | Imprint

...