I have "odometer" to display WindRun in WindSpeed gauge
http://www.meteobellaria.it/stazione1/gaugesSS.php
-Odometer display "value A"
-Windrun data change (from "value A" to "value B")
-Countdown refresh timer go to 0
-Odometer display "value B"
The transition from value A to B should be "animated" as in the demo page? [http://www.wilmslowastro.com/steelserie ... xtras.html]
On my web page the transition is not "animated", I see value A and the value B
Welcome to the Cumulus Support forum.
Latest Cumulus MX V4 release 4.4.2 (build 4085) - 12 March 2025
Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024
Legacy Cumulus 1 release 1.9.4 (build 1099) - 28 November 2014
(a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)
Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki
If you are posting a new Topic about an error or if you need help PLEASE read this first viewtopic.php?p=164080#p164080
Latest Cumulus MX V4 release 4.4.2 (build 4085) - 12 March 2025
Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024
Legacy Cumulus 1 release 1.9.4 (build 1099) - 28 November 2014
(a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)
Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki
If you are posting a new Topic about an error or if you need help PLEASE read this first viewtopic.php?p=164080#p164080
Wind Run <-> odometer
Moderator: mcrossley
-
CrasHBoneS
- Posts: 96
- Joined: Fri 06 Jan 2012 10:49 am
- Weather Station: PCE-FWS20
- Operating System: Windows XP SP3
- Location: Bellaria Igea Marina (RN)
- Contact:
- mcrossley
- Posts: 14384
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: Wind Run <-> odometer
Ah yes, the odometer embedded in the Radial gauge only supports .setValue() and not .setValueAnimated() - I'll get that added to the SS library.
The standalone odometer does support .setValueAnimated().
The standalone odometer does support .setValueAnimated().
-
CrasHBoneS
- Posts: 96
- Joined: Fri 06 Jan 2012 10:49 am
- Weather Station: PCE-FWS20
- Operating System: Windows XP SP3
- Location: Bellaria Igea Marina (RN)
- Contact:
Re: Wind Run <-> odometer
Thank You for the answer!
I modified steeleseries.js and it's working with animated transistion
Before
// Draw lcd display
if (lcdVisible) {
if (useOdometer) {
odoGauge.setValue(odometerUseValue ? value : odoValue);
mainCtx.drawImage(odoBuffer, odoPosX, odoPosY);
} else {
drawLcdText(value);
}
}
After
// Draw lcd display
if (lcdVisible) {
if (useOdometer) {
odoGauge.setValueAnimated(odometerUseValue ? value : odoValue);
mainCtx.drawImage(odoBuffer, odoPosX, odoPosY);
} else {
drawLcdText(value);
}
}
I modified steeleseries.js and it's working with animated transistion
Before
// Draw lcd display
if (lcdVisible) {
if (useOdometer) {
odoGauge.setValue(odometerUseValue ? value : odoValue);
mainCtx.drawImage(odoBuffer, odoPosX, odoPosY);
} else {
drawLcdText(value);
}
}
After
// Draw lcd display
if (lcdVisible) {
if (useOdometer) {
odoGauge.setValueAnimated(odometerUseValue ? value : odoValue);
mainCtx.drawImage(odoBuffer, odoPosX, odoPosY);
} else {
drawLcdText(value);
}
}
- mcrossley
- Posts: 14384
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: Wind Run <-> odometer
Hmm, I looked at implementing setValueAnimated() in Radial gauges - it's not trivial and probably why I didn't do it first time round. You will find your solution doesn't work properly. It will be more reliable if you change the tween timer in odometer...
To implement this properly is going to require implementing callbacks from the odometer component to the radial gauge 
Code: Select all
from
tween = new Tween({}, '', Tween.strongEaseOut, value, newVal, 2);
to
tween = new Tween({}, '', Tween.strongEaseOut, value, newVal, 1);