vinay shabad
Junior Member level 3
- Joined
- Dec 13, 2010
- Messages
- 30
- Helped
- 0
- Reputation
- 0
- Reaction score
- 0
- Trophy points
- 1,286
- Activity points
- 1,769
hii i saw aprogram in net where they wrote value of spibuf can any one explain me how to give value for this.
void readSPI()
{
unsigned int i;
_SPI_SS_PIN = 0; //Slave Select Enable bit (Master mode)
for (i=0; i<4; i++){};
SPI1STATbits.SPIROV=0; // resets TX buffer overflow
IFS0bits.SPI1IF = 0; // resets SPI Interrupt Flag
*********SPI1BUF = 0x5105;**************
}
can any one tell me how we get this value how to calculate this value
void readSPI()
{
unsigned int i;
_SPI_SS_PIN = 0; //Slave Select Enable bit (Master mode)
for (i=0; i<4; i++){};
SPI1STATbits.SPIROV=0; // resets TX buffer overflow
IFS0bits.SPI1IF = 0; // resets SPI Interrupt Flag
*********SPI1BUF = 0x5105;**************
}
can any one tell me how we get this value how to calculate this value