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
Pressure Trends converted to words in Cumulus
-
RayProudfoot
- Posts: 3602
- Joined: Wed 06 May 2009 6:29 pm
- Weather Station: Davis VP2 with Daytime FARS
- Operating System: Windows XP SP3
- Location: Cheadle Hulme, Cheshire, England
- Contact:
Pressure Trends converted to words in Cumulus
Now that I've got the code in my signature banner to describe pressure trends I'm keen to make it match an official Met Office standard.
Here are the rules according to the UK Met Office...
Rising (or falling) slowly
Pressure change of 0.1 to 1.5 hPa in the preceding three hours
Rising (or falling)
Pressure change of 1.6 to 3.5 hPa in the preceding three hours
Rising (or falling) quickly
Pressure change of 3.6 to 6.0 hPa in the preceding three hours
Rising (or falling) v. rapidly
Pressure change of more than 6.0 hPa in the preceding three hours
The highest rise I've seen is a little over 2hPa/hour and this was described by Cumulus as Rising Rapidly but according to the rules above it would have to be rising greater than 6 hPa/hour. They don't have a rule for steady so I guess that would be 0 over the last 3 hours.
Comments welcome.
Here are the rules according to the UK Met Office...
Rising (or falling) slowly
Pressure change of 0.1 to 1.5 hPa in the preceding three hours
Rising (or falling)
Pressure change of 1.6 to 3.5 hPa in the preceding three hours
Rising (or falling) quickly
Pressure change of 3.6 to 6.0 hPa in the preceding three hours
Rising (or falling) v. rapidly
Pressure change of more than 6.0 hPa in the preceding three hours
The highest rise I've seen is a little over 2hPa/hour and this was described by Cumulus as Rising Rapidly but according to the rules above it would have to be rising greater than 6 hPa/hour. They don't have a rule for steady so I guess that would be 0 over the last 3 hours.
Comments welcome.
- daj
- Posts: 2041
- Joined: Tue 29 Jul 2008 8:00 pm
- Weather Station: WH1081
- Operating System: Pi & MX
- Location: SW Scotland
- Contact:
Re: Pressure Trends converted to words in Cumulus
From what I can see on a previos post, Cumulus uses the same rules
https://cumulus.hosiene.co.uk/viewtopic.p ... 755#p36755
Maybe you could post a snapshot of your monthly log file covering the period you are questioning.
https://cumulus.hosiene.co.uk/viewtopic.p ... 755#p36755
Maybe you could post a snapshot of your monthly log file covering the period you are questioning.
- nking
- Posts: 813
- Joined: Thu 17 Dec 2009 2:03 pm
- Weather Station: W-8681
- Operating System: Windows 10
- Location: Hurstpierpoint, West Sussex, UK
- Contact:
Re: Pressure Trends converted to words in Cumulus
Met 3 hours, Cumulus 1 hour (average last 3 hours). They are the sameRayProudfoot wrote:Now that I've got the code in my signature banner to describe pressure trends I'm keen to make it match an official Met Office standard.
Pressure change of more than 6.0 hPa in the preceding three hours
The highest rise I've seen is a little over 2hPa/hour and this was described by Cumulus as Rising Rapidly but according to the rules above it would have to be rising greater than 6 hPa/hour. They don't have a rule for steady so I guess that would be 0 over the last 3 hours.
Comments welcome.
-
RayProudfoot
- Posts: 3602
- Joined: Wed 06 May 2009 6:29 pm
- Weather Station: Davis VP2 with Daytime FARS
- Operating System: Windows XP SP3
- Location: Cheadle Hulme, Cheshire, England
- Contact:
Re: Pressure Trends converted to words in Cumulus
Thanks for that David. That code is different to what betelguise supplied to me last night because of this 3 hour thing. It might be easier if I post what I now have.
$weather_trend = ret_value("presstrend") * 3;
if (($weather_trend >= -0.1) && ($weather_trend <= 0.1)) {
$pressure_trend_text = "Steady";
}
if (($weather_trend > 0.1) && ($weather_trend <= 1.5 )) {
$pressure_trend_text = "Rising Slowly";
}
if (($weather_trend > 1.5) && ($weather_trend <= 3.5 )) {
$pressure_trend_text = "Rising";
}
if (($weather_trend > 3.5) && ($weather_trend <= 6.0 )) {
$pressure_trend_text = "Rising Quickly";
}
if (weather_trend >= 6.0) {
$pressure_trend_text = "Rising Rapidly"; // rising rapidly
}
if (($weather_trend < -0.1) && ($weather_trend >= -1.5)) {
$pressure_trend_text = "Falling Slowly";
}
if (($weather_trend < -1.5) && ($weather_trend >= -3.5)) {
$pressure_trend_text = "Falling";
}
if (($weather_trend < -3.5) && ($weather_trend > -6.0)) {
$pressure_trend_text = "Falling Quickly";
}
if ($weather_trend <= -6.0) {
$pressure_trend_text = "Falling Rapidly"; // falling rapidly
}
That's as close as I can get to the Met Office (and Cumulus) standards although I tweaked the Steady value slightly.
$weather_trend = ret_value("presstrend") * 3;
if (($weather_trend >= -0.1) && ($weather_trend <= 0.1)) {
$pressure_trend_text = "Steady";
}
if (($weather_trend > 0.1) && ($weather_trend <= 1.5 )) {
$pressure_trend_text = "Rising Slowly";
}
if (($weather_trend > 1.5) && ($weather_trend <= 3.5 )) {
$pressure_trend_text = "Rising";
}
if (($weather_trend > 3.5) && ($weather_trend <= 6.0 )) {
$pressure_trend_text = "Rising Quickly";
}
if (weather_trend >= 6.0) {
$pressure_trend_text = "Rising Rapidly"; // rising rapidly
}
if (($weather_trend < -0.1) && ($weather_trend >= -1.5)) {
$pressure_trend_text = "Falling Slowly";
}
if (($weather_trend < -1.5) && ($weather_trend >= -3.5)) {
$pressure_trend_text = "Falling";
}
if (($weather_trend < -3.5) && ($weather_trend > -6.0)) {
$pressure_trend_text = "Falling Quickly";
}
if ($weather_trend <= -6.0) {
$pressure_trend_text = "Falling Rapidly"; // falling rapidly
}
That's as close as I can get to the Met Office (and Cumulus) standards although I tweaked the Steady value slightly.
-
RayProudfoot
- Posts: 3602
- Joined: Wed 06 May 2009 6:29 pm
- Weather Station: Davis VP2 with Daytime FARS
- Operating System: Windows XP SP3
- Location: Cheadle Hulme, Cheshire, England
- Contact:
Re: Pressure Trends converted to words in Cumulus
Thanks Neil. I think the code in the previous message sticks to those rules.nking wrote: Met 3 hours, Cumulus 1 hour (average last 3 hours). They are the same
- daj
- Posts: 2041
- Joined: Tue 29 Jul 2008 8:00 pm
- Weather Station: WH1081
- Operating System: Pi & MX
- Location: SW Scotland
- Contact:
Re: Pressure Trends converted to words in Cumulus
I'm confused. Why the code? Cumulus provides the trend in a web tag so you can use the surely?
-
RayProudfoot
- Posts: 3602
- Joined: Wed 06 May 2009 6:29 pm
- Weather Station: Davis VP2 with Daytime FARS
- Operating System: Windows XP SP3
- Location: Cheadle Hulme, Cheshire, England
- Contact:
Re: Pressure Trends converted to words in Cumulus
I thought that but it didn't work. Have a read through this thread and you can see why I ended up using code. It starts around the 5th message.daj wrote:I'm confused. Why the code? Cumulus provides the trend in a web tag so you can use the surely?
- daj
- Posts: 2041
- Joined: Tue 29 Jul 2008 8:00 pm
- Weather Station: WH1081
- Operating System: Pi & MX
- Location: SW Scotland
- Contact:
Re: Pressure Trends converted to words in Cumulus
Ah, right. I am late to the party and not basing my reply on any other thread as I did not know (and my crystal ball being at the cleaners lol)
If it were me I would create my own realtime file using web tags and include the pressure trend tag.
Equally, the php solution should get you there -- As with most things in life, there are several ways of achieving the same goal.
If it were me I would create my own realtime file using web tags and include the pressure trend tag.
Equally, the php solution should get you there -- As with most things in life, there are several ways of achieving the same goal.
-
RayProudfoot
- Posts: 3602
- Joined: Wed 06 May 2009 6:29 pm
- Weather Station: Davis VP2 with Daytime FARS
- Operating System: Windows XP SP3
- Location: Cheadle Hulme, Cheshire, England
- Contact:
Re: Pressure Trends converted to words in Cumulus
When one is as experienced as you David there will be alternative solutions but for this beginner I'm just pleased that what I have been given works.
When retirement beckons and I have more time I want to get into this a lot more. But for now, making small tweaks helps me understand a little at a time.
When retirement beckons and I have more time I want to get into this a lot more. But for now, making small tweaks helps me understand a little at a time.
- daj
- Posts: 2041
- Joined: Tue 29 Jul 2008 8:00 pm
- Weather Station: WH1081
- Operating System: Pi & MX
- Location: SW Scotland
- Contact:
Re: Pressure Trends converted to words in Cumulus
Of course I should have realised at the start of the post that we were discussing the realtime file as it was to do with the banner -- and I know the banner user realtime.txt, which doesn't include the trend in words!
I will go to the back of the class.
I will go to the back of the class.
- nking
- Posts: 813
- Joined: Thu 17 Dec 2009 2:03 pm
- Weather Station: W-8681
- Operating System: Windows 10
- Location: Hurstpierpoint, West Sussex, UK
- Contact:
Re: Pressure Trends converted to words in Cumulus
Ditto thatRayProudfoot wrote:When one is as experienced as you David there will be alternative solutions but for this beginner I'm just pleased that what I have been given works.![]()
When retirement beckons and I have more time I want to get into this a lot more. But for now, making small tweaks helps me understand a little at a time.
Do you feel a lesson coming on David - explaining how to create your own realtime file etc.
-
RayProudfoot
- Posts: 3602
- Joined: Wed 06 May 2009 6:29 pm
- Weather Station: Davis VP2 with Daytime FARS
- Operating System: Windows XP SP3
- Location: Cheadle Hulme, Cheshire, England
- Contact:
Re: Pressure Trends converted to words in Cumulus
I did look through the variables in the Wiki help but it didn't list pressuretrendenglish which I believe is what is used on the main Cumulus page. It was then that the penny dropped that code was probably the only way to achieve what I wanted.
Maybe that's something that could be looked at? Not sure whether it's possible or not.
- mcrossley
- Posts: 14388
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: Pressure Trends converted to words in Cumulus
Wouldn't Steve's code be more efficent - it stops testing values as soon as it finds a match.
Code: Select all
$weather_trend = ret_value("presstrend") * 3;
if ($weather_trend >= 6.0)
$pressure_trend_text = "Rising Rapidly";
elseif ($weather_trend > 3.5)
$pressure_trend_text = "Rising Quickly";
elseif ($weather_trend > 1.5)
$pressure_trend_text = "Rising";
else if ($weather_trend > 0.1)
$pressure_trend_text = "Rising Slowly";
elseif ($weather_trend > -0.1)
$pressure_trend_text = "Steady";
elseif ($weather_trend > -1.5)
$pressure_trend_text = "Falling Slowly";
elseif ($weather_trend > -3.5)
$pressure_trend_text = "Falling";
elseif ($weather_trend > -6.0)
$pressure_trend_text = "Falling Quickly";
else
$pressure_trend_text = "Falling Rapidly";
-
RayProudfoot
- Posts: 3602
- Joined: Wed 06 May 2009 6:29 pm
- Weather Station: Davis VP2 with Daytime FARS
- Operating System: Windows XP SP3
- Location: Cheadle Hulme, Cheshire, England
- Contact:
Re: Pressure Trends converted to words in Cumulus
Indeed it would Mark. Thanks! 
- daj
- Posts: 2041
- Joined: Tue 29 Jul 2008 8:00 pm
- Weather Station: WH1081
- Operating System: Pi & MX
- Location: SW Scotland
- Contact:
Re: Pressure Trends converted to words in Cumulus
Will do!nking wrote:Do you feel a lesson coming on David - explaining how to create your own realtime file etc.