LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

USB-8451 Scripts

Hello all, my problem is this :  I need to be able to stretch the time between byte writes using a NI USB-8451.  I am using four wire SPI communications.  The device in question is a ADC that returns 16 bytes.   I am able to read and write to the device.  Every so often, the data appears to be flaky.  It has been suggested someone to give the device a little more time by setting up a delay between each time a byte is sent.  The delay will probably need to be in the microseconds.  Also I am programmming using is CVI, but if there is an answer to this in labview, I'll gradly learn a new language!!!  I hope the picture below helps.....

Figure 7.2 of the NI-845x Software User Manual is a better picture.  In FIgure 7.2, t3 - SCLK setup time. that is what I would like to increase significantly.  Any and suggestions are welcome.


Regards



 
0 Kudos
Message 1 of 3
(3,669 Views)

Hi sal_c,

Unfortunately right now the functionality of increasing the SCLK setup time in microseconds is not supported.

You are able to increase the SCLK setup time in milliseconds using the ni845xSpiScriptDelay function. This can be found in page 9-37 of the Software User Manual found here.

Have a great weekend!

 
Rasheel
0 Kudos
Message 2 of 3
(3,626 Views)
I was able to cheat a shorter delay by repeated chip selects to the the same value (if CS is low use the chip select low vi). I did not see any glitches but was able to get a delay of about 9 us per chip select. I needed a 40 us wait between a write and teh subsequent read to allow ADC conversion time.


0 Kudos
Message 3 of 3
(3,430 Views)