Вы здесь

DlnSpiMasterSetDelayBetweenFrames() Function

The DlnSpiMasterSetDelayBetweenFrames() function sets a delay between data frames exchanged with a single slave device. For more information, read SPI Delays.

Syntax
C/C++
DLN_RESULT DlnSpiMasterSetDelayBetweenFrames(
   HDLN handle,
   uint8_t port,
   uint32_t delayBetweenFrames,
   uint32_t* actualDelayBetweenFrames
);
Parameters
handle

A handle to the DLN-series adapter.

port

A number of the SPI master port to be configured.

delayBetweenFrames

The delay value in nanoseconds. If you specify an unsupported value, it will be approximated as the closest higher supported value.

actualDelayBetweenFrames

Actual set delay value in nanoseconds.

Return Value
DLN_RES_SUCCESS (0x00)

The function successfully set the delay between data frames.

DLN_RES_INVALID_PORT_NUMBER (0xA8)

The port number is not valid. Use the DlnSpiMasterGetPortCount() function to find the maximum possible port number.

DLN_RES_BUSY (0xB6)

The SPI master is busy transmitting.

DLN_RES_VALUE_ROUNDED (0x21)

The delay value has been approximated as the closest supported value.

Remarks
DLN-1 and DLN-2 adapters do not support delays between frames.

The DlnSpiMasterSetDelayBetweenFrames() function is defined in the dln_spi_master.h file.

Языки

Вход на сайт