Jump to content

Blank White Screen for Flashed Example Programs


newbornsun

Recommended Posts

Hello,

I am attempting to compile and flash a uGFX Mikromedia-STM32-M4-ILI9341 example program to my Mikromedia devboard. I am able to successfully compile and therefore create a .hex file in ChibiStudio using the tetris uGFX example file (by setting GFXDEMO = games/tetris in the makefile). As noted, this all compiles fine and dandy, however, when I try to flash the .hex file using ST-Link utility or other .hex flasher, it works, the board successfully flashes, however, only a blank white screen appears upon startup of the dev board.

I am wondering if you might happen to know why this is the case or if you can provide me with further assistance.

Thank you!

Link to comment
Share on other sites

Perhaps I should include my console output:

11:41:09 **** Build of configuration Default for project Mikromedia-example ****
make -j4 all 
.
C Compiler Options....
Compiling ../../uGFX/src/gfx.c
Compiling ../../uGFX/src/gos/gos_chibios.c
arm-none-eabi-gcc -c -ggdb -O1 -mcpu=cortex-m4 -falign-functions=16 -mfloat-abi=hard -mfpu=fpv4-sp-d16 -fsingle-precision-constant -fomit-frame-pointer -Wall -Wextra -Wstrict-prototypes -fverbose-asm -ffunction-sections -fdata-sections -fno-common -flto -MMD -MP -MF .build/dep/fakethumbfile.o.d -I. -I../../uGFX -I../../uGFX/3rdparty/tinygl-0.4-ugfx/include -I../../uGFX/boards/base/Mikromedia-STM32-M4-ILI9341 -I../../uGFX/drivers/gdisp/ILI9341 -I../../uGFX/drivers/gaudio/vs1053 -I../../uGFX/demos/applications/notepad -I../../chibios26/os/ports/common/ARMCMx/CMSIS/include -I../../chibios26/os/ports/common/ARMCMx -I../../chibios26/os/ports/GCC/ARMCMx -I../../chibios26/os/ports/GCC/ARMCMx/STM32F4xx -I../../chibios26/os/kernel/include -I../../chibios26/os/hal/include -I../../chibios26/os/hal/platforms/STM32F4xx -I../../chibios26/os/hal/platforms/STM32 -I../../chibios26/os/hal/platforms/STM32/GPIOv2 -I../../chibios26/os/hal/platforms/STM32/I2Cv1 -I../../chibios26/os/hal/platforms/STM32/OTGv1 -I../../chibios26/os/hal/platforms/STM32/RTCv2 -I../../chibios26/os/hal/platforms/STM32/SPIv1 -I../../chibios26/os/hal/platforms/STM32/TIMv1 -I../../chibios26/os/hal/platforms/STM32/USARTv1 -I../../uGFX/boards/base/Mikromedia-STM32-M4-ILI9341/ChibiOS_Board -DGFX_USE_OS_CHIBIOS=TRUE -DGFX_USE_OS_CHIBIOS=TRUE -DCORTEX_USE_FPU=TRUE -DUSE_FPU=hard -DTHUMB_PRESENT -DTHUMB_NO_INTERWORKING -mthumb -DTHUMB fakethumbfile.c -o .build/obj/fakethumbfile.o
.
Linker Options........
Compiling ../../uGFX/src/gos/gos_freertos.c
arm-none-eabi-gcc -u chThdExit -Wl,--defsym=__process_stack_size__=0x400 -Wl,--defsym=__main_stack_size__=0x400 -mcpu=cortex-m4 -falign-functions=16 -mfloat-abi=hard -mfpu=fpv4-sp-d16 -fsingle-precision-constant -nostartfiles -mthumb -Wl,--gc-sections -T../../chibios26/os/ports/GCC/ARMCMx/STM32F4xx/ld/STM32F407xG.ld -lm .build/obj/fakethumbfile.o -o .build/Mikromedia-example.elf
In file included from ../../uGFX/src/../gfx.h:185:0,
                 from ../../uGFX/src/gfx.c:16:
../../uGFX/src/../src/gdisp/gdisp_rules.h:65:6: warning: #warning "GDISP: GDISP_NEED_ANTIALIAS has been set but your hardware does not support reading back pixels. Anti-aliasing will only occur for filled characters." [-Wcpp]
     #warning "GDISP: GDISP_NEED_ANTIALIAS has been set but your hardware does not support reading back pixels. Anti-aliasing will only occur for filled characters."
      ^
.
Compiling ../../uGFX/src/gos/gos_win32.c
Compiling ../../uGFX/src/gos/gos_linux.c
Compiling ../../uGFX/src/gos/gos_osx.c
...
Compiling ../../chibios26/os/hal/platforms/STM32/TIMv1/pwm_lld.c
Compiling ../../chibios26/os/hal/platforms/STM32/USARTv1/serial_lld.c
Compiling ../../chibios26/os/hal/platforms/STM32/USARTv1/uart_lld.c
Compiling ../../uGFX/boards/base/Mikromedia-STM32-M4-ILI9341/ChibiOS_Board/board.c
Compiling ../../uGFX/boards/base/Mikromedia-STM32-M4-ILI9341/ChibiOS_Board/flash_memory.c
Linking .build/Mikromedia-example.elf
Creating .build/Mikromedia-example.hex
Creating .build/Mikromedia-example.bin
Creating .build/Mikromedia-example.dmp
.
   text       data        bss        dec        hex    filename
  26920          0       6036      32956       80bc    .build/Mikromedia-example.elf

11:41:20 Build Finished (took 11s.638ms)

 

Edited by Joel Bodenmann
Using code box and shortening unnecessary output
Link to comment
Share on other sites

Start with the gdisp/basics demo as this enables us to test the hardware with the least amount of "fluff".

Make sure that you have the M4 board not the M4-Plus board as that has different hardware on it.

Also the M4 board itself comes in 2 versions, one with the ILI9341 and the other with a different display controller. Make sure you have the ILI9341 version.

This is a board that I have myself so last time I tried this configuration was working well. If we can't identify the problem then I will fire up my board and retest however that won't happen until next week as I am currently away on business. 

Link to comment
Share on other sites

Hi thanks for the reply.

I believe it is the one with ILI9341, as listed on the website. Is there any way to deterministically check? Haven't seen a Mikromedia STM32 M4 with a different driver...

Also, I should note, that I was only able to compile the above example by including the following in my makefile:

LDFLAGS  = -u chThdExit

Otherwise wont compile and have linking issues as mentioned in a different thread.
 

Link to comment
Share on other sites

Hello @newbornsun and welcome to the µGFX community!

I'm glad to hear that you got everything working! The OPT_LINK_OPTIMIZE = no doesn't surprise me at all. Basically that doesn't do anything but turning LTO off. There is one (known) GCC version which has a bug in the LTO stuff.
The -u chThdExit stuff would be surprising however. That's definitely wrong and doesn't belong there.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...