Jump to content
Sign in to follow this  
bspieg

Camera Bash Script to Change Camera Settings

Recommended Posts

I am interested in writing a bash script that runs on the camera to change the IR on/off based on sunset/sunrise data that gets updated daily. I have a similar script that runs on Ubuntu Linux where I have access to the curl command.

 

The camera OS lacks the curl command. Anyone got ideas on how to query an external website for sunrise/sunset info without the curl and grep commands?

 

Is there a command on the camera to directly change the camera settings such as IR on/off? I also need a direct way to change the event recording on/off. I turn off the event recording when the IR changes then turn it back on after the camera settles down.

 

Any thoughts, suggestions appreciated.

 

Thanks.

Share this post


Link to post
Share on other sites

I actually tried adding curl to a camera and it just didn't fit as the file systems are full. I can keep it mounted on a NAS for example and run it from there or if you have a camera with an SD card, you can run it from there.

 

A cheap and smarter alternative could be a Raspberry Pi, about $40 with sd card and power adapter. You can write a shell script to issue curl commands to control IR on a set of cameras. You can do it based on a calendar of dusk/dawn times so you can program it to control IR based on that information. You can google raspberry sunrise sunset timer. There's a couple of solutions that are well documented.

 

I was working on using a Raspberry Pi to issue a curl command with the temperature using a temp sensor and it works.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×