Programmer's Guide
RaDeKL Radar API Programmer’s Guide 21
© Multispectral Solutions, Inc. 2006
RaDeKL_GetReceiveAttenuation
Get the RECEIVE ATTENUATION register value from the radar device.
NOTE: Receive attenuation settings can currently be in the range from 0 to 255, but the actual
range of permissible settings should be obtained by calling RaDeKL_GetDeviceInfo and using
rx_atten_min and rx_atten_max, as these might change with future versions of the radar unit.
Format:
ULONG RaDeKL_GetReceiveAttenuation (RaDeKL_HANDLE handle, BYTE *attenuation);
Parameters:
handle RaDeKL_HANDLE as returned by a call to RaDeKL_OpenRadar.
attenuation Pointer to a BYTE to receive the attenuation value. Possible attenuation values are
in the range from 0 to 255. Reference values are:
Value Attenuation
0 0 dB (default)
31 -5 dB
81 -10 dB
125 -15 dB
155 -20 dB
180 -30 dB
For the receive attenuation there is no function to convert between register value
and attenuation. The above values are derived from experimentation. The user
may use any register value between 0 and 255 and use the above table as a rough
guide for the resulting attenuation.
Return Value:
RADEKL_OK (0) if successful, a non-zero status otherwise. See RaDeKL_GetStatusText for codes.
Example:
Read the RECEIVE ATTENUATION register and display its value.
ULONG status;
RaDeKL_HANDLE handle;
BYTE attenuation;
// Assume we have an open radar with a valid handle
status = RaDeKL_GetReceiveAttenuation (handle, &attenuation);
// Check status . . .
printf (“The RECEIVE ATTENUATION is currently set to %d\n”, attenuation);