Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The ticker is choppy since MM 2.26 #64

Open
hesspoint opened this issue Jan 6, 2024 · 14 comments
Open

The ticker is choppy since MM 2.26 #64

hesspoint opened this issue Jan 6, 2024 · 14 comments
Labels
bug Something isn't working

Comments

@hesspoint
Copy link

Platform

Pi 4

Node.js Version

v18.18.0

MagicMirror Version

2.26

Module Version

lastest version

Description

I have been running the module for a few month w/out issues. Since I updated MM to 2.26 recently the ticker does not run smoothly anymore. It starts stopping ever second or so and then jumps a bit ahead. It is very choppy and nice to look at. Before it has never done that.

Expected behavior

No response

Current behavior

No response

Possible solution

No response

Steps to reproduce

same after every restart or Pi reboot

Log

No response

config.js

module: "MMM-Jast",
			position: "bottom_bar",
			config: {
				currencyStyle: "code", // One of ["code", "symbol", "name"]
				fadeSpeedInSeconds: 120,
				lastUpdateFormat: "HH:mm",
				maxChangeAge: 1 * 24 * 60 * 60 * 1000,
				maxWidth: "100%",
				numberDecimalsPercentages: 1,
				numberDecimalsValues: 2,
				scroll: "horizontal", // One of ["none", "vertical", "horizontal"]
				showColors: true,
				showCurrency: true,
				showChangePercent: true,
				showChangeValue: false,
				showChangeValueCurrency: false,
				showHiddenStocks: false,
				showLastUpdate: false,
				showPortfolioValue: false,
				showPortfolioGrowthPercent: false,
				showPortfolioGrowth: false,
				updateIntervalInSeconds: 300,
				useGrouping: false,
				virtualHorizontalMultiplier: 2,
				stocks: [
					{ name: "Tesla", symbol: "TSLA"},
					{ name: "Amazon", symbol: "AMZN"},
					{ name: "Apple", symbol: "AAPL"},
				]
			}

Additional info

No response

@hesspoint hesspoint added the bug Something isn't working label Jan 6, 2024
@jalibu
Copy link
Owner

jalibu commented Jan 8, 2024

Hi Hannes,
thank you for opening this issue.
I can not really explain why the rendering performance of the module could be related to the new MM version.
The rendering is done by the browser (these are normal CSS transition animations).

Probably, it could be that the general resource consumption is higher due to the new MM version and therefore less is left for rendering the ticker.

I don't have this problem, by the way.
We can wait and see if other affected people get in touch.

@stengelchristian
Copy link

stengelchristian commented Jan 19, 2024

I can´t say if it was better in the past but I can confirm that at least on a new (active cooled) PI5 with fresh install its irregularly choppy. BUT AV STOCK Module looks exactly the same. not sure what causes it. But I think its not really pi or mm related as the horizontal scroll is choppy in any browser just looking at the readme on github page as well on a mac or pc

@jalibu
Copy link
Owner

jalibu commented Jan 20, 2024

@stengelchristian what do you mean with that?

BUT AV STOCK Module looks exactly the same

@jalibu
Copy link
Owner

jalibu commented Jan 21, 2024

Hi @hesspoint @stengelchristian

can you please checkout the latest version and share your feedback? I made some changes in the horizontal scrolling

@stengelchristian
Copy link

stengelchristian commented Jan 21, 2024

@stengelchristian what do you mean with that?

BUT AV STOCK Module looks exactly the same

I was referring to the https://github.com/lavolp3/MMM-AVStock Module, which also has a horizontal scroll. The scrolling motion had the same choppy behavior from time to time.

I just checked out the 2.9.2 commit, and I would say that it is less choppy, occurring less frequently but I will check again tomorrow then it´s updating stock data and displaying more content.

thx for looking into it.

Edit: It is definitely a lot better

@KristjanESPERANTO
Copy link
Contributor

KristjanESPERANTO commented Jan 24, 2024

If it does occur again, you could perhaps try the following:

Instead of npm run start try export ELECTRON_ENABLE_GPU=1 && npm run start to start the mirror.

With MM 2.26.0 the GPU is disabled by default. This could be the reason why the horizontal scrolling is not running so smoothly since then.

@jalibu
Copy link
Owner

jalibu commented Jan 24, 2024

@sdetweil do you think it's worth thinking about adding this option to enable GPU rendering as an option for your installer scripts?

@sdetweil
Copy link
Contributor

@jalibu but it takes more than that. the drivers in /boot/config.txt need to be set correctly, as I understand it

@jalibu
Copy link
Owner

jalibu commented Jan 24, 2024

@sdetweil I thought you are the no-limits-scripting-magic-wonder-man 😁

@sdetweil
Copy link
Contributor

yes I can do lots of things.. IF I know what to do. for the video drivers I do NOT KNOW. seems like black.magic to me.

some drivers impact commands to manipulate display status

I know I can change the driver config on pi 4/5 to have two independent displays , instead of one big display over both monitors..

this is not my area of expertise.. I'll take advice and testing from others.

@hesspoint
Copy link
Author

If it does occur again, you could perhaps try the following:

Instead of npm run start try export ELECTRON_ENABLE_GPU=1 && npm run start to start the mirror.

With MM 2.26.0 the GPU is disabled by default. This could be the reason why the horizontal scrolling is not running so smoothly since then.

I have tried that and yes then it and it is much smoother. However it also is not entirely smooth but at least it does not do these weird jumps.

The issue is though that I start my MM via pm2. Not sure if I can somehow enable the GPU there.

Or is there a setting somewhere in the MM config where I can enable GPU?

@sdetweil
Copy link
Contributor

sdetweil commented Feb 15, 2024

@hesspoint put it in the script that pm2 launches.

if using my install script that is
~/MagicMirror/installers/mm sh

you can also find this thru the pm2 info command

pm2 status will give u the name and number of the managed apps

pm2 info name/number

look for script path

@BillYovino
Copy link

BillYovino commented Jul 17, 2024

Pi Zero 2W running Bullseye. I tried everything I could but the scrolling was still too jerky so I reverted back to my older version running on Buster which works fine. The vertical scrolling didn't look bad but I don't like how it behaves. It scrolls up one stock at a time but when it gets to the end of the list it scrolls down through all of them rapidly. A more natural way would just to continuously scroll up or down one at a time. I tried over-clocking but that yielded strange results and didn't fix the jerky motion.

@sdetweil
Copy link
Contributor

you may have to enable the gpu for scrolling to be smooth

in 2.27 we turned it OFF by default to prevent errors MOST users have.

in the script that launches MM add
export ELECTRON_ENABLE_GPU=1

before the npm start line

note you MAY have to change the /boot/config.txt to.make it work

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants