Skip to content

karaClass is a base library to build GUI structured user screen interface on ILI9341 touch screen for arduino due.

License

Notifications You must be signed in to change notification settings

karawin/karaClass

Repository files navigation

karaClass

KARACLASS_VERSION 1.03

karaClass is a skeleton to build structured user screen on ILI9341 touch screen (around 6$ in china) for arduino due. Probably it can work on other boards like mega or teensy.

Defined main classes are:
TScreen: the screen itself
TPanels: a container of TPanel and TButtons
TPanel: the main part of the screen
TButtons: a container of raw of TButtons. displayed from bottom to top of TPanels
TButton: a button
TStBar: a panel at the top of the screen. It contains TStatus object.
TKeyboard: a complete qwerty keyboard
TBigTime: A panel displaying date and time
TSlider: A panel with a slider.
Added a screensaver timeout (BigTime after a minute of inactivity)

A TButtons panel can be in group mode ie only all TButton are in toggle mode but only one can be On.
A TButton can be a simple push button or a toggle button (bistable) with or without an image and with a caption.

On many components, a user action may be called for each touch, untouch and slide events.

To add your code, please use only definitions beggining with userXXX
void loop() {
myScreen.Task();// mandatory. The engine
}

In your project.ino
////MODIFY///////////////////////////////////////////////
// Called in the TScreen::Task(). Put your code here
void TScreen::userTask()
{
;
}
// Called every second. Put your code here
void TScreen::userSecond()
{
;
}

In KaraScreenConfig.h:
/////////////////////////////////////////////////////////
// must be modified depending of the screen configuration
// Complete screen configuration, init ans start
void TScreen::userBegin()
{
...


void TScreen::userStatus()
{
StatusBar->Refresh();
}

See the example to show these elements in action.
The example needs additional libraries:
RTClib
SdFat
SdFatUtil
IniFile.h
DueTimer cannot live without it

screenshot Panel of buttons.
screenshot Keyboard QWERTY
screenshot Keyboard phone mode
screenshot BigTime
screenshot Radio buttons panel
screenshot Slider

Video:
https://www.youtube.com/watch?v=f44uVu8w-bA

About

karaClass is a base library to build GUI structured user screen interface on ILI9341 touch screen for arduino due.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages