Defines the source of the NETREF clocks on the H.100/H.110 bus.
DWORD swiConfigNetrefClock ( SWIHD swihd, SWI_NETREF_CLOCK_ARGS *args)
Argument |
Description |
swihd |
|
args |
NETREF clock configuration parameters: typedef struct Refer to the Details section for a description of the structure and acceptable values. |
Return value |
Description |
SUCCESS |
|
CTAERR_DRIVER_ERROR |
Underlying driver retrieved an unrecognized error. Call swiGetLastError to retrieve the MVIP device error code. |
CTAERR_INVALID_HANDLE |
swihd is not a valid switch handle. |
CTAERR_SVR_COMM |
Communication error in the server environment. |
SWIERR_INVALID_CLOCK_PARM |
Value of a clock configuration parameter is invalid. |
SWIERR_INVALID_PARAMETER |
Board-specific clock parameter value is invalid. |
swiConfigNetrefClock establishes the source of the NETREF clocks on the H.100/H.110 bus. The SWI_NETREF_CLOCK_ARGS structure contains the following fields:
Field |
Description |
size |
Number of bytes contained in the structure. If size is less than the size of SWI_NETREF_CLOCK_ARGS, the command uses only the number of bytes specified by size. If size is greater than the size of SWI_NETREF_CLOCK_ARGS, size is set to the size of SWI_NETREF_CLOCK_ARGS, and the command uses this number of bytes. |
network |
Acceptable values are 1 to n where n is the number of devices on the board. Some devices are not capable of being a source for NETREF. Refer to the device-specific hardware documentation for the devices that are capable of being a source for NETREF. |
netrefclockmode |
Acceptable values are: MVIP95_H100_NETREF MVIP95_H100_NETREF_1 MVIP95_H100_NETREF_2 |
netrefclockspeed |
Acceptable values are: MVIP95_H100_NETREF_8KHZ MVIP95_H100_NETREF_1544MHZ MVIP95_H100_NETREF_2048MHZ MVIP95_H100_NETREF_DISABLED
Note: If MVIP95_H100_NETREF_DISABLED is used, the board stops driving the NETREF specified in the netrefclockmode field. |
Refer to Configuring the clocks for more information.
If CTAERR_DRIVER_ERROR is returned, call swiGetLastError to retrieve the MVIP device error code.
swiConfigBoardClock, swiGetBoardClock, swiGetTimingReference, swiOpenSwitch
void myNetrefClockInit(SWIHD t1hd)
{
SWI_NETREF_CLOCK_ARGS netrefclock;
netrefclock.size = sizeof(SWI_NETREF_CLOCK_ARGS);
netrefclock.network = 1;
netrefclock.netrefclockmode = MVIP95_H100_NETREF;
netrefclock.netrefclockspeed = MVIP95_H100_NETREF_8KHZ;
swiConfigNetrefClock(t1hd, &netrefclock);
}