Use Java to Watch Your Axis Network Camera (Java Axis Viewer)

| No TrackBacks
axis-viewer-screenshot.pngI'm the proud owner of an Axis 2100 Network Camera.  Unfortunately, the 2100 was discontinued and replaced with the Axis 210.  One of the many reasons why I love these IP network cameras is the nice web-based management interface they offer.  The web-interface lets you control just about anything you want on the camera, including the motion-JPG image feed which is viewable in any web-browser.

But, herein lies the problem.  If I want to watch my Axis network camera, I have to keep a browser open.  This is slightly annoying because I shouldn't need a browser to look at a JPG image.  So, I took matters into my own hands and wrote my own lightweight Java app to let me watch my Axis Camera without a web-browser (screenshot).  Theoretically, this app should work for any IP based camera that exposes a still JPG image URL.  As a side note, the app lets you pause and adjust the refresh rate of the stream as well.  Continue reading for the source (released under the MIT License) and a pre-built JAR.
The code for this Java Axis Viewer has been adapted from one of my other projects: the Silhouette Project, a real-time shape recognition engine written in Java.

Pre-built "runnable" JAR (10Kb): axis-viewer.jar

Source JAR (12Kb): axis-viewer-src.jar

To run, download axis-viewer.jar.  If you have Java installed, and you're running Windows, chances are you can simply double-click on the JAR file to start the application.  If you don't have the JVM associated with JAR files in your environment, or you're running Linux, you can start the JAR from the command line:

(mark@bermuda)~> java -jar axis-viewer.jar

To get the source, download axis-viewer-src.jar.  The source is available under the MIT License; meaning you can do whatever you want with the code, but I'm not responsible for anything that goes wrong.  To extract the JAR:

(mark@bermuda)~> jar xvf axis-viewer-src.jar

Note, this Axis viewer is NOT serving up a motion JPG stream.  Instead, it makes repeated requests for a still JPG image at a given interval.  If you're looking for Java code to handle/process a motion JPG stream, this is not it.

Enjoy.

Did You Find this Helpful?

Did you find this post helpful, or at least, interesting?

  

About Mark

A Silicon Valley native, Mark Kolich is a full-time Software Engineer and a consultant for hire. A web technologies expert, his current focus is on building powerful and robust cloud-driven web-applications using Java, PHP, Perl, AJAX, DHTML, CSS, and JavaScript. His favorite programming languages are PHP, Java and JavaScript. He uses Linux, enjoys biking to work, loves building great software, and always writes elegant, readable, and maintainable code.

No TrackBacks

No trackbacks attached to this entry.

Twitter (@markkolich)

Translate

About this Entry

This page contains a single entry by Mark Kolich published on November 26, 2008 10:09 AM.

HOWTO: Use Java to Compute an md5sum of a String was the previous entry in this blog.

HTML Generator Approved for Open Source Release Under the MIT License is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.