Auto Download Your C3 Videos Will Check Every 5 minutes for New Videos

Eyezenheim
4 min readFeb 23, 2023
  1. Download and Install Winscp https://winscp.net/eng/index.php

Convert github id_rsa to putty (.ppk)

Look for your id_rsa file and winscp will prompt you to convert it .ppk

2. Open Notepad copy/paste. Replace private key and local directory with yours . My private key is C:\.ssh\id_rsa.ppk and local directory is D:\videos

option batch abort
option confirm off
open sftp://comma@192.168.1.27:8022/ -privatekey=”C:\.ssh\id_rsa.ppk”
synchronize local D:\videos /data/media/0/realdata
exit

3. Save as ‘sync.txt’ inside Winscp folder

4. Open Notepad again and paste the following:

winscp.com /script=sync.txt

Save it as ‘sync.bat’ in the same Winscp folder.

5. Let’s Automate. Goto Search in Windows and type Task Scheduler

6. Open and Choose Create Basic Task

7. Give it a name

8. For Trigger Choose Daily

9. Choose your starting time.

10. Action is Start a Program.

11. Program Script is ‘sync.bat’.

12. In Start in (optional): is the location of ‘sync.bat’ which is ‘C:\Program Files (x86)\WinSCP’ for me.

13. Hit finish.

14. Choose Sync and hit RUN to check if it’s working.

15. A pop up window should appear with a download progress.

16. Here’s the downloaded C3 Realdata folders.

so it worked!

17. Go back to Task window and double click ‘Sync’ task .

18. Go to Triggers and click Edit.

19. Choose Repeat task Every 5 minutes / Indefinitely. It’s up to you on what to put here.

20. There you have it folks , it will check for NEW realdata folders every 5 minutes.

21. I use Potplayer for the hevc files .

22. Here’s my Trigger

Will start checking at 5:38am daily, I get home around that time. And check every 5 minutes for one hour duration.

--

--