At 08:05 AM 11/28/02 +0000, you wrote: >The SSPIF bit is set when the byte in SSPBUF has been transmitted, but there >is no requirement for this to fire an interrupt. You can simply mask off >the MSSP interrupt (SSPIE = 0) and poll the SSPIF bit in a loop. > >If you really want to use interrupts, then you will have to make some >arrangement so the ISR knows how many bytes it needs to send. When sending >data on the SPI, set a counter holding the number of bytes to send. After >sending each byte, the counter can be decremented in the ISR until it is >zero. IMO, there's little reason to use interrupts with an SPI master running at high speed, the cycles after a transfer is initiated are both few in number and fixed. Best regards, Spehro Pefhany --"it's the network..." "The Journey is the reward" speff@interlog.com Info for manufacturers: http://www.trexon.com Embedded software/hardware/analog Info for designers: http://www.speff.com -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads