SC5312A Operating & Programming Manual
Rev 1.0.2
27
Function:
sc5312a_WriteUserEeprom
Definition:
int
sc5312a_WriteUserEeprom(
unsigned int
deviceHandle,
unsigned
int
memAdd,
unsigned
char
byteData)
Input:
unsigned int
deviceHandle
(handle to the opened device)
unsigned
int
memAdd
(memory address to write to)
unsigned
char
byteData
(byte to be written to the address)
Description:
sc5312a_WriteUserEeprom
writes one byte of data to the memory address specified.
Function:
sc5312a_StoreCurrentState
Definition:
int
sc5312a_StoreCurrentState(
unsigned int
deviceHandle)
Input:
unsigned int
deviceHandle
(handle to the opened device)
Description:
sc5312a_StoreCurrentState
stores the current state of the device as the default power-
up state.
Function:
sc5312a_GetDeviceInfo
Definition:
int
sc5312a_GetDeviceInfo(
unsigned int
deviceHandle,
deviceInfo_t
*devInfo)
Input:
unsigned int
deviceHandle
(handle to the opened device)
Output:
deviceInfo_t
*devInfo
(device info struct)
Description:
sc5312a_GetDeviceInfo
retrieves device information such as serial number, calibration
date, revision, etc.
Function:
sc5312a_GetDeviceStatus
Definition:
int
sc5312a_GetDeviceStatus(
unsigned int
deviceHandle,
deviceStatus_t
*deviceStatus)
Input:
unsigned int
deviceHandle
(handle to the opened device)
Output:
deviceStatus_t
*deviceStatus
(deviceStatus struct)
Description:
sc5312a_GetDeviceStatus
retrieves the status of the device such as phase lock status and
current device settings.
Example:
Code showing how to use this function:
deviceStatus_t
*devStatus;
devStatus = (deviceStatus_t*)malloc(
sizeof
(deviceStatus_t));
int
status = sc5312a_GetDeviceStatus(devHandle, devStatus);
if
(devStatus->loEnable)
printf(
"The LO Output Port is Enabled \n"
);
else
printf(
"The LO Output Port is disabled \n"
);
free(deviceStatus);