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

External program

From build 3044 the development baton passed to Mark Crossley. Mark has been responsible for all the Builds since. He has made the code available on GitHub. It is Mark's hope that others will join in this development, but at the very least he welcomes your ideas for future developments (see Cumulus MX Development suggestions).

Moderator: mcrossley

Post Reply
User avatar
PaulMy
Posts: 3827
Joined: Sun 28 Sep 2008 11:54 pm
Weather Station: Davis VP2 Plus 24-Hour FARS
Operating System: Windows8 and Windows10
Location: Komoka, ON Canada
Contact:

External program

Post by PaulMy »

I currently run Cumulusutils in the External program Daily program with the parameter as pwsFWI and this works great www.komokaweather.com/komokaweather-ca/wxFWI.php
In the settings this appears to be for a single run/parameter. How can I run this with additional parameters - i.e. maps so that this can also be updated once a day www.komokaweather.com/komokaweather-ca/wxMap.php

Thanks,
Paul
Davis Vantage Pro2+
C1 www.komokaweather.com/komokaweather-ca
MX www.komokaweather.com/cumulusmx/index.htm /index.html /index.php
MX www.komokaweather.com/cumulusmxwll/index.htm /index.html /index.php
MX www. komokaweather.com/cumulusmx4/index.htm
Image
User avatar
meteosangonera
Posts: 52
Joined: Thu 07 Jun 2018 2:17 pm
Weather Station: Davis Vantage Vue
Operating System: Windows 10
Contact:

Re: External program

Post by meteosangonera »

PaulMy wrote: Sat 16 Nov 2019 4:14 pm I currently run Cumulusutils in the External program Daily program with the parameter as pwsFWI and this works great www.komokaweather.com/komokaweather-ca/wxFWI.php
In the settings this appears to be for a single run/parameter. How can I run this with additional parameters - i.e. maps so that this can also be updated once a day www.komokaweather.com/komokaweather-ca/wxMap.php

Thanks,
Paul
You can use multiple parameter at the same time. You have to let a space between each parameter.
User avatar
PaulMy
Posts: 3827
Joined: Sun 28 Sep 2008 11:54 pm
Weather Station: Davis VP2 Plus 24-Hour FARS
Operating System: Windows8 and Windows10
Location: Komoka, ON Canada
Contact:

Re: External program

Post by PaulMy »

Thank you, I will add the other parameters.

Enjoy,
Paul
Davis Vantage Pro2+
C1 www.komokaweather.com/komokaweather-ca
MX www.komokaweather.com/cumulusmx/index.htm /index.html /index.php
MX www.komokaweather.com/cumulusmxwll/index.htm /index.html /index.php
MX www. komokaweather.com/cumulusmx4/index.htm
Image
Phil23
Posts: 884
Joined: Sat 16 Jul 2016 11:59 pm
Weather Station: Davis VP2+ & GW1000 (Standalone)
Operating System: Win10 Pro / rPi Buster
Location: Australia

Re: External program

Post by Phil23 »

I only have one external program run at end of day.

C:\CumulusMX\Scripts\DayEnd.bat

Then do all the stuff I want in that batch file.

Code: Select all

@echo off
echo Waiting a few seconds for End of Day to complete.

ping localhost -n 5 > nul

copy "\\WEATHER-PC\Cumulus\data\dayfile.txt" + "\\WEATHER-PC\CumulusMX\data\dayfile.txt" "\\WEATHER-PC\CumulusMX\Scripts\dayfile-merged.txt" /b /y

cd \cumulusmx
cumulusutils Top10 pwsFWI SysInfo Graphs MapsOn

ftp -s:"\\WEATHER-PC\CumulusMX\Scripts\ftp.txt"

Ping localhost -n 5 > nul
CD\

The FTP in Windows is fed by the command file ftp.txt

Code: Select all

open weather.inverellit.com
Username
Password
cd /public_html/weather/historic
put \\WEATHER-PC\CumulusMX\Scripts\dayfile-merged.txt dayfile.txt
cd /public_html/weather
put \\WEATHER-PC\CumulusMX\utils\pwsFWI.txt pwsFWI.txt
put \\WEATHER-PC\CumulusMX\utils\top10Table.txt top10Table.txt
put \\WEATHER-PC\CumulusMX\utils\graphs.txt graphs.txt
put \\WEATHER-PC\CumulusMX\utils\maps.txt maps.txt
put \\WEATHER-PC\CumulusMX\utils\pwsFWIanalyse.csv pwsFWIanalyse.csv
quit
Lets me run more than one command & a bit easier to manage.

Phil.
:Now: :Today/Yesterday:

Image

Main Station Davis VP2+ Running Via Win10 Pro.
Secondary Stations, Ecowitt HP2551/GW1000 Via rPi 3 & 4 Running Buster GUI.
:Local Inverell Ecowitt Station: :Remote Ashford Ecowitt Station:
User avatar
PaulMy
Posts: 3827
Joined: Sun 28 Sep 2008 11:54 pm
Weather Station: Davis VP2 Plus 24-Hour FARS
Operating System: Windows8 and Windows10
Location: Komoka, ON Canada
Contact:

Re: External program

Post by PaulMy »

I've tried the multi parameters and that works as each of pwsFWI, graphs, MapOn, SysInfo and Top10 were executed and the results files placed in the \utils folder, thanks for that suggestion.
However the timing of the external program execution and the End of Day FTP of the files are not in sync so the FTP was done before the cumulusutils.exe were executed causing the previous days files to be FTP.

I've looked at Phil's batch file which he indicates has a delay to wait a few seconds, but so far beyond my understanding how to put that together and use it.
I could have the files FTP at the Cumulus 5 min interval (all except maps) instead at end of day but that would be overkill.


Edit: just thought of a way, instead of CumulusMX Extra web files to FTP at End of day, use Cumulus Toolbox to FTP at a time after 12:00 am.

Enjoy,
Paul
Davis Vantage Pro2+
C1 www.komokaweather.com/komokaweather-ca
MX www.komokaweather.com/cumulusmx/index.htm /index.html /index.php
MX www.komokaweather.com/cumulusmxwll/index.htm /index.html /index.php
MX www. komokaweather.com/cumulusmx4/index.htm
Image
Phil23
Posts: 884
Joined: Sat 16 Jul 2016 11:59 pm
Weather Station: Davis VP2+ & GW1000 (Standalone)
Operating System: Win10 Pro / rPi Buster
Location: Australia

Re: External program

Post by Phil23 »

PaulMy wrote: Tue 19 Nov 2019 5:56 am I've looked at Phil's batch file which he indicates has a delay to wait a few seconds, but so far beyond my understanding how to put that together and use it.
It's pretty simple really.

Code: Select all

@echo off
That just stops the commands showing in the dos box.

Code: Select all

echo Waiting a few seconds for End of Day to complete.
Puts that message in the dos box. Like print...

Code: Select all

ping localhost -n 5 > nul
Just makes the PC ping it's self to create the delay

Code: Select all

cd \cumulusmx
cumulusutils Top10 pwsFWI SysInfo Graphs MapsOn
Changes to the MX folder & runs the cumulusutils

Code: Select all

ftp -s:"\\WEATHER-PC\CumulusMX\Scripts\ftp.txt"
Runs the windows FTP command with the commands in the FTP.txt file shown above.

You don't need a lot of the rest & you can see in my FTP.txt file above the list of files I am transferring.
:Now: :Today/Yesterday:

Image

Main Station Davis VP2+ Running Via Win10 Pro.
Secondary Stations, Ecowitt HP2551/GW1000 Via rPi 3 & 4 Running Buster GUI.
:Local Inverell Ecowitt Station: :Remote Ashford Ecowitt Station:
User avatar
HansR
Posts: 5957
Joined: Sat 20 Oct 2012 6:53 am
Weather Station: GW1100 (WS80/WH40)
Operating System: Raspberry OS/Bookworm
Location: Wagenborgen (NL)
Contact:

Re: External program

Post by HansR »

What happened to the sleep command? eg:

Code: Select all

Sleep 10
for a 10 second delay?
Gives more control and precision.
Hans

https://meteo-wagenborgen.nl
CMX build 4017+ ● RPi 3B+ ● Raspbian Linux 6.1.21-v7+ armv7l ● dotnet 8.0.3
Phil23
Posts: 884
Joined: Sat 16 Jul 2016 11:59 pm
Weather Station: Davis VP2+ & GW1000 (Standalone)
Operating System: Win10 Pro / rPi Buster
Location: Australia

Re: External program

Post by Phil23 »

HansR wrote: Wed 20 Nov 2019 8:37 am What happened to the sleep command?
Hmmm
The simple things we forget.....

That one must have long slipped out of my DOS command memory bank.

I do recall though that I had left the > NUL off initially for feedback during debugging.
:Now: :Today/Yesterday:

Image

Main Station Davis VP2+ Running Via Win10 Pro.
Secondary Stations, Ecowitt HP2551/GW1000 Via rPi 3 & 4 Running Buster GUI.
:Local Inverell Ecowitt Station: :Remote Ashford Ecowitt Station:
Phil23
Posts: 884
Joined: Sat 16 Jul 2016 11:59 pm
Weather Station: Davis VP2+ & GW1000 (Standalone)
Operating System: Win10 Pro / rPi Buster
Location: Australia

Re: External program

Post by Phil23 »

Just tried to refresh my brain a bit on a few dos commands.

Appears Sleep does not exist as an internal or default installed external command.

Apparently it was distributed in some Win Resource kits.

Win 7 & above include Timeout.

Timeout /t 10 [/nobreak]

It can be aborted with CTRL-C & in that case it will return an Errorlevel=1

Useful for jumping over bits.

Phil.
:Now: :Today/Yesterday:

Image

Main Station Davis VP2+ Running Via Win10 Pro.
Secondary Stations, Ecowitt HP2551/GW1000 Via rPi 3 & 4 Running Buster GUI.
:Local Inverell Ecowitt Station: :Remote Ashford Ecowitt Station:
User avatar
HansR
Posts: 5957
Joined: Sat 20 Oct 2012 6:53 am
Weather Station: GW1100 (WS80/WH40)
Operating System: Raspberry OS/Bookworm
Location: Wagenborgen (NL)
Contact:

Re: External program

Post by HansR »

Mmm... Must have been win10 too long :)
Hans

https://meteo-wagenborgen.nl
CMX build 4017+ ● RPi 3B+ ● Raspbian Linux 6.1.21-v7+ armv7l ● dotnet 8.0.3
User avatar
PaulMy
Posts: 3827
Joined: Sun 28 Sep 2008 11:54 pm
Weather Station: Davis VP2 Plus 24-Hour FARS
Operating System: Windows8 and Windows10
Location: Komoka, ON Canada
Contact:

Re: External program

Post by PaulMy »

Using CumulusMX External programs Daily program works great with the 5 parameters. Cumulus Toolbox with FTP at shortly after midnight then updates on webserver for all 8 files. The only obstacle is the processing of the systeminfoTable.txt file before the FTP. Hoping my sequence order allows for processing before FTP. I will know after midnight.

As you can detect, I am hesitate :oops: to implement a Windows scheduler and DOS batch file.

Enjoy,
Paul
Davis Vantage Pro2+
C1 www.komokaweather.com/komokaweather-ca
MX www.komokaweather.com/cumulusmx/index.htm /index.html /index.php
MX www.komokaweather.com/cumulusmxwll/index.htm /index.html /index.php
MX www. komokaweather.com/cumulusmx4/index.htm
Image
Phil23
Posts: 884
Joined: Sat 16 Jul 2016 11:59 pm
Weather Station: Davis VP2+ & GW1000 (Standalone)
Operating System: Win10 Pro / rPi Buster
Location: Australia

Re: External program

Post by Phil23 »

PaulMy wrote: Wed 20 Nov 2019 9:52 pm As you can detect, I am hesitate :oops: to implement a Windows scheduler and DOS batch file.
In that case why not experiment a bit with some simple stuff to try.

Stuff that won't impact your data.

Start out with a batch file like this....
(Call it Test.bat)

Code: Select all

pause
Echo Hello
Dir C:\
pause
Then work out how to schedule it & set it to run a minute of two from the time when you are testing.

As you get the hang try adding other things that will not use your data until you get confident.

Phil
:Now: :Today/Yesterday:

Image

Main Station Davis VP2+ Running Via Win10 Pro.
Secondary Stations, Ecowitt HP2551/GW1000 Via rPi 3 & 4 Running Buster GUI.
:Local Inverell Ecowitt Station: :Remote Ashford Ecowitt Station:
Post Reply