Comments (4)
That's fantastic - setting the scrollAlign to PA_RIGHT is the crux of the matter here. I would never figured that out, not even by accident. PA_LEFT and setScrollSpacing(1) and that is all. My fix into the rubbish bin, all the better. You really seem to have nailed everything in this library. Apologies for wasting your time and many thanks for your kind help!
Absolutely brilliant.
from md_parola.
Thanks. Happy to hear that you are enjoying using the library.
I think the setting you were looking for is setScrtollSpacing(). Documentation entry:
void MD_Parola::setScrollSpacing (uint16_t space)
Set the horizontal scrolling distance between messages for all the zones.
When scrolling horizontally, the distance between the end of one message and the start of the next can be set using this method. Default behavior is for the message to be fully off the display before the new message starts. Set to zero for default behavior.
from md_parola.
Thank you, but I actually do use setScrollSpacing(3) not 0.
With texts shorter than the display, and spacing set to 0 (default behaviour) the text runs off the display and when completely gone, the new message enters at the righthand side.
With texts shorter than the display, and spacing set to 1 (or 3 in my case), as soon as the text arrives at the most lefthand column, not entirely has scrolled off, the new message enters at the righthand side. Here we see a gap of empty fillers, because the display is longer than the message.
With the filler mechanism turned off, messages shorter than the display will be repeated without gaps.
To demonstrate the effect, I made a video that shows/explains it better.
I could use zones, but zones have predefined sizes and would not work here, I think..
https://www.youtube.com/watch?v=c9pWQCqJZHg
First parts is with setScrollSpacing(3) and the second part of the video is with the fillers off.
Do you see what I mean? ;-)
from md_parola.
The normal behaviour of Parola is to wait for the message to scroll off the screen (ie the last column of LEDs to disappear on the left) before the next message starts - this is as you observe. To do this the code counts the number of columns that are blank and compares it to the size of the display in columns. This is found in the block of code under the comment around line 124
// check if enough scrolled off to say that new message should start
in the 'exit' part of the code file you modified in the original post. (BTW, now I am looking at the code I would observe that you changed the code in the 'entry' part of the animation, not the exit, so I would suggest that you change it back).
To control the number of blank columns displayed after the scrolling message, the setScrollSpacing() method sets an internal variable that overrides this around line 130
if ((_scrollDistance != 0) && (maxCount > _scrollDistance)) maxCount = _scrollDistance;
This feature was added some time ago for someone who was looking for the same outcome as I understand you want, so it should work.
Note that the exit part of the code only becomes active when the message has ended the pause (which you have set to zero). Where it pauses will depend on what text justification you have set for the display - it looks to me like you have set LEFT justified. In this case the message will go to the left, pause (0) and then start to exit, at which time the check for the blank columns is done.
It seems to me that you probably need to set RIGHT justification so that the text goes into exit mode when it has fully entered the display wihtout going all the way to the other end. It would probably help you debug what is going on if you also temporarily enable the pause between animation entry and exit.
from md_parola.
Related Issues (20)
- strrev missing?? HOT 7
- CP437 Font File HOT 1
- Scrolling text one time HOT 1
- Interrupt text effect in anytime HOT 3
- Use of MD_parola HOT 2
- [QUESTION] turn specific pixel on or off? HOT 2
- Remanant residual text on Double_Height on 2x19 matrix HOT 5
- How can I change HARDWARE_TYPE and MAX_DEVICES from the loop depending on some integer variables HOT 1
- Pixel errors and display reset HOT 1
- For UNO r4 minima is this lib ported ? or just works as it is HOT 1
- I want to use Hindi font. How can i use ? HOT 1
- Display Clear is not working HOT 2
- issue on P.displayAnimate() parola HOT 3
- avr/io.h HOT 1
- access the dot display buffer before animation ? HOT 4
- Software SPI not working on Arduino Nano ESP32 HOT 2
- Is there a way to access the framebuffer directly? HOT 1
- Show RtcDS3231.h time on Max7219 HOT 9
- Can't Grow Down A Font Character as One Character When Using 2 FC16 Modules HOT 8
- Combination of text scroll with bitmap sprite animation HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from md_parola.