Help using NI-845x SPI and DIO in MatLab

조회 수: 6 (최근 30일)
Erik
Erik 2025년 2월 10일
댓글: Erik 2025년 2월 11일
I am trying use the SPI interface as well as control the DIO pins. So far I have to connect to the NI box 2 seperate ways to make it work. I found an example that supposedly does this but it doesn't work.
device = ni845x('NI box serial');
spi_obj = spi(device, 0, 0);
I get the following error regarding the vendor???
Error using spi
Expected input number 1, vendorName, to match one of these values:
'aardvark', 'ni845x'
The input did not match any of the valid values.
Error in stest (line 17)
spi_obj = spi(device, 0, 0)

답변 (1개)

Walter Roberson
Walter Roberson 2025년 2월 10일
spi_obj = spi('ni845x', 0, 0);
  댓글 수: 7
Walter Roberson
Walter Roberson 2025년 2월 11일
It just might be the case that you can either establish an spi connection or a DIO connection. I do not know. I do not have any ni845x to experiment with.
I can say that spi() has no option to accept a device returned from ni845x()
I suggest that you open a support case.
Erik
Erik 2025년 2월 11일
Thats what I kinda thought. Thanks for you time

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Test and Measurement에 대해 자세히 알아보기

제품


릴리스

R2023a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by