Hi I am using 89C51ED2 for my projects.From SPI I am receiving datas from peripherial.I using inbuilt registers like SPDAT,SPCON.But I can't call my SPI function from interrupt service routine My CODE is void readspi(void){ Enablecs(); SPDAT = addr; while((SPSTA & 0x80) == 0); spivalue = SPDAT; while((SPSTA & 0x80) == 0); Disablecs(); } void Ext0_ISR(void) interrupt 0 using 1{ readspi(); } void main(void){ static unsigned int spivalue; while(1){ } } Please help me to over come this problem
I am using Non interrupt SPI function only. That, most likely is your problem. SPI is REAL time NOT the friggin "real enough" but REAL. Non-interrupt SPI is likely not to be timely, even when presumed to be real enough" That interrupt code is more difficult than non-interrupt code is nothing but an urban legend Again, if you grab CodeArchitect, you will be amazed. Erik
Hi "Again, if you grab CodeArchitect, you will be amazed" I cann't get that code .Please help me to find it out.
I posted codearchitect for Philips LPC932 free from http://www.esacademy.com what is your problem "I can not get that code"? Erik
Hi Thanks a lot!I got code from http://www.esacademy.com and I solved my problem also.........