Page 9 of 18
Re: GDISP driver
Posted: Sat Aug 04, 2012 4:00 pm
by inmarket
Just added a pull request.
This contains scaled fonts. These are fonts that use the data tables for a normal font but are scaled in the x or y direction.
This gives large fonts effectivly for free. I have defined double sized and narrow (double height normal width) fonts for all the standard fonts.
It turned out that this was much simpler than changing the API to include scaling parameters for all the text drawing routines.
Also added a mechanism to control device specific stuff like contrast, backlight brightness etc. Moved power control and orientation into the same routine to keep things consistant (with a macro definition for the old power and orientation routines).
Re: GDISP driver
Posted: Sat Aug 04, 2012 4:35 pm
by inmarket
I am now at a bit of a cross-roads as to what to tackle next.
What do the group consider a priority?
I will balance requests from the group with my own requirements to determine what to do next.
Some things on the list...
- Fix my partially functioning Nokia6610 LCD. Required for my project but not high priority.
- Finish implementing multithread protection.
- Touchscreen into halext. Not needed for my project but I would be happy to have a crack at it. I particularly like doing the high level abstraction work.
- Freetype fonts. There has been some request for this however I think the latest scaled bitmap fonts should reduce the requirement. This is also a memory and code size intensive project so it would go as a new high level driver that calls gdisp as its low level driver. (Boy I like the layering). Not required for my project.
- Create a utility to generate bitmap fonts suitable for gdisp. I would probably write this in java so it runs on both windows and linux although I am rusty in java.
- Create a driver that can feed common stream or memory based picture formats into the gdisp native pixel format blitter. We would have to be careful which formats we support due to software patent issues.
- Audio halext driver. This is a waveform audio mixer and tone generater using PWM as its lower level driver. This is required for my project.
- Porting gui or console to gdisp. Not needed for my project.
Any other suggestions and information on priority is welcome.
Re: GDISP driver
Posted: Sat Aug 04, 2012 4:57 pm
by Abhishek
Hi inmarket,
I think this would be the happiest day for Tectu

, he had so long been waiting for this. But even I can't resist trying it out myself.
As the other three members (including myself) using touchscreen LCDs now, we would definitely like to try out the touchscreen driver.
I guess we would start afresh with the GUI abstraction stuff (we've had a lot of discussions on this, see other topics).
I'd leave the freetype part as of now for a later stage. However we do need a utility to generate fonts, so it could be taken up as a sub-repo. And yes, java seems to be the natural choice.
Re: GDISP driver
Posted: Sat Aug 04, 2012 5:24 pm
by Tectu
Thank you very much for the scaling font stuff, inmarket. I didn't suggest that it can be done the way it is now, otherwise I would have done it myself -.-
I agree with Abhishek, libfreetype stuff isn't very neccessary at the moment. I think porting the touchpad drivers to halext is a better point, which also should be done in no time.
I am not sure why you want to port console to gdisp/halext stuff?
And Abhishek is right, to give the library a higher value, a GUI abstraction layer should be next in my opinion as well. But I can't do it on my own.
I would also love to see the font generator stuff in a utilities folder inside the glcd library.
~ Tectu
Re: GDISP driver
Posted: Sat Aug 04, 2012 5:48 pm
by inmarket
OK. Its looking like the priorities are:
- Touchpad to halext
- Font generator utility
- Gui abstraction
Re: GDISP driver
Posted: Sat Aug 04, 2012 5:53 pm
by Tectu
Why not using C for the font generator?
Since we don't have plattform dependend things like network sockets etc. this would be plattfrom independend as well.
~ Tectu
Re: GDISP driver
Posted: Sat Aug 04, 2012 5:58 pm
by Abhishek
Using C = libfreetype

.
BTW, it'll be easier in Java, because it requires 2D graphics, which is something platform dependent (Windows uses GDI, linux uses something else) . Java keeps it platform independent. We'll be generating fonts from existing fonts on the system.
Re: GDISP driver
Posted: Sat Aug 04, 2012 6:02 pm
by Tectu
inmarket, I found some time to take a look to your pull request.
Code: Select all
Fast-forward
halext/drivers/gdispNokia6610/gdisp_lld.c | 223 ++++++----------
halext/drivers/gdispNokia6610/gdisp_lld.h | 166 ------------
halext/drivers/gdispNokia6610/gdisp_lld_board_olimexsam7ex256.h | 34 +++
halext/drivers/gdispNokia6610/gdisp_lld_config.h | 278 +++++--------------
halext/drivers/gdispS6d1121/gdisp_lld.c | 194 +++++++-------
halext/drivers/gdispS6d1121/gdisp_lld.h | 150 -----------
halext/drivers/gdispS6d1121/gdisp_lld_config.h | 278 +++++--------------
halext/drivers/gdispS6d1121/s6d1121_lld.c.h | 247 +++++++++++++++++
halext/drivers/gdispSsd1289/gdisp_lld.c | 201 +++++++-------
halext/drivers/gdispSsd1289/gdisp_lld.h | 150 -----------
halext/drivers/gdispSsd1289/gdisp_lld_config.h | 278 +++++--------------
halext/drivers/gdispTestStub/gdisp_lld.c | 71 ++---
halext/drivers/gdispTestStub/gdisp_lld.h | 150 -----------
halext/drivers/gdispTestStub/gdisp_lld_config.h | 278 +++++--------------
halext/halext.mk | 4 +-
halext/include/gdisp.h | 701 +++++++++++++++++++++---------------------------
halext/include/gdisp_fonts.h | 192 +++++++------
halext/include/gdisp_lld.h | 466 ++++++++++++++++++++++++++++++++
halext/src/gdisp-readme.txt | 13 +-
halext/src/gdisp.c | 1465 +++++++++++++++++++++++++++++++++++++++++++++++++++-------------------------------------------------
halext/{include/gdisp_lld_inc_emulation.c.h => src/gdisp_emulation.c} | 155 +++++++----
halext/{include/gdisp_inc_fonts.c.h => src/gdisp_fonts.c} | 1264 ++++++++++++++++++++++++++++++++++++++++++++------------------------------------------
halext/templates/gdispXXXXX/gdisp_lld.c | 194 +++++++-------
halext/templates/gdispXXXXX/gdisp_lld.h | 150 -----------
halext/templates/gdispXXXXX/gdisp_lld_config.h | 278 +++++--------------
halext/templates/gdispXXXXX/readme.txt | 11 +
26 files changed, 3409 insertions(+), 4182 deletions(-)
delete mode 100644 halext/drivers/gdispNokia6610/gdisp_lld.h
delete mode 100644 halext/drivers/gdispS6d1121/gdisp_lld.h
delete mode 100644 halext/drivers/gdispSsd1289/gdisp_lld.h
delete mode 100644 halext/drivers/gdispTestStub/gdisp_lld.h
create mode 100644 halext/include/gdisp_lld.h
rename halext/{include/gdisp_lld_inc_emulation.c.h => src/gdisp_emulation.c} (72%)
rename halext/{include/gdisp_inc_fonts.c.h => src/gdisp_fonts.c} (89%)
delete mode 100644 halext/templates/gdispXXXXX/gdisp_lld.h
How exactly did you do the font stuff? Shouldn't this be in glcd/ files?
I am not sure if I still understand what you want to with the halext stuff. This will only contain the driver abstraction, right? the glcd/ and touchpad/ directories with the highlevel functions will still exist.
~ Tectu
Re: GDISP driver
Posted: Sat Aug 04, 2012 6:06 pm
by Abhishek
The fonts go into src/glcd_fonts.c .
I suppose halext will contain not just GDISP, but gTouch, and very soon audio as well.
Re: GDISP driver
Posted: Sat Aug 04, 2012 6:09 pm
by Tectu
What will happen to the old glcd/ and touchpad/ stuff? Why aren't the font's implemented in glcd/fonts.* used by glcd/glcd.*
The origin idea was to have a HAL, which would be inside halext, and all highlevel functions, in glcd/ and touchpad/ gui/ etc.
~ Tectu