Success in driving Newhaven display with STM32F746 DISCO board

75 views
asked Feb 2 in Embedded Wizard Studio by ezed413

I was successful in connecting the Newhaven 320 x 240 TFT display. I used the ColorFormats example for the STM32F746 DISCO board. Of course it cuts some of the screen off because of the resolution difference, but it works. And looks quite good. 

But when I create a new application using the STM32F746 Discovery template and build and upload the program to the board, the diplay is blank. BTW, I am using the default ew_bsp_display.c intialization code. Oh, backlight boost convertor on the DISCO board produces 36 volts. I only need 19 volts for the Newhaven display, so I connected an external power supply to the backlight LEDs. 

Any thoughts as to why the new application won't work?

 

1 Answer

0 votes
answered Feb 3 by Manfred Schweyer

Hello,

great to see that your own display is running.

When you create a new project by using the STM32F746 Discovery template, make sure to adapt the ScreenSize according to your display.

Furthermore, when your display is still empty, please check the output within the console window. Are there any error messages?

Best regards,

Manfred.

commented Feb 4 by ezed413
When I change the example project ColorFormats ScreenSize from 480, 272 to 320, 240 and build and upload it, I get a blank screen. When I change the ScreenSize back to 480, 272 the screen is displayed again, albeit in 320, 240 resolution. I tried changing the ScreenSize in a newly created STM32F746 template project to 320, 240 and get I the same thing, blank screen. And I have tried keeping the ScreenSize at 480, 272 in a template project and keep the bounds of the rectangle to 320, 240. This doesn't work either.

Here are the 24 bit timings of the Newhaven display;

RGB_DISPLAY_RESOLUTION_QVGA

Values specific to QVGA LCD display

DispWidth = 320;

DispHeight = 240;

DispHCycle =  408;

DispHOffset = 70;

DispHSync0 = 0;

DispHSync1 = 10;

DispVCycle = 263;

DispVOffset = 13;

DispVSync0 = 0;

DispVSync1 = 2;

DispPCLK = 8;

DispSwizzle = 2;

DispPCLKPol = 0;

DispCSpread = 1;

DispDither = 1;

 Any help would be appreciated.
commented Feb 4 by Manfred Schweyer
Please make sure to adjust also the Framebuffer Size within the file ewconfig.h.

Are there any error messages in the console window?
commented Feb 4 by ezed413
No, there are no error messages.
commented Feb 4 by ezed413
So I should change the frame buffer to 240.4 K bytes?
commented Feb 4 by Manfred Schweyer

The framebuffer defines

#define FRAME_BUFFER_WIDTH              480
#define FRAME_BUFFER_HEIGHT             272

should be adapted to the size of your display

#define FRAME_BUFFER_WIDTH              320
#define FRAME_BUFFER_HEIGHT             240

so that it matches with the ScreenSize of your GUI project.

commented Feb 4 by ezed413
Ok, thanks, I bet this is it!
commented Feb 4 by ezed413
I am feeling dumb, I did not check the console output. I was confusing the DOS screen that you upload the program from with the output console. I would have seen the resolution. My bad. I will do this later.
commented Feb 5 by ezed413

After changing the two defines, it worked. But I did have to download a later build environment for this board. Thanks again!

commented Feb 5 by Manfred Schweyer
Congratulations!!!
commented Feb 5 by ezed413
Yes, I am pleased!

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

...