Jump to content

First uGFX Studio derived application


jbsull

Recommended Posts

Hello,

I am modifying the ChibiStudio  stm32f4-discovery project - which I have running --- to use the output files from uGFX Studio.

How do I set this up ? - I copied all the files, and the resources directory.

It looks like I need to modify main() , and add guiInit().. and remove a few things.

I thought I saw instructions somewhere , but I misplaced them.

But, in case you have an already modified main.c somewhere....

Jim

Link to comment
Share on other sites

Hello Jim,

It's correct that you copy all the files of the generated output directory (generated by the µGFX-Studio) to your project. Once you added the necessary files you just have to add the call to guiInit() to your main.c. Here's the most minimalistic main.c that we use for testing purposes:

int main(void)
{
	gfxInit();

	guiInit();

	guiShowPage(DISPLAY_PAGE);

	while(1) {
		gfxYield();
	}
}

of course your main() can contain other things as well. You really just add the functions you can find in gui.h to interact with the GUI.

I hope that helps. Don't hesitate to ask if you have any further questions.

Link to comment
Share on other sites

There seems to be a conflict in font names in _RESOURCES_MANAGER_H, and gui.h.

 

gui.h

font_t DejaVuSans12;
font_t phpoXxi1Y;
font_t DejaVuSans24;

 

_RESOURCES_MANAGER_H

#define DejaVuSans12 0
#define phpoXxi1Y 1
#define DejaVuSans24 2
 

What to do ?

Jim

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...