For those that are interested in touch gLCDs, who struggle to create their own touch keypad, we have added the ideal solution to the Graphical LCD Display manager.
Not only will it create the widgets as keypad buttons with your custom text, it allows you to click on the widgets so you have a working keypad.
Simulation works great!:
An example project has been created, so you can have a working keypad on your gLCD.
This is the function macro that is very flexible in what you can create:
Lots of flexibility and there are also tooltips to help.
Make sure you download the latest component updates, then reload project before running and sending to hardware.
How the key touch is detected
The first widget is automatically assigned a unique widget ID e.g. the first widget with text 1 on it is assigned 24.
All the following widgets ID is then incremented from 24, e.g. widget with text 6 on is assigned 24+ 5 = 29.
The widget button pressed can then be calculated from 29 – 24 + 1 = 6.
Note: if you get a unable to run simulation error or compile error, then make sure you have the latest components downloaded.
Creating custom touch keypads for gLCDs
-
- Matrix Staff
- Posts: 1913
- http://meble-kuchenne.info.pl
- Joined: Wed Dec 02, 2020 11:07 pm
- Has thanked: 619 times
- Been thanked: 644 times
Creating custom touch keypads for gLCDs
- Attachments
-
- DisplayManager WidgetArray Keypad Example.fcfx
- (27.44 KiB) Downloaded 25 times
Martin
-
- Valued Contributor
- Posts: 1528
- Joined: Thu Dec 03, 2020 10:57 am
- Has thanked: 353 times
- Been thanked: 549 times
Re: Creating custom touch keypads for gLCDs
Hi Martin
That looks as though it will be very handy indeed.
Regards
That looks as though it will be very handy indeed.
Regards
-
- Matrix Staff
- Posts: 1913
- Joined: Wed Dec 02, 2020 11:07 pm
- Has thanked: 619 times
- Been thanked: 644 times
Re: Creating custom touch keypads for gLCDs
Thanks,
It was something we at Matrix wanted to create as its so handy for menus or RTC time/date setting.
You can have as many or as little keys as you like, and can be any size with any label.
It is versatile.
I'm going to be using it for my power monitor project so I can manually set the RTC if no internet is available, to reset energy used and to set price for KWh.
No more trying to set up and object and calculating if its been pressed or not.
I have just edited my first post to explain how the touch is detected.
It was something we at Matrix wanted to create as its so handy for menus or RTC time/date setting.
You can have as many or as little keys as you like, and can be any size with any label.
It is versatile.
I'm going to be using it for my power monitor project so I can manually set the RTC if no internet is available, to reset energy used and to set price for KWh.
No more trying to set up and object and calculating if its been pressed or not.
I have just edited my first post to explain how the touch is detected.
Martin
-
- Posts: 74
- Joined: Thu Jun 16, 2022 6:16 pm
- Has thanked: 110 times
- Been thanked: 13 times
Re: Creating custom touch keypads for gLCDs
Hi Martin
You added this example at the right time.
I thought about it.
I will test it out , when I get the time.
Regards
You added this example at the right time.
I thought about it.
I will test it out , when I get the time.
Regards
-
- Posts: 774
- Joined: Thu Dec 03, 2020 8:25 pm
- Location: Denmark
- Has thanked: 669 times
- Been thanked: 173 times
Re: Creating custom touch keypads for gLCDs
Hi Martin!
First I try to simulate, get the error init, and if I try to compile I also get error, the init is there?
Br Jorgen
First I try to simulate, get the error init, and if I try to compile I also get error, the init is there?

Br Jorgen
- Attachments
-
- DisplayManager WidgetArray Keypad Example.msg.txt
- (570 Bytes) Downloaded 11 times
-
- Macro.png (9.2 KiB) Viewed 3483 times
-
- Simulation.png (16.48 KiB) Viewed 3483 times
-
- Matrix Staff
- Posts: 1913
- Joined: Wed Dec 02, 2020 11:07 pm
- Has thanked: 619 times
- Been thanked: 644 times
Re: Creating custom touch keypads for gLCDs
Hi Jorgen have you updated your components database so you have the latest Graphical LCD Manager?
Also Strings are being worked on.
As soon as they are completed, I will let you know.
Have you you tried the file from here?
Also Strings are being worked on.
As soon as they are completed, I will let you know.
Have you you tried the file from here?
Last edited by medelec35 on Wed Apr 02, 2025 3:17 pm, edited 1 time in total.
Reason: Removed link as it now better to run a Full database component library update.
Reason: Removed link as it now better to run a Full database component library update.
Martin
-
- Posts: 74
- Joined: Thu Jun 16, 2022 6:16 pm
- Has thanked: 110 times
- Been thanked: 13 times
Re: Creating custom touch keypads for gLCDs
Hi medelec35
I also have a play with the keypad.
It worked out very well, Comes in handy for quite alot of stuffs
Thanks again
Regards
I also have a play with the keypad.
It worked out very well, Comes in handy for quite alot of stuffs
Thanks again
Regards
-
- Matrix Staff
- Posts: 1913
- Joined: Wed Dec 02, 2020 11:07 pm
- Has thanked: 619 times
- Been thanked: 644 times
Re: Creating custom touch keypads for gLCDs
Thanks for letting us know.
It was a component I have wanted for sometime.
I'm glad it works very well, and I also use it within my projects.
It was a component I have wanted for sometime.
I'm glad it works very well, and I also use it within my projects.
Martin