Tony Nixon wrote: > There is some matrix code here, but I had trouble making it scroll. It > didn't matter what I did, the digits always looked like they were > duplicated by 1 pixel. I'm not sure where I read this up; it might have been on this list; but that's one of two "trade secrets" of Times Square displays. The other is keeping the letters straight as they scroll, since the multiplexing is actually sweeping up or down through the rows, which produces a slant when the characters move. As I see it, the problem with scrolling is that the letter spends a certain time in one position, then suddenly steps to the next. Your eyes OTOH, track the letters with a smooth movement either in fact, or virtually, using their terrific signal processing and a pixel resolution much finer than the display. (Obviously the "double width" effect will disappear somewhat with distance.) Consequently, what the eyes see is a line of text whose smooth movement is modulated by a 1 pixel peak-to-peak sawtooth, blurring it to an extra pixel width. The only remedy I can see for this is to use PWM to blur the transfer from one character to the next, dividing the pixel shift interval into at least four sub-periods with corresponding durations in the "old" and "new" pixel positions i.e. 4:0, 3:1, 2:2 and 1:3. Interestingly, this is absolutely dead easy to do using the logic you should already have to drive the display; it is just a matter of serially loading the data into the row registers, waiting the required proportion of the multiplex time, then shifting in just one more bit (and re-latching presuming you have latching registers) for the remainder of the multiplex time. It will *not* be necessary to re-load the entire row. Now as to *why* this should improve the appearance when by my analogue, you still have a "sawtooth" (indeed, a larger one!) imposed on the steady text movement, is largely intuitive. In the original case, all parts of the "sawtooth" were equally bright, so defining a moving pixel, whereas in the altered version, the pixel's intensity is proportional to how close it is to the average position. Plot of "jitter" on movement with original algorithm: **** **** **** **** **** ** **** **** **** **** **** **** **** **** **** **** **** **** Plot of "jitter" on movement with PWM algorithm: * * * * * * ** ** ** ** *** *** *** *** **** **** **** **** *** *** *** *** *** * ** ** ** ** * * * * Note that peak jitter is actually nearly doubled! -- Cheers, Paul B.