NI-8452 ChipSelect pin with Matlab
5 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Hi,
I'm trying to send SPI control signals to an device that we are testing recently over the NI-8452.
The signal geneerated from the NI-8452 SPI_SCLK and SPI_MOSI pins are all correct.
A 'ChipSelect' sign from NI-8452 CS0 pin is also generated correctly.
However, the device need another signal from the NI-8452 CS1 pin.
I checked the Matlab Instrument Contrl Toolbox user's guide, but did not find a clear answer.
It only described the ChipSelect value is 0.
So, the question is can Matlab fully utilize the NI-8452 and generate signals from mulitple Cihip Select pins now?
Thank you very much
0 comentarios
Respuestas (1)
John Hribar
el 27 de Mayo de 2019
Hi,
ChipSelect is a property of the spi object in Matlab. The default is zero, but you can change this to any chip select pin 0-7 by typing
S.ChipSelect = pinNumber;
where pinNumber is the desired pin and S is the name of your spi object defined by
S = spi('ni845x', 0, 0);
I hope this helps.
0 comentarios
Ver también
Categorías
Más información sobre Instrument Control Toolbox Supported Hardware en Help Center y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!