Definitely, well I'll have to dig more to see how it is done, thus I was asking for an easy method (if any) to make this temporarily work.
Better hide until your old account is unlocked tomorrow and delete this one. The moderators take a dim view of multiple accounts.
You can still append replies by editing the latest previous post #26.
If you are using the sketch in the first post, it looks like your display colors are inverted, 0x0000 should be black and 0xffff white. Try tft.invertDisplay(false); after tft.begin() and see if that corrects the problem (I've had a display like that).
Thanks for advice I added tft.invertDisplay(false); however that didn't fix the issue
Here it is before the time is updated:
I was brainwashed with the NAPLPS system, now obsolete, but it tackled and solved basic problems like this. It had an alpha channel IIRC and that is how you could easily define overwrite behaviour because both foreground and background had independent alpha channels (part of the colour definition, really). So an overwrite such as the poster desires, was easily achieved by setting both foreground and background colour alpha channels to 1.0
Ok that looks like it's overwriting. Was there a doubt?
No, I knew it was overwriting however I now just need a way to not make it do that.
You took a different bit of advice from him, go back there is more you need to do. Few posts back by @david_2018 Davide
To clarify post #28, you would have to
- call function to get the rectangle size of the text area
- call function to fill a rectangle on the screen, of that size (thus, erasing text)
- finally, print your new text
If you're not planning on moving the text for the life of the program, you can perform the first step only once, in setup().
You could write a class that has methods to help manage the rectangles that make up the screen area. One of those could write out the clock display you have, but the very same class could other screen data that you might add, such as the date or whatever. It would hide the ugliness of blatting rectangles and such. Then you have two display objects,
Calendar
Time
Each one uses exactly the same code, but has an independent screen location and data. Then you could just write something like:
calendar.display(dateTime, calendarCoordinates);
time.display(t, timeCoordinates);
Very dim.
No one also asked for "new user limit" im simply tryna have my inquiry solved
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.