Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 01:56 17 Jun 2024 Privacy Policy
Jump to

Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.

Forum Index : Microcontroller and PC projects : Screen Savers?

Author Message
Phil23
Guru

Joined: 27/03/2016
Location: Australia
Posts: 1664
Posted: 11:48pm 17 Jun 2016
Copy link to clipboard 
Print this post

A thought for @matherp

I've seen some of the examples of LCD's displaying photo's etc. (Tiger Rings a bell).

Would it be feasible to convert these to a screen saver function.

So once a device becomes idle, it reverts to a slide show of 1 image or many, from a given location.

Might be more appealing to some (SO's), than a 5 or 7" screen full of data.

Options could simply be in given SD folder, a start timeout, sequential or random image display, and how long between image changes.

Cheers

Phil.
 
Grogster

Admin Group

Joined: 31/12/2012
Location: New Zealand
Posts: 9133
Posted: 04:30am 18 Jun 2016
Copy link to clipboard 
Print this post

I might be wrong here, but although the MM's can load full-colour images, they do it slowly by PC standards, and loading the full-screen tiger image is never gonna get any faster then it does now, which is too slow for a screensaver I would have thought.

However, if slow-drawing is not a problem, then a screensaver routine in BASIC would be easy, so long as you knew the filenames of the images. I have used this kind of thing before using SETTICK to draw the RTC on the screen each half-second or so, and while in there doing the clock, it does a SST=SST+1 kind of thing.

Back in the main loop, IF SST=180 THEN GOTO SCREENSAVER

Code loops over to screensaver, and one of the first things it does there, is SST=0, along with clearing the screen and DISABLING the RTC draw SETTICK.

Monitor for a keypress or touch, and as soon as that happens(or something else external perhaps), clear the screen again, and RE-ENABLE the SETTICK to draw the RTC, then hop out of that screensaver routine. This will immediately start incrementing SST again each time from zero.

In the interrupt for ANY touch or keypress, you also SST=0 to reset the screensaver timeout.

All easily done in BASIC - not a Cfunction or Csub in sight.

EDIT: Something else to be aware of, is that the LOAD IMAGE command takes time to complete, and everything else stops I think, while the image is loading, so if data could arrive at any time, and the MM is busy loading an image on the LCD, data could easily be missed. I would need to check that with a test code, but I would expect that to be the case, as loading image data is very processor intensive. Perhaps Geoff or matherp can confirm that or correct me on that.Edited by Grogster 2016-06-19
Smoke makes things work. When the smoke gets out, it stops!
 
Phil23
Guru

Joined: 27/03/2016
Location: Australia
Posts: 1664
Posted: 11:45am 18 Jun 2016
Copy link to clipboard 
Print this post

Ok,

Sort of digested that.

Probably what I'm thinking stems from the fact that many will find an image on a wall more aesthetic than a data screen.

Even an image as opposed to a slide show.

I'd get a Gold Star for a "Grandchild Photo" on the wall, & probably encouragement for another.

A touch screen controller.........

So something that just replaces data or "Blank", after a timeout was primarily what me thoughts were.

A single image would suffice.
 
Phil23
Guru

Joined: 27/03/2016
Location: Australia
Posts: 1664
Posted: 12:38pm 18 Jun 2016
Copy link to clipboard 
Print this post

Further thoughts....
Call it a Background page.

Looking at the GUI PAGE command in 5.2.

Could PAGE#0 be a background image.

File requirement could be predefined resolution proportional to the screen.
Not sure which is best approach for colour depth.

24 bit would be excessive.

8 Bit indexed colour images can look pretty good if the right image is chosen.

Haven't double checked my calculations, but if an 8 bit indexed image was saved in say 400x240 resolution it should be 96k.

Maybe a file that size could even reside in the library area?

Could be totally un feasible, but just thinking out loud.

Cheers

Phil.
 
Grogster

Admin Group

Joined: 31/12/2012
Location: New Zealand
Posts: 9133
Posted: 04:59pm 18 Jun 2016
Copy link to clipboard 
Print this post

I just used the circles demo in my earlier code. This is the same demo that is built into MM+ with the GUI TEST LCDPANEL command.

Perhaps what we need is for people to write some more graphics screensaver type demo things, that could then be implemented in your code. Those kinds of drawing graphics routines are much easier to deal with, still look good as a replacement for a static screen of data, and can be checked at every turn for external inputs etc.

Single image(or more) is still perfectly do-able, but you just need to be sure that while the MM is loading the image, should something signal the system for attention, if it is ignored cos the MM is drawing the image, will that matter?
Smoke makes things work. When the smoke gets out, it stops!
 
Print this page


To reply to this topic, you need to log in.

© JAQ Software 2024