From ElphelWiki
Jump to: navigation, search

Web-based Graphical User Interface for camogm

The web interface for camogm is intended for recording of video or images to internal or external storage just from your browser. Elphel393 series cameras support recording in two modes: normal recording to a file system and fast recording to a raw disk or disk partition without any file system on it. The process of images extraction from raw partition is described on this page.


Disk should be prepared before it can be used in either of the two modes of recording. Normal recording assumes there is at least one partition with a file system. Follow this guide from step 1 to step 4 to prepare a partition for normal recording if your disk is not partitioned yet. Fast recording mode requires at least one partition without file system. Follow this guide from step 1 to step 3 to prepare such partition. As alternative, the whole disk can be used as a fast recording buffer and no actions with disk required in this case given that the disk in not partitioned.


Main window

Open the following link in your browser to start camogmgui
Main window

The main window of the program consists of several areas (marked in red on the image) and two of them, preview (1) and buffers usage (2), are folded by default. The third area displays a list of files recorded in normal mode to some directory on the mounted disk. This list is empty right after start and you need to press Reload button to refresh the list. Create folder button makes new subdirectory in the current directory and Set Target Folder sets selected directory as a location for recorded files. The group of tabs on the right side contains status information and controls for recording. The first tab of the group, Status, shows status of all ports and some recording statistics. Some fields on this tab are empty right after start but they will be updated as soon as recording has started. By default, the update period during recording is one second.


Preview panel

The Live-Preview link opens a thumbnail of a captured image and some controls for preview capturing. Preview image can be updated manually each time the Update button is pressed or automatically within a predefined period of time if Auto Update check box is checked. The Size buttons allows you to adjust the image size. Preview is displayed for a single channel selected by Port radio buttons.

Buffers usage

Buffers usage

The Show Buffers link opens several bars indicating the usage of in-camera memory buffers. Each bar corresponds to a single sensor port and shows free space left in buffer and the space occupied by images which have not been recorded yet. The status of these bars is updated along with the content of the Status tab. Click on any bar to fold these indicators back to link. The HELP link below bars leads to this page.

File names tab

File names tab

The Filenames tab controls file naming scheme for recorded files. There are three schemes available:

  • Unix time stamps. The name of a file is created from image time stamp and channel number extracted from Exif. The example of such naming scheme is shown on the screenshot of main window. This is a default scheme.
  • Prompt user for file name after recording
  • Advanced naming scheme. This scheme assembles file names using several predefined fields.

The settings on this tab are ineffective in fast recording mode.

Format tab

Normal recording mode
Fast recording mode

The Format tab controls recording mode and path for resulting files. The group of radio buttons named Format selects resulting file format. Use fast recording check box switches camogm to fast recording mode and disables Format and Directory settings because they are ineffective in this mode. The Directory text field sets full path to a directory where files are saved. Note, that this is a path in camera system, not on your PC. The Devices panel shows a list of disks or partitions available for recording. The contents of this panel depends on the mode of operation: in normal recording mode, the list of mountable partitions is shown, and in fast recording mode the list of partitions or disks without file system is presented. The group of controls below devices list allows you to enable or disable camogm debug output, save this output to a file and adjust its level of verbosity. Do not forget to press OK button before recording to apply the settings.

Advanced tab

Advanced tab

The Advanced tab controls how video files are recorded. The settings on this tab allows you to limit the size and duration of single video file. When either limit is reached, camogm starts recording to a new file. The settings on this tab are ineffective in fast recording mode.

Plans for Future Releases

  • Full Audio Support
  • Full Geotagging Support


camogmgui Version 0.8

Version 0.8

  • added support for USB sound devices, underlying camogm2 is still buggy though and therefore disabled
  • added support for geotagging, underlying camogm2 is still buggy though and therefore disabled
  • mounting of different devices/partitions like external SATA devices is now possible, still needs testing though
  • updates free hdd space dynamically while recording
  • added buffer graph, still unexpected behaviour
  • used different method to set quicktime mov as default format
  • bug fixes

No release URL this time as from now on latest source files need to be obtained directly from the CVS tree.

Version 0.7

  • updated to work with 8.0 firmware
  • advanced naming scheme tab added
  • debug output added
  • bug fixes

camogmgui Version 0.6

Version 0.6

I think we are getting close to a first major 1.0 release. As always please provide feedback.

  • sensor state info added
  • added some help text
  • quicktime *.mov is now the default format
  • the filebrowser can now go into subfolders, also create them or set them as target for recordings
  • live video preview image added in expandable tab
  • tabs remember their state across page reloads
  • bug fixes

camogmgui Version 0.5

Version 0.5

  • good bye bulky placeholder design -> Hello fancy real visual interface
  • camogm is now automatically started from within the script.
  • hdd can be mounted with a single click
  • filebrowser is is alot fancier now
  • frameskip / timelapse problem fixed
  • spry applets added for even more responsive and feature rich layout

camogmgui Version 0.4

Version 0.4

Anything hdd mounting related can now be done directly inside the gui. I also added a filebrowser so recorded videos can immediately be downloaded. Advanced settings added. The whole script does not rely on any external resources anymore.

I tried starting camogm from within the script as well, but ran into some problems, stay tuned.

So still: before the script can be used camogm must be started manually via shell:

camogm /var/state/camogm_cmd &

Version 0.3

Some decent progess here. Lots of ajax scripting done to show filesize, datarate, etc. live while recording video files. Record and stop-record commands are also ajax transmitted which makes the GUI much more responsive. Stability issues seem to be solved now as well.

Again: before the script can be used camogm must be started manually via shell:

camogm /var/state/camogm_cmd &

Version 0.2

I color labeled the parts of the gui and their current grade of operation. Record Format and destination directory are now read from xml output of camogm to fill in the form. The script now checks if both camogm and compressor are running. If the compressor is not running it can be started directly in the GUI. Camogm can not be started in the GUI yet (crashes...).

Before the script can be used camogm must be started manually via shell:

camogm /var/state/camogm_cmd &

Version 0.1

Very basic functionality as of now, format/codec can be selected, target directory can be set, record start/stop, audio recording form is already in the file but not functional yet

(Wiki hosted download link will follow as soon as the wiki permits me to upload anything else than images)


Software Interface

The GUI strongly relies on AJAX requests to update contents on the fly. These AJAX commands can be (re)used from external programs as well.



The following commands are available:

start camogm as background deamon:


does nothing if camogm is already running

show camogm xml status:


returns something like this:

<kml_height_mode>"map ground level"</kml_height_mode>

start recording:


stop recording:


rename file:


returns errors if the file names are the same or if the target file name already exists.

mount partition:

mount the default partition /dev/hda1 at /var/hdd. Also create the required directory:


You can also supply 2 more arguments specifying custom partition and mountpoint:

For example:


unmount partition:

To unmount a previously mounted partition you need to supply the mountpoint:

For example:


list devices: Shows xml information about connected media no matter if they are mounted or not:


with only the internal HDD this returns:

<size>37.25 GB</size>

create directory: creates a new directory

Example creating a new directory called "newdir" in the /subdir/ which has to exist already:


Get remaining free HDD Space:


is HDD mounted:


returns either the mountpoint or "no HDD mounted"

create HDD symlink:


makes the HDD available over http by placing a symlink in the correct directory.

List files:


returns an xml tree of the available files at a specified path with details like size and creation date:

<date>13 Nov 2008 22:37:15</date>

set camogm record directory:


Tell camogm to record to this specified path. Also creates/sets a cookie called "directory" with the same value.

init the camera compressor:


check USB audio hardware:


Returns connected (hotplugable) USB audio devices.

Play sound over USB audio device:


Tests audio hardware by playing back a specific soundfile.

set quicktime as recording format:


Tells camogm to use quicktime mov as format.