Welcome to the Cumulus Support forum.

Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024

Cumulus MX V4 beta test release 4.0.0 (build 4019) - 03 April 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

v2.1.0 install

Discussion of Mark Crossley's HTML5/Javascript gauges

Moderator: mcrossley

User avatar
mcrossley
Posts: 12756
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: v2.1.0 install

Post by mcrossley »

gemini06720 wrote:... I also moved the odometer further down and centered - that new location was necessary as the odometer on my underdevelopment web pages (you know where to look if you need to check/see ;) ) was way off due to the larger size of the wind rose gauge.
Interesting Ray, I have scaled up the gauges to 500px and the odometer position seems to behave for me?
duke

Re: v2.1.0 install

Post by duke »

Mark, looking at yours and Rays pages, why does the word 'windrose', the letter 'N' and the 'scale' get fainter towards the top of the windrose gauge?
I also moved the odometer further down and centered - was way off due to the larger size of the wind rose gauge.
I had that problem too, rectified now.
User avatar
mcrossley
Posts: 12756
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: v2.1.0 install

Post by mcrossley »

The 'fading' is because of the gauge foreground - the simulated 'shine' on the glass.

How are you and Ray 'rectifying' the odometer positioning?
duke

Re: v2.1.0 install

Post by duke »

Here are the changes I made. Although I have positioned mine different to Ray and resized (PM sent).

Code: Select all

// Create an odometer
                if (_showOdo) {
                    _odoHeight = Math.ceil(size * 0.07); // Sets the size of the odometer
                    _odoWidth = Math.ceil(Math.floor(_odoHeight * 0.6) * _odoDigits);  // 'Magic' numbers, do not alter
                    // Create a new canvas for the oodometer
                    _canvasOdo = document.createElement('canvas');
                    $(_canvasOdo).attr({
                        'id': 'canvas_odo',
                        'width': _odoWidth,
                        'height': _odoHeight
                    });
                    // Position it
                    $(_canvasOdo).css({
                        'position': 'absolute',
                        'top': Math.ceil(size * 0.77) + 'px',
                        'left': Math.ceil((size - _odoWidth) / 1.8) + 'px'
                    });
Is it possible to decrease the 'shine' on the glass? I am failing to find where that is?
water01
Posts: 3246
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: Ecowitt HP2551
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: v2.1.0 install

Post by water01 »

I don't see a Windrose gauge on your site, so what does that code refer to?
David
Image
duke

Re: v2.1.0 install

Post by duke »

water01 wrote:I don't see a Windrose gauge on your site, so what does that code refer to?
That is how I modified the code in the 'windrose.js' to reposition/resize the 'odo' on an experimental gauges page.
User avatar
dimitris vichos
Posts: 94
Joined: Fri 21 Oct 2011 5:29 pm
Weather Station: wh 1080
Operating System: linux mint 19
Location: nea moudania chalkidiki grecce
Contact:

Re: v2.1.0 install

Post by dimitris vichos »

i was upload the 2.1.0 version. everything works good but the Wind Run odometer, apears in the wind speed gauge not in the winrose gauge

http://www.snowguide.gr/nea-moudania/liveweather.htm
Meteostation of Nea Moudania Chalkidiki Greece
https://kairos.moudania.com/index.php
water01
Posts: 3246
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: Ecowitt HP2551
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: v2.1.0 install

Post by water01 »

I got this wrong as well you have forgotten to upgrade the gauges-ss.css file.
David
Image
User avatar
mcrossley
Posts: 12756
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: v2.1.0 install

Post by mcrossley »

OK, I have figured out why people are having problems with the odometer positioning (it's all to do with element padding, and an incorrect 'magic number' on my part, I have a general solution that I will put in the next release if it proves robust. The code is below if you would try it please...
windrose.js
You do not have the required permissions to view the files attached to this post.
duke

Re: v2.1.0 install

Post by duke »

mcrossley wrote:OK, I have figured out why people are having problems with the odometer positioning (it's all to do with element padding, and an incorrect 'magic number' on my part, I have a general solution that I will put in the next release if it proves robust. The code is below if you would try it please...
windrose.js
Works fine for me Mark (on the link I sent you). I have just altered the gauge size in the script.
User avatar
dimitris vichos
Posts: 94
Joined: Fri 21 Oct 2011 5:29 pm
Weather Station: wh 1080
Operating System: linux mint 19
Location: nea moudania chalkidiki grecce
Contact:

Re: v2.1.0 install

Post by dimitris vichos »

i just do this. the odometer still apears in wind speed gauge
Meteostation of Nea Moudania Chalkidiki Greece
https://kairos.moudania.com/index.php
water01
Posts: 3246
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: Ecowitt HP2551
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: v2.1.0 install

Post by water01 »

water01 wrote:I got this wrong as well you have forgotten to upgrade the gauges-ss.css file.

Did you do this?
David
Image
water01
Posts: 3246
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: Ecowitt HP2551
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: v2.1.0 install

Post by water01 »

Works fine Mark.
David
Image
User avatar
mcrossley
Posts: 12756
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: v2.1.0 install

Post by mcrossley »

dimitris vichos wrote:i just do this. the odometer still apears in wind speed gauge
Hi Dimitris, it would really help if you put a link to your web site either in your profile or signature...
User avatar
dimitris vichos
Posts: 94
Joined: Fri 21 Oct 2011 5:29 pm
Weather Station: wh 1080
Operating System: linux mint 19
Location: nea moudania chalkidiki grecce
Contact:

Re: v2.1.0 install

Post by dimitris vichos »

mcrossley wrote:
dimitris vichos wrote:i just do this. the odometer still apears in wind speed gauge
Hi Dimitris, it would really help if you put a link to your web site either in your profile or signature...
i just do this.
Meteostation of Nea Moudania Chalkidiki Greece
https://kairos.moudania.com/index.php
Post Reply