Quantcast
Channel: EngineerZone: Message List
Viewing all articles
Browse latest Browse all 28044

Re: VDK accessing multiple SPI devices

$
0
0

OK, next question, bidirectional access to the SPI using DMA mode.  There are many examples use reads, but, need to support both write and reads.

 

What is the basic API flow?

 

adi_dev_Open(..., ADISPIDMAEntryPoint, ...);

 

Result = adi_dev_Control( spiHandle, ADI_DEV_CMD_TABLE, (void*)SPI_config );

ADI_DEV_CMD_VALUE_PAIR = SPI_config[] {

ADI_SPI_CMD_SET_TRANSFER_INIT_MODE, (void*)2, ... //read

}

 

This sets up the SPI driver in read mode.  So each time a write a call must be made to adi_dev_control to switch the ADI_SPI_CMD_SET_TRANSFER_INIT_MODE to write?


Viewing all articles
Browse latest Browse all 28044

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>