RtgvWriteRegister

RtgvWriteRegister writes a value to a register on the camera. This operation is intended for unsupported features and will fail if the address corresponds to a supported feature.

Syntax

Copy
BOOL RtgvWriteRegister(
    [in]    UINT32 cameraHandle, 
    [in]    UINT32 registerAddress, 
    [in]    PVOID pValue,
    [in]    UINT8 length,
    [in]    BOOL isBigEndian
);

Parameters

[in] cameraHandle

A handle to the camera.

[in] registerAddress

The address of the register to write.

[in] pValue

A pointer to the value to write to the register.

[in] length

The length of the value.

[in] isBigEndian

A flag indicating whether the value is in big-endian format.

Return Values

If the function succeeds, it returns TRUE. If the function fails, it returns FALSE. Call GetLastError to obtain an error code.

Possible error codes:

Error code Meaning

RTGV_ERROR_SOCKET_ERROR

The write operation to socket failed.

ERROR_INVALID_PARAMETER

One of the following conditions occurred:

  • The value of parameter pValue is NULL.
  • The value of parameter length is greater than 4.

ERROR_INVALID_ADDRESS

One of the following conditions occurred:

  • The value of parameter registerAddress cannot be divided by 4.
  • The input address corresponds to a supported feature.

RTGV_GEV_STATUS(GEV_STATUS_INVALID_ADDRESS)

Parameter registerAddress does not exist.

RTGV_GEV_STATUS(GEV_STATUS_WRITE_PROTECT)

Parameter registerAddress is write-protected.

Requirements

Minimum supported version Header Library

wRTOS 1.0 SDK

RtgvApi.h

RtgvApi.lib

See Also: