How to setup the SPI module to send and recieve data
Posted: Fri Mar 20, 2009 5:20 pm
Hello Mr. Lubin,
We are a team of students at Oakland University, USA and we are currently working on a project that uses dspic (30f4011)controller and we are currently using your dspic toolbox for spi communication. We are communicating to the pressure sensor that has spi interface. We looked through your forum and exmaple and it's useful, however it didn't help us setup the SPI block for receiving data from the pressure sensor to micro and to send data from micro to a transmitter though UART. Could you please give us a direction on how to configure the spi block to send and receive data. I have attached the simulink model that we have so far, but our model is not complete. Your help is appreciated.
Here is a summary of the things that we want to accomplish:
Send 8 bits command to the pressure sensor through the SPI module of the dspic.
Receive the pressure data from the pressure sensor
Send the pressure sensor data to the UART using the dspic
I have attached the simulink block diagram and pressure sensor data sheet
Thank you very much for your help.
Khalid
We are a team of students at Oakland University, USA and we are currently working on a project that uses dspic (30f4011)controller and we are currently using your dspic toolbox for spi communication. We are communicating to the pressure sensor that has spi interface. We looked through your forum and exmaple and it's useful, however it didn't help us setup the SPI block for receiving data from the pressure sensor to micro and to send data from micro to a transmitter though UART. Could you please give us a direction on how to configure the spi block to send and receive data. I have attached the simulink model that we have so far, but our model is not complete. Your help is appreciated.
Here is a summary of the things that we want to accomplish:
Send 8 bits command to the pressure sensor through the SPI module of the dspic.
Receive the pressure data from the pressure sensor
Send the pressure sensor data to the UART using the dspic
I have attached the simulink block diagram and pressure sensor data sheet
Thank you very much for your help.
Khalid