Set up Blue Iris Surveillance software with IFTTT

I have two cameras in which I’d like to always have a notification for if I’m not home. Initially I set this up to always send me an alert but I’m sure as you can imagine, my phone blew up with me walking around. Blue Iris has a neat feature which is simply a traffic light. If red, it will disable various things including recording (not desired for me in this case), but it can also disable alerts. I selected to only disable alerts if the traffic light is red. In the past, I had never used this feature. So here’s a brief how-to.

Click settings button and modify the settings as illustrated.

Set User Account that will perform this action.

Set Traffic Signal to Alerts Only

Verify web server port & disable Secure only for the web server

  1. On your server computer (Blue Iris Windows machine), install something like WAMP or XAMPP to handle web requests.
  2. After install set up a script similar to this one in PHP (create a php file with the name of your choice and .php extension):
    1. After you’ve created the script, drop it in your HTDOCs directory in WAMP or XAMPP
      1. For example, my directory is here: C:\Bitnami\wampstack-7.1.19-0\apache2\htdocs
$home = $_GET['home']; //get and set variable for the home status.
$my_file = 'log.txt'; //store logs so we know if our server is being used improperly and by whom

if($home == 'true')
	$handle = fopen($my_file, 'a') or die('Cannot open file:  '.$my_file);
	$data = date("Y.m.d.h.i.s") . ' on requesting ip: ' . $_SERVER['REMOTE_ADDR'] . ' Request to set RED.' . "\r\n";
	fwrite($handle, $data);
	echo "home";
elseif($home == 'false')
	$handle = fopen($my_file, 'a') or die('Cannot open file:  '.$my_file);
	$data = date("Y.m.d.h.i.s") . ' on requesting ip: ' . $_SERVER['REMOTE_ADDR'] . ' Request to set GREEN.' . "\r\n";
	fwrite($handle, $data);

	echo "away";
	$handle = fopen($my_file, 'a') or die('Cannot open file:  '.$my_file);
	$data = date("Y.m.d.h.i.s") . ' on requesting ip: ' . $_SERVER['REMOTE_ADDR'] . ' FAILED REQUEST!!! Request: ' . $home . "\r\n";
	fwrite($handle, $data);
	echo "invalid";
  1. Now let’s explain the URL in there so you can get an idea of what is happening and how Blue Iris is interpreting it.
    1. Where 8080 is the port you’ve set blue iris to
    2. User is the user account you create in Blue Iris
    3. PW is the password for said account (recommended to restrict this account down to admin tasks only not viewing rights or anything else).
    4. Signal is the traffic symbol where 1 is active (green) and 0 is inactive (red).
  2. Now if you browse to your local host URL you should have a value returned. In this case, you should see “away” in your web browser. If you see this, that means your PHP script is working. Blue Iris at this point should also change the animation in the traffic symbol.

  3. Let’s take a moment to understand all of what just happened and why. You set up a web server with a script to change the alert status on the local Blue Iris machine. Now you’ll need to expose the web server to the internet (or if your security aware, you may also set it to only work with IFTTT IP addresses). This step I will not outline as there are too many router combinations, but you need to port forward to your web server.
  4. IFTTT is super easy! Just log in, select Location for the “this” (set up an enter an area and set it appropriately for your home) and a “that” with a webhook in which you will put in your IP/ domain so something like x.x.x.x:PORT/myphpfile.php?home=true for enter and home=false for exit. You will create 2 webhook applets, one for enter and one for exit, each with the appropriate URL.

This guide is somewhat advanced as it assumes you know/ can port forward and you have a static IP or a domain set to change with your IP.

Surveillance Cameras & Software Reviews

Surveillance is becoming increasingly popular in households in the United States. I’m not actually basing that on stats online though. I take walks in the evenings and every other house has cameras. It’s definitely a new thing of the future. Cameras are getting cheaper and better. Software is becoming more available and more affordable. I’m just going to discuss quickly a few cameras and the software I’ve used as well as my thoughts on them. Let’s first discuss cameras.

The question to ask is “Digital/IP or Analog/Coax”?

Designed by Freepik
CCTV security camera in city of China.

The first system I bought for my house about 3 years ago was a LaView analog system for about $300 on Newegg that came with 4 bullet cams. Quite honestly compared to other cameras I’ve used in the past, I thought the quality was pretty amazing. Over time, I added cameras to fill up the 8 channel system. The quality is good for a basic home system. Not so good for catching the details. It records on a 3TB hard drive for about 2 years on high quality for each of the cams. The support for LaView is by far the worst I’ve experienced and I’d have to recommend against their brand simply for that reason. Today, the cameras are still running and I still like them. Occasionally the DVR stops recording but continues streaming live feeds so you don’t actually know until you want to look up video. Thankfully, the RTSP streams keep working during this time. How does that help exactly? The stream can be fed to a network recording software such as iSpy or Blue Iris. It gives you that redundancy over the cameras in case one of the systems fail. The software is also what you might use to record video streams from Digital/ IP cameras.

Let’s talk about Digital or IP Cameras. I started off purchasing ELP cameras (cheap Chinese versions) for about $30-40. They work and the quality is clearer than that of my LaView analog system, but due to the quality, the angle was not as wide as advertised and getting them to work initially was…. involved. I didn’t gain confidence in those cameras at first since I wasn’t recording to a dedicated machine. I later discovered it is really only capable of broadcasting a low and high quality stream. Once each of those two streams are attached to a recording device, another recording device cannot pick up the streams anymore. (IE: Surveillance software as well as a remote viewer for the camera) As of recently, I’ve purchased a 4MP camera for about $80. The quality of that camera when compared to the ELP cameras is outstanding. First of all, these guys have done AMAZING work at making the camera visible over the network. Second, I’ve had it connected to 3 systems simultaneously and the stream just doesn’t fail. It’s one of the most resilient cameras I’ve found so far within the home camera systems. As a matter of fact, it is always the first camera to connect to my software.

What software should I use?

Speaking purely in terms of home use, there were 3 major contenders in the race. There are many brands, but these were the ones I found to be affordable, easy to use, and reliable.

  1. iSpy¬†| This software is free unless you want to have remote viewing enabled. I’ve used this software for probably 3-5 years now and it has been great for what I’ve needed.
    • Pros: It is free. There is a local viewing through a web browser (sometimes flaky). It seems to keep running. It has crashed a few times, but it restarts itself quickly. Supports many cameras. Ability to buy a subscription to get some additional features. Many options available.
    • Cons: The software can take a while to connect to all cameras (outside of the fact the cameras sometimes take time to connect). It’s updated regularly (seemingly too often actually) and new features are seldom added from what I’ve seen. There have been some minor interface changes, menus combined, lots of new cameras supported (all great things), but just no new face lift to the interface. I think their main focus is making it work online more so they can bring in cash flow through subscriptions (I don’t blame them). It takes a long time to get the settings tuned in just right to get the effect you are after. Sometimes video doesn’t record correctly and renders a corrupt recording file.
  2. Blue Iris | I am definitely not for paying software usually, so it took me a long time to actually test out this software. It is about $60-70 for a full license (no subscriptions thankfully). This is my new first choice.
    1. Pros: Fast, sleek looking, web interface for remote viewing, updated regularly, works with a wide range of cameras, lots of features, lightweight on computer resources, high quality recordings, user friendly GUI, 64 bit, inexpensive, great online documentation and user manual.
    2. Cons: No free version. The light edition only supports 1 camera or you buy the full version supporting 64 cameras. (A little more choice would be great on the pricing model). Support can be somewhat rude (check out the forums and the way the staff member responds to people). No viewing of AVI files through the software or while the file is being recorded. You have to use the native bvr format for easy playback.
  3. Milestone XProtect | Free for up to 12 cameras on a subscription license. Professional software. This would be my second choice. Crazy, I know, but their pricing model doesn’t feel solid. I feel they may attempt to change the plan to restrict what the “free users” get since it’s a subscription model.
    1. Pros: Fast, professional, clean, easy to use, automated, used in large corporations, supports up to 12 cameras with unlimited recording time.
    2. Cons: Expensive. Subscription license. Records to proprietary format that would require having the software to view it. “Lost connection” messages with the client, though it does seem to keep recording.

With the rising popularity of cameras in residential settings and the multitude of options, my personal recommendation would have to be Blue Iris on a dedicated computer with 4 Megapixel Digital IP Cameras. I wouldn’t recommend analog cameras as much anymore unless you want a cheap system to get a general idea of what is happening in an area. Even with the ELP cameras, I can get a license plate number which would be harder to achieve with analog cameras in the home price range. I personally wouldn’t spend a lot of money on a higher quality analog system since the way of the future is in the digital cameras.