??? 09/09/05 10:20 Read: times |
#100851 - LED displays scroll demonstrator |
As multiplexed dot matrix LED displays are very often implemented using '51s and there are various interesting subjective visual effects on them, I have prepared a demonstator that runs on PC. AS the PC's display (CRT) is also a form of scanned display, this works quite reasonably well.
First the requirements and disclaimers: - tested to work under DOS, W9x and WXP. DOS recommended. Fullscreen mode required on Win's. Should work on any PC from 8088 on (not tested - having none....) - no functionality guaranteed - system crash not excluded (accesses VGA registers directly) although did not happen to me on a wild variety of PCs. Backup first, or use a spare PC. - uses 40x25 text mode. Some adapters don't imlement this mode correctly (commonly on laptops). - the described artefacts will probably be not observable on most of the LCD displays (depending on their construction, but most of them have too high persistence so that the "moving text" will appear smeared even if on a typical CRT will be clearly readable) Usage: Simply run http://www.8052.com/users/wek/Aliaslon.exe . Switch to fullscreen if needed (Alt+Enter). A scrolling text ("BUJDY") should appear. Use arrows to move it up and down. Use 'q','a' to increase/decrease speed1 - see "how it works" below Use 'w','s' to increase/decrease speed2 Use 'e','d' to increase/decrease xskip Use 'v' or ENTER to toggle between text and vertical line. Use '' or 'r' to toggle scroll direction. How it works: - synchronised to vertical retrace of CRT - that's one "period" - highlights the "text" (or vertical line) for speed1 periods (default=1) - hides the "text" for speed2 periods (default=0) - shifts the "text" by xskip positions (default=1) in the required direcition (default=right to left) - for the curious, source here. Explanation of what you see: - if text is on the top, on slower machines it might disappear (entirely or partially). This is a consequence of redrawing in process while the ray already started to trace from top. The consequence for LED displays: the shifting and displaying process may not overlap (shifting must be finished before displaying). - this is the effect why I wrote it at all. The text (or more visibly, the vertical line) is slanted - the top of the vertical bar appears shifted to the left compared to the bottom by approximately one "dot". The effect is more noticeable if you toggle the shift direction from left to right - the tilt changes to the opposite. The explanation is that the eye+nerves+brain "synchronizes" to the movement of the text and so the brain expects the whole picture to move simultaneously; but it sees flashes (dots) at a different time - the CRT is scanned from top to bottom, so it sees first the topmost "dot", remembers it, then as it "knows" it is moving to the left it "moves" it "himself" shightly forward when he a moment later sees the second "dot"... The proof of this explanation is, while trying to concentrate on the "text", the whole "mesh" appears to move smoothly. As the latin letters are usually tilted the other way while readibility requires a left-to-right scroll, it is necessary to make a bottom-to-top scan - you can try it by reversing the direction and turning the monitor at its top :-) Consequence for LED displays: this effect cannot be cancelled entirely on multiplexed displays. If you want to "utilize" it, make a bottom-to-top scanning display. If you want to avoid it, you need to make a non-multiplexed display. The effect can be weakened by making the scan more rapidly and switch off for the rest of time of frame (as is the case for the "text" which is scanned only a fraction of the frame time - note that it is tilted significantly less than one "dot"); but that also has implications on overall brightness. On column-multiplexed displays, this effect has implications on columns appearing in between real columns, but cannot be demonstrated on PC. - "higher" speed: press 'E' once. Now the "text" moves by two dots at a time rather than one. The text appears to move twice so rapidly and the tilt is more visible - for the vertical line it is two "dots". Pressing 'E' once more makes it move three dots at a time, but that's too much for such a small monitor so you stop perceiving it as a moving text (the brains stops "moving", the mesh is now standing and there are wildly flashing dots in the lines of the text). Stepping back a few steps might help but you need to concentrate to keep the brain do the "moving". Before continue decrease back to normal pressing 'D' or restart the progam. - "lower" speed 1: press 'A' (or '-') once. Now the text is displayed for two frames and then shifts. The brain still does it's "moving" thing, but at a half speed; so it sees the dots twice shifted by a half of the real pitch. Quite remarkable is that the dots even overlap. Pressing 'A' more times increases the number of frames the text is "stable" to a point where the brain stops the "moving" and you will see the text slowly jumping from position to position. Before continue increase back to normal pressing 'Q' or restart the progam. - "lower" speed 2: press 'S' (or '') once. Now each other frame the "text" is "off". Dots are not doubling anymore, but appear to be of half intensity (no wonder). Tilting is a half dot for full height line. Consequences of both "lower" speeds for LEDs: to avoid dots "doubling" for half speed frames have to be skipped, or scanning speed decreased (cannot be simulated on the PC)(both way it will appear flickering so the second method is superior as it does not introduce decrease in intensity, but the slanting will be a full dot) A note on the "text": "Bujdy" is the nickname of my friend for whom I wanted to demonstrate these effects several years ago, when we built the first dot matrix LED signs. Enjoy! Jan Waclawek |