Personal tools
Sections
Path: Home Software AXIS Camera Recorder Documentation Howtos Getting started
Document Actions

Getting started

This How-to applies to: 0.1, 0.0.35
This How-to is intended for: End User

How to get started with your first camera

To start off with you will need one or more AXIS IP camera's attached to your network on known IP's, and you will need access to an SQL database. (and you will need it's IP, and a valid username and password)

  • First, decide which "user" is going to own this process, then log in as that user. (or "su" to that user")
  • Second cd to ~/.config/gambas , or make the folder if it does not already exist
  • Create and edit "axis_recorder.conf"

Now you will need to define the SQL database you are going to use, enter;

[SQL]
user="<user name>"
pass="<password>"
host="<name or IP of host>"
type="<database driver, eg; mysql>"
name="<database name, create if necessary>"
Next you will need to add a section for each camera you want to handle, using the notation;
[Camera_<number>]
URL="<ip address>/axis-cgi/jpg/image.cgi?resolution=<resolution, for example; 320x240>"
user="<camera user id>"
pass="<camera password>"
delay=<delay in ms between frames, eg, 300>

Here's a real life example just to make sure we're on the same track;

;
; This takes two views of the same camera, 320x240 px shots 4 times a second and 640x480 shots once a second.
;
[SQL]
user="root"
pass="******"
host="localserver"
type="mysql"
name="axis"

[Camera_1]
URL="10.0.0.130/axis-cgi/jpg/image.cgi?resolution=320x240"
user="root"
pass="******"
delay=250

[Camera_101]
URL="10.0.0.130/axis-cgi/jpg/image.cgi?resolution=640x480"
user="root"
pass="******"
delay=1000

Now you need to create a project called "axis_recorder" and paste the project source code into your main module. (you need to create a basic command line / non-GUI application) Then compile the program which will generate a file called "axis_recorder.gambas", which you should probably copy to /usr/local/bin.

Now fire it up, try;

/usr/local/bin/gambas.recorder 1

Which should start the application in the foreground. If all looks good, control-C to kill it, then do the same again with " BG" appended to start it up in the background. The appropriate start commands for the example configuration would be;

/usr/local/bin/gambas.recorder 1 BG
/usr/local/bin/gambas.recorder 101 BG

And you're off!

Important note;

The viewer application will look for a camera with id <number+100> for "detailed" views .. so if you want the detailed view to work then you need to run a second recorder instance with number+100.