The following camera settings are specific to systems purchased after April 2021 (Z2 systems) or after November 2025 (Z3 systems). Most users of these versions of the systems will never need to adjust the camera settings. The example script below details how to change the camera settings through the running of a Zanscript.
There are number of commands which allow you to alter various aspects of the camera settings.
Commands to change Z2 & Z3 camera profile
The following commands control the camera profile for both the Z2 and the Z3 systems. This setting controls the image resolution.
CAMERAPROFILE(11) CAMERAPROFILE(12) CAMERAPROFILE(13)
The default resolution is set as Half - 720x540 or CAMERAPROFILE(12). This leads to a clear image for most sized animals. The full resolution mode, CAMERAPROFILE(11), runs at a resolution of 1440x1080. The partial mode, CAMERAPROFILE(13), is a 'Region of Interest' (ROI) of the centre of the image. The ROI is used when operating at bursts of high speed (up to 600 fps).
CAMERAPROFILE(11): Full - 1440x1080
CAMERAPROFILE(12): Half - 720x540
CAMERAPROFILE(13): Partial - 640x480; ROI
NOTE: Scripts will abort if an asset file (zones or arenas) is loaded, but does not match the current system image resolution. Changing the camera resolution means the arena and zones assets need to be rebuilt to be in the correct resolution.
Command to change Z2 & Z3 Gain
The following command is used to adjust the Gain. It is used when one needs to adjust the brightness of the image from the camera.
SET(GAINVAL,#)
The gain value can be set within the range of 0-480. The camera gain is the amplification of the camera 'signal' which makes it brighter. Increasing the gain, increases brightness. However, it also increases background noise, which can lead to false tracking.
Standard gain settings:
- MWP = 0
- AD = 100
- LT = 100
Command to change Z2 & Z3 Exposure
The following command adjusts the exposure value. This is used to set the camera's shutter speed in μsec.
SET(EXPVAL,#)
Reducing shutter speed reduces the blurry aspect of the image.
Standard exposure settings
- MWP = 3000μsec (3ms shutter speed)
- AD = 20,000μsec (20ms shutter speed)
- LT = 15,000μsec (15ms shutter speed)
NOTE: When using the system at high speed (600fps) the exposure value will need to be SET at 1600μsec (1.66ms) or below.
Command to change Z2 & Z3 frame rate
The following command is used to set the camera's frame rate.
SET(FRAME_RATE,#)
The frame rate can be set between 1-120 frames per second (fps) at "full" and "half" camera profiles (1440 x 1080 and 720 x 540 respectively). When the camera profile is set to ROI (640 x 480) the frame rate can increase further up to 600fps. Frame rates are stepped (i.e., 1 ,5, 15, 30, 60, 120, 240, 480, 600).
For continued, reliable tracking at different camera profiles, it may be required to adjust the frame rate.
Suggested frame rate settings:
- Full (1440x1080) = 15fps
- Half (720x540) = 30fps
- ROI (640x480) = 600fps (for bursts of 60 seconds)
NOTE: The Z3 systems have an improved camera and processor over the Z2 and Z2S systems. As such it may be possible to set higher frame rates in a Z3 system (e.g. 30fps at full camera profile). The load placed on the processor also affects how consistent the system can keep up with processing of frames of data. For example a Z2 or Z2S system may need the frame rate reduced to 5fps at full camera profile if exporting multiple videos and tracking data at the same time.
Exposure time has priority over frame rate - so if a exposure time of 100 ms is set, then the frame rate will not be able to be higher than 10. When creating a full video (i.e., no frames removed / not a timelapse), we recommend 5 fps at high resolution. Also of note, high resolution can be good for imaging, but only very rarely leads to significantly better tracking.
Example script
DEFINE WAIT_TIME 2
ACTION MAIN
#CAMERAPROFILE(11) #full
CAMERAPROFILE(12) #half
#CAMERAPROFILE(13) #ROI
WAIT(WAIT_TIME)
SET(GAINVAL,0) #set gain
WAIT(WAIT_TIME)
SET(EXPVAL,3000) #set exposure
WAIT(WAIT_TIME)
SET(FRAME_RATE,30) #set frame rate
WAIT(WAIT_TIME)
COMPLETE
Script explanation
WAIT(WAIT_TIME) - The system waits the amount of time set in the DEFINE WAIT_TIME statement at the top of the script, i.e., 3 seconds.
CAMERAPROFILE(12) - The default resolution of 720x540 is used and the other two CAMERAPROFILEs are hashed out/not set.
SET(GAINVAL,0) - The camera's gain to set to 0.
SET(EXPVAL,3000) - After waiting the 3 seconds, the system changes the exposure time to 3000 and then waits another 3 seconds as defined for the WAIT(WAIT_TIME) command.
SET(FRAME_RATE,30) - The frame rate is set to 30 frames per second.
NOTE: The above values are the typical values for the Zantiks MWP (0 gain, 3000 exposure, 30fps and a default resolution).
Script download
To download the Z2 camera settings demo script as a .zs file (file type Zantiks software reads), choose the Save File As option in the right-click dialogue box. Clicking on the script name hyperlink will open a read-only version of the script.
Script download: Z2_camera_settings.zs
NOTE: We do not recommend using automatic gain or exposure. The lighting within the system is fixed and keeping a consistently lit image during tracking is important in avoiding false tracks. If the auto modes are turned on, the lighting can change based on the location of the animal in the arena.
However, it is possible to change the camera's setting to allow auto-gain and auto-exposure. To do this, the following two commands can be used to turn of auto mode.
SET(GAINMODE,1) SET(EXPMODE,1)
SET(GAINMODE,1): allows you to switch on the automatic gain setting.
SET(EXPMODE,1): allows you to switch on the automatic exposure time setting.