Jump to content

How To Start


avtop

Recommended Posts

This guide should lead you through the process without any problems. In the Integrate µGFX section, you can find a link to a working Win32 Makefile.

Basic examples can be found under /demos/modules/gdisp/. All these demos are meant to work out of the box just by copying the gfxconf.h and the main.c file from the demo directory to your working project.

~ Tectu

Link to comment
Share on other sites

  • 3 weeks later...

There's not much sense in building such a demo for us. There are just too many factors which differ from system to system. Even if we build such a demo, there will be problems regarding toolchains. People use different compilers, different IDEs, different flash tools... As soon as we are through that, we have the problem that the panel settings differ from each display (the gdisp_lld_panel.h).

However, the STM32F407 discovery board is well supported by ChibiOS/RT and it runs out of the box. The SSD1963 driver of µGFX itself is used by many community members as well and there's even a demo board file for the STM32F407 discovery. Assuming that your toolchain is working fine and that you're able to wire it up correctly, there's really nothing that can go wrong beside the panel config file - and that's where we simply can't give any working demo at all.

If you have specific questions, please feel free to open up a new thread and ask, we will help you as best as we can.

~ Tectu

Link to comment
Share on other sites

Thank you for your reply, Tectu!

Sure, ChibiOS is runs out of the box but I can't add ugfx to the project.

As I understand, I need to do 2 things as written here: http://ugfx.org/get-ugfx/11-documentati ... fx-chibios

Do I need to do something else? Do I need to add files to the project in Keil or they will be automatically included while compiling?

I'm asking that because I have problem in compiling step, I'm getting this error: "..\main.c(16): error: #5: cannot open source input file "gfx.h": No such file or directory"

How I can solve it? Thank you.

Link to comment
Share on other sites

See, this is exactly the problem I mentioned ;)

When you're using Keil as your IDE, you have to add all the used .c and .h files of µGFX to your project path. I did this once for a friend quite a while ago and it was a real pain. Sadly it's not possible to build from an external Makefile out of Keil, so you can simply forget about the Makefile (modification). I'd suggest you to use ChibiStudio. That's a ready-to-use eclipse setup coming with the compiler and flasher already built-in and setup.

~ Tectu

Link to comment
Share on other sites

I'm sorry, but I don't really use ChibiStudio myself. I myself develop without any IDE since I got fed up by all this crazy stuff. I wrote this guide back the days in case of you're interested. Using that method, you won't have any problems with the Makefile modifications etc. at all because the Get µGFX Guide is 100% accurate for that method.

Otherwise I suggest you to take the working F407 Discovery demo and start building your own stuff around it.

~ Tectu

Link to comment
Share on other sites

  • 4 weeks later...

I'm sorry, but make functional project in version 2.0 is currently impossible for me, available information is conflicting, board.mk files in ugfx folders contain bad paths. The previous version have not a problem, but I spent many hours with version 2.0, no result :-(

Link to comment
Share on other sites

eg. file ugfx\boards\base\FireBull-STM32F103-FB\chibios_board\board.mk Why has this code, when board.c is in folder ugfx\boards\base.... I do not understand this :( Makefile is modified by this guide: http://ugfx.org/get-ugfx/11-documentation/37-get-ugfx-chibios

# List of all the board related files.
BOARDSRC = ${CHIBIOS}/boards/FIREBULL_STM32_F103/board.c

# Required include directories
BOARDINC = ${CHIBIOS}/boards/FIREBULL_STM32_F103

Link to comment
Share on other sites

Little progress, project in directory Mikromedia-STM32-M4-ILI9341 managed to compile after small modifications. But here again makefile in example folder not in accordance with the site guide ;)

Maybe needed to unify the code. Thanks for all your hard work done in the development of uGFX.

Link to comment
Share on other sites

Only modifications in path to chibios and ugfx.

In guide is included only

$(GFXLIB)/boards/base/Olimex-STM32-LCD/board.mk  # your board

, but in makefile in example folder are included

 include $(GFXLIB)/boards/base/Mikromedia-STM32-M4-ILI9341/board.mk
include $(GFXLIB)/boards/base/Mikromedia-STM32-M4-ILI9341/ChibiOS_Board/board.mk

Link to comment
Share on other sites

I don't see any problem there. The provided Makefiles within the example directories are of course supposed to include the board files for the board they are written for.

You are of course not supposed to include the board files of a board you do not own in your project directory, hence the # your board comment. The guide states this:


If you're using some well known dev board, it's very likely that there are already board files for this board. Inside the /boards/base/ directory, you can find the supported boards. Simply include the board.mk for the appropriate board in your Makefile.

I will try to rewrite the "Get µGFX" guide within the following week - there was just too little time.

Long story short: Don't include board files of a board you do not want to use.

~ Tectu

Link to comment
Share on other sites

The reason that the readme just says to include the one file but the example file includes two different files is because the Mikromedia board is not a board that is supported by default in ChibiOS. The additional line in the example Makefile was to add the support for that board to ChibiOS (which is really quite independent of uGFX).

The additional line is included in the example Makefile so that the makefile is complete and compilable with potentially no other change than to change the location of where uGFX and ChibiOS has been stored relative to your project directory.

Similiarly the ChibiOS_board directory is purely to add the files to ChibiOS to support that board.

Link to comment
Share on other sites

  • 10 months later...

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