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

Uploading .mp4 timelapse at end of the day

From Cumulus MX version 3 build 3044 the development baton passed to Mark Crossley. Mark has been responsible for all the Builds since, and has recently released Cumulus MX version 4. 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
Nottub
Posts: 227
Joined: Fri 04 Dec 2020 4:35 pm
Weather Station: Davis VP2 (Cabled)
Operating System: RPi 4 (Bookworm)
Contact:

Uploading .mp4 timelapse at end of the day

Post by Nottub »

A little issue you may be able to give me some guidance on.

I have created a couple of scripts to take a snapshot from my webcam every minute through the day and annotate the captured image with the current date and time. Then at the end of the day another script takes those images and converts them into a timelapse .mp4.

I have set up (in the 'Extra Webfiles') to upload at the end of the day to my web host.

These fail with the message 'Unprocessable entity' or something similar. However if I select 'Real Time' it does upload. I don't leave 'Real Time' selected once it has uploaded.

The message in the diagnostic log (attached) reads at 09:00:17

Code: Select all

Error: TimeStamp is out of date
Data TS   = 1740646802
Server TS = 1740646817
It does initiate at 09:00:02 but errors 15s later. A guide perhaps WRT the Timestamps recorded at initiation and failure of the transfer.

The log may be able to show more but I can't see anything. Perhaps the file size (19Mb) is just too big?

Any help appreciated.

Martyn
You do not have the required permissions to view the files attached to this post.
Image
Nottub
Posts: 227
Joined: Fri 04 Dec 2020 4:35 pm
Weather Station: Davis VP2 (Cabled)
Operating System: RPi 4 (Bookworm)
Contact:

Re: Uploading .mp4 timelapse at end of the day

Post by Nottub »

Just to confirm the upload again failed this morning. here is the error as reported in the 'Latest errors' :

Code: Select all

2025-02-28 09:00:52 - PHP[Int]: HTTP Error uploading to images/timelapse.mp4: Response code = 422: UnprocessableEntity
Not sure if this helps.


Thanks
Martyn
Image
water01
Posts: 3669
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: Ecowitt HP2551
Operating System: Windows 10/11 64bit Synology NAS
Location: Burnham-on-Sea
Contact:

Re: Uploading .mp4 timelapse at end of the day

Post by water01 »

Are you uploading it as a Binary file?
David
Image
User avatar
mcrossley
Posts: 14382
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Uploading .mp4 timelapse at end of the day

Post by mcrossley »

It looks like you are running an old version of upload.php. Please update it to the latest in the /webfiles folder.

If that does not fix the problem - the timeout is increased to 20 seconds in the latest version of upload.php - then we can look at this further.
Nottub
Posts: 227
Joined: Fri 04 Dec 2020 4:35 pm
Weather Station: Davis VP2 (Cabled)
Operating System: RPi 4 (Bookworm)
Contact:

Re: Uploading .mp4 timelapse at end of the day

Post by Nottub »

water01 wrote: Fri 28 Feb 2025 9:41 am Are you uploading it as a Binary file?
Hi, the upload is set as a Binary. 👍

Mark, the upload.php is the version which came with CMX 4.3.3 b4070. Do I need to update it somewhere else?

EDIT: I have just updated the php version with IONOS from 8.2 to 8.3.

Within the upload.php file is at line 77:

Code: Select all

If  (abs ($receivedTime - $requestTime) >20). {

Does this mean that it is the later version?

Many thanks for your suggestions

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

Re: Uploading .mp4 timelapse at end of the day

Post by mcrossley »

It still appears to be an older version. The latest is dated "2024/11/28 17:56:02" on line 2

Yes line 77 should be > 20
Nottub
Posts: 227
Joined: Fri 04 Dec 2020 4:35 pm
Weather Station: Davis VP2 (Cabled)
Operating System: RPi 4 (Bookworm)
Contact:

Re: Uploading .mp4 timelapse at end of the day

Post by Nottub »

mcrossley wrote: Fri 28 Feb 2025 11:56 am It still appears to be an older version. The latest is dated "2024/11/28 17:56:02" on line 2

Yes line 77 should be > 20
I can see that Mark thanks for pointing out what I'm looking for. But how do I update it in CMX?

I have just a few minutes ago updated the version in IONOS (my provider). Will this auto update in CMX when I restart?

If not I don't know how to update the version that CMX uses.

Thanks

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

Re: Uploading .mp4 timelapse at end of the day

Post by mcrossley »

You just need to put your "secret" into the upload.php file, then copy it up to your web server. Cumulus Will just start using it.

You can check it is on your server by loading the script in a web browser: https://www.calvertoncam.co.uk/weather/upload.php

Newer versions report the script version and your PHP version in the response.
Old versions do not, you just get "Welcome to upload.php" and a load of "x"'s.
Nottub
Posts: 227
Joined: Fri 04 Dec 2020 4:35 pm
Weather Station: Davis VP2 (Cabled)
Operating System: RPi 4 (Bookworm)
Contact:

Re: Uploading .mp4 timelapse at end of the day

Post by Nottub »

mcrossley wrote: Fri 28 Feb 2025 12:09 pm You just need to put your "secret" into the upload.php file, then copy it up to your web server. Cumulus Will just start using it.

You can check it is on your server by loading the script in a web browser: https://www.calvertoncam.co.uk/weather/upload.php

Newer versions report the script version and your PHP version in the response.
Old versions do not, you just get "Welcome to upload.php" and a load of "x"'s.
Thanks Mark, I have re-uploaded the upload.php file with the 'secret' and I do now get the 'welcome', a 'version number' of 2024/11/28 17:56:02, and an 'Engine' number of 8.3.17, then a lot of XXXX's.

Hopefully that's now up to date!

I didn't realise I had to update the upload.php 'secret' again.
My other .php transfers have been working OK though.

Lets see what this update does.

Thanks again for giving up your time.

Martyn
Image
Nottub
Posts: 227
Joined: Fri 04 Dec 2020 4:35 pm
Weather Station: Davis VP2 (Cabled)
Operating System: RPi 4 (Bookworm)
Contact:

Re: Uploading .mp4 timelapse at end of the day

Post by Nottub »

I thought I would post back to confirm that this mornings upload of my timelapse using CMX worked fine, with no error messages.

Fingers crossed that this continues.
https://www.calvertoncam.co.uk/weather/ ... elapse.mp4

Now need to a bit of fine tuning and get my old webcam up and running looking westwards.

Remarkable all this on a RPi.

Thanks
Martyn
Image
Post Reply