Difference between revisions of "Architecture"
(→Modules) |
|||
(13 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
− | [[File:architecture2.png| | + | [[File:architecture2.png|500px|right|Overall µGFX architecture. Not showing all modules.]] |
− | The library is split into different modules. Each module is responsible for a specific task such as [[GDISP|driving an LCD]], [[GINPUT|reading user inputs]] or [[GFILE|handling files]]. | + | The library is split into different [[#modules|modules]]. Each module is responsible for a specific task such as [[GDISP|driving an LCD]], [[GINPUT|reading user inputs]] or [[GFILE|handling files]]. |
− | Each | + | The image to the right shows the architecture of a typical user application. Note that there are many more modules that are used internally and therefore not shown in the graphic. |
+ | |||
+ | '''Important:''' Each module has to be enabled in the [[Configuration|configuration file]] before it can be used. | ||
+ | |||
+ | == Modules == | ||
+ | Although there are many modules available, most of those are used internally and are not relevant for common application building. The main modules with which a user will usually interact are: | ||
+ | * GWIN | ||
+ | * GDISP | ||
+ | * GEVENT | ||
+ | * GFILE | ||
+ | * GINPUT | ||
+ | * GAUDIO | ||
+ | However, the user has full access to the other modules as well as they can simplify development of an application. One of these examples is the [[GQUEUE]] module. It provides (a)syncronous queues and buffers which can be a great help for some users. | ||
+ | |||
+ | The following modules are available: | ||
+ | {| class="wikitable" | ||
+ | ! scope="col"|Module | ||
+ | ! scope="col"|Description | ||
+ | |- | ||
+ | |GDISP | ||
+ | |Module to interface graphic displays including high-level drawing API.<br/>See [[GDISP]]. | ||
+ | |- | ||
+ | |GINPUT | ||
+ | |Module to interface user interaction peripherals such as touchscreen and buttons.<br/>See [[GINPUT]]. | ||
+ | |- | ||
+ | |GWIN | ||
+ | |Complete GUI toolkit.<br/>See [[GWIN]] | ||
+ | |- | ||
+ | |GAUDIO | ||
+ | |Modules to play and record audio.<br/>See [[GAUDIO]]. | ||
+ | |- | ||
+ | |GFILE | ||
+ | |Module to interface many different types of file systems through the same API.<br/>See [[GFILE]]. | ||
+ | |- | ||
+ | |GEVENT | ||
+ | |Event handling module. Used internally to couple the [[GINPUT]] an the [[GWIN]] module together.<br/>See [[GEVENT]]. | ||
+ | |- | ||
+ | |GTIMER | ||
+ | |Module providing software timers. Used internally.<br/>See [[GTIMER]] | ||
+ | |- | ||
+ | |GQUEUE | ||
+ | |Module which provides (a)synchronous queues, buffers and more. Used internally.<br/>See [[GQUEUE]]. | ||
+ | |- | ||
+ | |GOS | ||
+ | |Module which provides the interface to abstract many different underlying systems (OSes). This is used when porting the library to a new system.<br/>See [[GOS]]. | ||
+ | |- | ||
+ | |GADC | ||
+ | |Module to provide a common API for analog interface to the library. Used internally.<br/>See [[GADC]]. | ||
+ | |- | ||
+ | |GMISC | ||
+ | |Module containing miscellaneous features such as look-up tables for trigonometry functions, array operations and more. Used internally.<br/>See [[GMISC]]. | ||
+ | |} | ||
+ | |||
+ | == Configuration == | ||
+ | Each module has to be enabled in the [[configuration]] file before it can be used. Most modules do furthermore provide options that can not only manipulate the behavior of the module but also extend its features and capabilities. | ||
+ | |||
+ | == Initialization == | ||
+ | The entire library is initialized by calling <code>gfxInit()</code>. All modules will automatically be initialized if they have been enabled in the [[Configuration|configuration file]]. | ||
+ | |||
+ | |||
+ | |||
+ | [[Category:General]] |
Latest revision as of 13:50, 4 March 2016
The library is split into different modules. Each module is responsible for a specific task such as driving an LCD, reading user inputs or handling files. The image to the right shows the architecture of a typical user application. Note that there are many more modules that are used internally and therefore not shown in the graphic.
Important: Each module has to be enabled in the configuration file before it can be used.
Modules
Although there are many modules available, most of those are used internally and are not relevant for common application building. The main modules with which a user will usually interact are:
- GWIN
- GDISP
- GEVENT
- GFILE
- GINPUT
- GAUDIO
However, the user has full access to the other modules as well as they can simplify development of an application. One of these examples is the GQUEUE module. It provides (a)syncronous queues and buffers which can be a great help for some users.
The following modules are available:
Module | Description |
---|---|
GDISP | Module to interface graphic displays including high-level drawing API. See GDISP. |
GINPUT | Module to interface user interaction peripherals such as touchscreen and buttons. See GINPUT. |
GWIN | Complete GUI toolkit. See GWIN |
GAUDIO | Modules to play and record audio. See GAUDIO. |
GFILE | Module to interface many different types of file systems through the same API. See GFILE. |
GEVENT | Event handling module. Used internally to couple the GINPUT an the GWIN module together. See GEVENT. |
GTIMER | Module providing software timers. Used internally. See GTIMER |
GQUEUE | Module which provides (a)synchronous queues, buffers and more. Used internally. See GQUEUE. |
GOS | Module which provides the interface to abstract many different underlying systems (OSes). This is used when porting the library to a new system. See GOS. |
GADC | Module to provide a common API for analog interface to the library. Used internally. See GADC. |
GMISC | Module containing miscellaneous features such as look-up tables for trigonometry functions, array operations and more. Used internally. See GMISC. |
Configuration
Each module has to be enabled in the configuration file before it can be used. Most modules do furthermore provide options that can not only manipulate the behavior of the module but also extend its features and capabilities.
Initialization
The entire library is initialized by calling gfxInit()
. All modules will automatically be initialized if they have been enabled in the configuration file.