Skip to main content

Can I use Alarm Task Script for JPEG post to FTP every 30 minutes?

Related Products

All IP encoders

Question

Can I use Alarm Task Script for JPEG post to FTP every 30 minutes?

Answer

Copy/ Paste this example into the alarm task editor and save.  See comments below for more details, annotated by //.

JpegPosting PicPosting := {IP("ftp.example.com") // Replace with your FTP server IP or hostname
Login("username") // Replace with FTP username
Password("password") // Replace with FTP password
Format(Large)
FileName("Snap")
Suffix(Date)
Camera(All)
};

// Define periodic operation: 30 minutes (1800 sec = 1800000 ms)
OperationMode periodic := { Low(1800000) High(1000) }; // High = 1 second for snapshot trigger

// Initialize temp state with periodic trigger
TempState(1) := periodic;

// Trigger JPEG posting only during the High period
if (TempState(1)) then
PicPosting;

(info) Notes:

  1. Replace "ftp.example.com", "username", and "password" with your actual FTP credentials.

  2. Make sure the camera supports Alarm Task Scripting and JPEGPosting.

  3. Save and enable the Alarm Task; it should now upload one JPEG every 30 minutes automatically.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.