Jump to content

Recommended Posts

Posted

from emblocks forum, we continue here (tectu rules)

tectu, can i send you my project for chibios & ugfx (2.2) under emblocks? i'm stuck on error:

Compiling: src\main.c

Compiling: ugfx\drivers\gdisp\SSD1289\gdisp_lld_SSD1289.c

src\main.c: In function 'Blinky':

src\main.c:43:27: warning: unused parameter 'arg' [-Wunused-parameter]

Compiling: ugfx\drivers\ginput\touch\ADS7843\ginput_lld_mouse.c

ugfx\drivers\ginput\touch\ADS7843\ginput_lld_mouse.c:48:35: error: unknown type name 'MouseReading'

ugfx\drivers\ginput\touch\ADS7843\ginput_lld_mouse.c:26:16: warning: 'lastx' defined but not used [-Wunused-variable]

ugfx\drivers\ginput\touch\ADS7843\ginput_lld_mouse.c:26:23: warning: 'lasty' defined but not used [-Wunused-variable]

ugfx\drivers\ginput\touch\ADS7843\ginput_lld_mouse.c:28:13: warning: 'filter' defined but not used [-Wunused-function]

chibios part is ok, but ugfx need everytime something

is not simple make functional chibios & ugfx under emblocks (for me).

i'm trying to make a skeleton project under emblocks, for future use.

i've used chibistudio and is all ok, but i prefer emblock.

thanks

Tectu

This is exactly the outdated board file issue :)

If you don't mind I'd like to move this issue to the uGFX forums as it is a fully uGFX related problem. Em::Blocks works fine

link to the project skeleton (the file is too big to attach here)

http://ge.tt/7GrQ6o72/v/0

uGFX is vs 2.2

Posted

Hello fastlink,

I took a look at your project and it seems like you are missing the actual board files for both the display and the touch screen.

You need to supply two files which tell uGFX how to talk to your display and to your touch screen controller. In your case you can copy the following two files from the uGFX library directory:

  • /drivers/gdisp/SSD1289/board_SSD1289_template.h
  • /drivers/ginput/touch/ADS7843/gmouse_lld_ADS7843_board_template.h

Copy those two files to your project directory (the place where you also have your main.c) and drop the _template in the file names. Then fill in the routines.

You can read more about board files here: http://wiki.ugfx.org/index.php?title=Board_File

Let us know if you have any questions about the board file implementation.

~ Tectu

Posted

i've done as you say (copyed the file in the same dir of the main.c and remove _template), and added to the project

but error persist..

i have put the project modified on the same place (ge.tt)

Posted

I have downloaded the project again from the link in your first post but I don't see any board files in the src directory. It looks like you left them in the driver directory.

Note that you will also have to add those new files in the Em::Blocks project file tree.

~ Tectu

Posted

You are using a "strange" version of uGFX. I have replace the 'ugfx' directory with the latest master and I can compile without any problems (after adding all the other missing uGFX files to the Em::Blocks project tree).

Note that you have to fix the GDISP_USE_DMA macro in the configuration file. It needs to be either set to TRUE or FALSE (I recommend not to mess with DMA until you got the display working).

~ Tectu

Posted

thank you tectu, now i can compile (probably before i do mix with 2.2 version, old version & repository version.. :( )

but when i add gfxInit(), receive this error :

.\src/gmouse_lld_ADS7843_board.h: In function 'read_value':

.\src/gmouse_lld_ADS7843_board.h:40:1: warning: no return statement in function returning non-void [-Wreturn-type]

.\src/gmouse_lld_ADS7843_board.h:38:43: warning: unused parameter 'm' [-Wunused-parameter]

.\src/gmouse_lld_ADS7843_board.h:38:55: warning: unused parameter 'port' [-Wunused-parameter]

ext\ugfx\drivers\ginput\touch\ADS7843\gmouse_lld_ADS7843.c: At top level:

ext\ugfx\drivers\ginput\touch\ADS7843\gmouse_lld_ADS7843.c:53:18: error: 'BOARD_DATA_SIZE' undeclared here (not in a function)

i think that i not include some .h file of the mouse driver

i have moved the directory of chibios & uGFX inside dir ext, not think is the problem

http://ge.tt/7GrQ6o72

OVEN_TFT2_33.rar

Posted

before replaced the files, error go away, after i try to

remove directory ugfx and replace with update from repository,also previous error go away but (this happen also when only replace file)..

obj\debug\ext\ugfx\src\gfx.o: In function `gfxInit':

C:\EmBlocks\OVEN_TFT2/ext\ugfx\src/gfx.c:90: undefined reference to `_gdispInit'

obj\debug\ext\ugfx\src\ginput\ginput_mouse.o: In function `GetMouseReading':

C:\EmBlocks\OVEN_TFT2/ext\ugfx\src\ginput/ginput_mouse.c:181: undefined reference to `gdispGGetWidth'

C:\EmBlocks\OVEN_TFT2/ext\ugfx\src\ginput/ginput_mouse.c:182: undefined reference to `gdispGGetHeight'

C:\EmBlocks\OVEN_TFT2/ext\ugfx\src\ginput/ginput_mouse.c:189: undefined reference to `gdispGGetOrientation'

obj\debug\ext\ugfx\src\ginput\ginput_mouse.o: In function `CalibrationCrossDraw':

:) never ending story..

in the usual place, if can help you (and me!)

OVEN_TFT2_5.rar

Posted

thanks for all tectu, i have some problem, but i try to solve by myself (i see correctly displayed the calibration screen, but not my text after the calibration)

how to disable the calibration screen? i need to go immediatly to first page, without, everytime make calibration, at this point not interest me interact with touchscreen

Posted
now the second more difficult thing.. why not writed correctly display

Can you please describe the symptoms that you get? Do you see a white screen? Noise? Garbage? Nothing at all? Wrong colors?

Please also let us know about your hardware setup (what microcontroller, what display, what interface you are using, if it is a PCB or wires on a breadboard etc.).

~ Tectu

Posted

i not see text on display, or to say better, i see something that seems text, but not writed correctly (see image attached), also there are blu line, garbage

i use stm32f4 discovery, ssd1289, display is connected with wire, i tryed with my previous project (with chibistudio), and goes fine, so is not problem of wire, is something about setup.

i have modified (like in previous project) the driver for the ss1289, to go more slow (DMA), if i use the original, i see only fuzzy

i put on the usual place photo and project modified

you can see on the left what is supposed be text :)

logo startup is correct, also calibration page

Posted

So you are 100% sure that the hardware works even now with the "old" project?

Can you please make sure that you replaced the SSD1289 driver in your project with the modified one from the other project? As you updated to a more recent version you might have forgotten that.

From what I can say the display was initialized but there is definitely some speed issue.

~ Tectu

Posted

yes, old project is working, i tryed to be sure, and yes, is working

i'm sure i have replaced the board_ssd1289.h file with file of old project & put to slow speed dma

what i not understand if is communication problem, also the logo i can't see, but i see correctly, also the mouse calibration, text & graphics!

can be some optimization settings of the compiler?

Posted

Optimization can definitely be a problem. I am not sure it is the problem in this case though. Easiest way to check is to simply turn off all optimisation and do a full build.

GCC in particular has some bad optimization bugs.

Posted
also the logo i can't see, but i see correctly, also the mouse calibration, text & graphics!?

I don't understand that sentence. You can you please try to rephrase this?

Also, it is recommended to turn of all the modules expect of the GDISP module until you have the display runing properly.

~ Tectu

Posted

i had put 2 video on the usual repository, is more simple for me (excuse my english)

the new, show what happen when i start debug, as you can see, i can do calibration, and text is ok, after calibration, you can see some white pixel on the right

the old, show the old project (first page only), is correct. no calibration becouse not needed.

i tryed to disable all the optimization but nothing change, fpu is active

at this point i not have idea what to try.. :evil:

i tryed also to deactivate all (only GDISP active)

Posted

found the problem! :roll:

my mistake, i initialize GPIOD_15 before i show the first page, but GPIO_15 is used by display bus.... so, after problem to send data to display... ach!

sorry tectu & innmarket for the time loosed about my stupid mistake!

  • 5 months later...
Posted

Hi, I have the same problem. :( I have a previous project worked on my previous computer but I failed to compile now :(

/home/makkmarci/workspace/ugfx/drivers/ginput/touch/ADS7843/ginput_lld_mouse.c:48:35: error: unknown type name 'MouseReading'

void ginput_lld_mouse_get_reading(MouseReading *pt) {

^

make: *** [build/obj/ginput_lld_mouse.o] Error 1

http://pastebin.com/mxVcekEz

with warnings:

http://pastebin.com/2Mii4YsF

would you please take a look at this? :( Thank you!

Posted

After I recognised some changes I have solved the previous.

Now I have:

        ^
main.c: In function 'main':
main.c:693:32: error: 'GEventMouse' has no member named 'meta'
if ((pem->meta & GMETA_MOUSE_CLICK)) {
^
main.c:701:43: error: 'GEventGWinButton' has no member named 'button'
if (((GEventGWinButton*)pe)->button == ghConsole)
^
main.c:709:41: error: 'GEventGWinSlider' has no member named 'slider'
if (((GEventGWinSlider*)pe)->slider == ghBrightness)
^
main.c:712:113: error: 'GEventGWinSlider' has no member named 'slider'
chprintf((BaseSequentialStream *)&SD2,"Slider %s = %d\r\n", gwinGetText(((GEventGWinSlider *)pe)->slider),
^
main.c: At top level:
main.c:382:13: warning: 'mysave' defined but not used [-Wunused-function]
static void mysave(uint16_t instance, const uint8_t *calbuf, size_t sz)
^
main.c:408:20: warning: 'myload' defined but not used [-Wunused-function]
static const char *myload(uint16_t instance)
^
make: *** [build/obj/main.o] Error 1

BUILD FAILED (exit value 2, total time: 11s)

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