LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Labview connection with HW

Hello,

 

I would like to ask you how to connect ADS1293 to LabView, I am using NI USB-6501. How should I do it? Some kind of UART communication? DAQ or VISA?

 

Thank you,

Daniel 

0 Kudos
Message 1 of 13
(3,467 Views)

Hi Dan,

 

which communication port does that "ADS1293" offer?

(I don't think this simple NI6501 DIO device will be of any help for your task…)

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 13
(3,459 Views)

Hello, thank you for your reply. 

 

The ADS1293 provides:
CSB 16 Digital Input Chip-select bar
SCLK 17 Digital Input Serial clock
SDI 18 Digital Input Serial data input
SDO 19 Digital Output Serial data output
DRDYB 20 Digital Output Data ready bar

and GND.

 

Daniel

 

0 Kudos
Message 3 of 13
(3,453 Views)

That chip uses a SPI interface to communicate.  So you will need something like a USB-8451 or USB-8452 to talk with it.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 4 of 13
(3,438 Views)

As another option...  a co-worker successfully used a NI 6501 to bit-bang a SPI bus once.

---------------------------------------------
Former Certified LabVIEW Developer (CLD)
0 Kudos
Message 5 of 13
(3,424 Views)

Possible but without waveform outputs very painful. At least with something that supports digital waveform I/O you can run a little bit faster and get something nice-ish working.

 

I guess your colleague basically had all the pains of FPGA programming with none of the advantages or gains. Probably also depends on the requirements for timing variability on the ADS1293. At 0.4/Fsclk I'm not sure what the limit on clock speed would be for the USB-6501.


GCentral
0 Kudos
Message 6 of 13
(3,418 Views)

Thank you very much for your opinions guys. So your suggestion is to change the measurement card? Or do you have any advice on how to proceed with that current one which I have? 

I think ADS1293 is able to communicate by UART as well. Maybe there is some way how to do it.

 

Thank you,

Daniel

0 Kudos
Message 7 of 13
(3,405 Views)

It's not impossible to do with the hardware you have now - it's just pretty slow and tedious and perhaps a little tricky to code. If you don't feel confident understanding exactly what's required, it's unlikely to be your best choice.


Essentially, you'd be better paying somebody else to write the code, and the cost of that coding might will (I just checked the prices on the link) be higher than hardware better suited to the task (guess only - I don't know what people charge for consulting, and I haven't purchased any of the NI or equivalent hardware suitable for this that I think was the cheapest that could solve the problem).

 

If you want to press ahead and do it yourself, you'll have to do the "bitbanging" that was mentioned above - this is taking whatever message you want to send or receive and then toggling all of your digital I/O in a loop, one bit at a time, to send and receive data. I'm not certain it's possible with the 6501, but it might be. Your problem will be getting the right timing relations between different changes of the clock and the MOSI/MISO (or SDI/SDO) lines. Ensuring the appropriate timing relationships might require you to use a very slow clock speed (because you'll be basically doing one bit per iteration of a while loop) and you need it to be fairly reliable.

 

Since the hardware linked about is not particularly expensive, even just considering salary costs for your programming time might make it a good buy, depending on what you get paid 😉 You'll still have to program the other hardware (and that will still take time) but your programming will probably be limited to working out what data to send, and interpreting the data you receive, rather than first having to work out how to send and receive data.


GCentral
0 Kudos
Message 8 of 13
(3,400 Views)

Ok. Thank you very much. 

 

Best regards,

Daniel

0 Kudos
Message 9 of 13
(3,395 Views)

Hi Daniel,

 

what about using an Arduino (or similar) to do the SPI stuff and send the data via its (virtual) COM port to your computer?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 10 of 13
(3,384 Views)