Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

SPI USB-8451 Connection

Hi, I'm new to USB-8451 for SPI. May I know which pin should I connect SPI_CSB, SPI_MOSI, SPI_CLK & SPI_MISO in USB-8451? Thank you in advance for the reply! Best Regards, Norman
0 Kudos
Message 1 of 7
(4,737 Views)
Your signals            8451 Signals
SPI_CSB                  SPI_CS0 (pin 13) (I assume this is a chip select line)
SPI_MOSI                 SPI_MOSI (pin 14)
SPI_CLK                   SPI_CLK (pin 16)
SPI_MISO                 SPI_MISO (pin 15)

Essentially, with SPI, MOSI stands for Master Out, Slave In, so this wire describes the purpose and is connected straight through. Same thing with the MISO (Master In, Slave Out). The clock connects to the clock and the chip select connects to the chip select.


Message Edited by GPIB Guru on 07-25-2007 09:43 AM

0 Kudos
Message 2 of 7
(4,729 Views)

Hi:

I have the question on the SPI scripting on NI-8451. My device ( always in slave mode) needs 16 clock pulses for a read operation. First 8 clocks for register address write and then the next 8 clock pulses when the data out from my device. Is there a way to program using SPi scripting to generate 16 clock pulses instead of 8 with one "SPI write script" VI. This will be very helpful for my application. As I need to do burst reads/writes and adding a zero would make it very hard. Please let me know asap.

Thanks,

Divya.

 

 

0 Kudos
Message 3 of 7
(4,505 Views)
Howdy Divya,

There is a way to 16 bit communication with your device, however it's kind of a work around as the SPI scripting only supports 8 bit communication. Details of this process can be found in the Knowledge Base Article Does the NI-USB-8451 Support 16 Bit Transfers? However, this method has about a 10 to 20 us delay between 8 bit transfers. Good luck on your application!
Sincerely,

Chris G in AE
0 Kudos
Message 4 of 7
(4,487 Views)
I am interested in 3-wire SPI ( SDO/SDI line is bi-directional on my part) with the NI-8451...has someone tried this or has an idea whether it could be done?
0 Kudos
Message 5 of 7
(4,485 Views)
Divya,

It looks like you've been trying to find this for quite some time now.  I saw a post on another NI thread that talks about a 3rd party 3-wire SSI device.  I thought you might find that helpful.  Have a great weekend!
Sincerely,

Chris G in AE
0 Kudos
Message 6 of 7
(4,468 Views)
On Jan 15, 10:10 am, DivyaS <x...@no.email> wrote:
> Hi:
> I have the question on the SPI scripting on NI-8451. My device ( always in slave mode) needs 16 clock pulses for a read operation. First 8 clocks for register address write and then the next 8 clock pulses when the data out from my device. Is there a way to program using SPi scripting to generate 16 clock pulses instead of 8 with one "SPI write script" VI. This will be very helpful for my application. As I need to do burst reads/writes and adding a zero would make it very hard. Please let me know asap.
> Thanks,
> Divya.
> &nbsp;
> &nbsp;

Divya,

The way I've done this is to send out two bytes and read two bytes.
You send the register write data and a second byte of anything. Then,
the read data is two bytes long. Just ignore the first byte.

This will not slow down the communication. Remember that read and
write are simultaneous.

Example:
You want to send value W (11111111) and you want to read value R
(11111111).
You send W (11111111) and 1 byte of anything (xxxxxxxx): it will look
like 11111111xxxxxxxx
and the output will read 1 byte of anything (xxxxxxxx) and R
(11111111): it will look like xxxxxxxx11111111.
You just ignore the first 8 bits in the reply.

0 Kudos
Message 7 of 7
(4,421 Views)