On Fri, 9 Jan 2004 22:08:58 +0100, Jan-Erik Soderholm XA (TN/PAC) wrote on Re: [PIC:] Pic as an i2c slave. Debug bits: >Robert Soubie wrote : > >> I have browsed the whole assembler file compild fo my "big" >> (8k) application, and found no trace of interrupt stuff >> (enabling or disabling) by the compiler. This is what >> thought I would find, because that compiler has a special >> system for interrupts, that are delayed under the current >> basic instruction has been executed; in other words, basic >> routines cannot be iterrupted in the immediate sens of the >> term. > >It's very possible that the Basic compiler has something called >"interrupts" that isn't the same thing as what a ASM programmer >would call an "interrupt". That is, it's not unlikely that >the hardware (PIC) always has interrupts enabled, but the >Basic RT (Run Time) environment "hides" this from >the higher level code and also, as you point out, delays >the execution of the *Basic* ISR until the current Basic >"statement" has finished. You are correct; this is what is explained at http://microengineeringlabs.com/resources/pbpmanual/5_42-5_47.htm#544. However the documentation says it is possible to implement "assembler interrupts"; the two kinds being mutually exclusive.=20 This is explained at http://microengineeringlabs.com/resources/pbpmanual/9_0.htm#93, where there is an explanation on what to save and how to do it; the procedures I use that implement that have been written by Timothy Box, a very nice and helping member of both the PicBasic list and our list.=20 A (much) more elaborated version for the 18F series has been written by Darrel Taylor.=20 =46or the time being, I work under the assumption that the context saving routines are correct and the compiler is weel behaved; I still have to run more tests to really understand what went wrong so far; this is a rainy WE, so back to work! Thanks again for your help. * Xrobert.soubie@free.frX (veuillez supprimer les "X") * http://www.astrosurf.com/soubie * Au royaume des aveugles, les borgnes sont mal vus... - P.Dac -- http://www.piclist.com#nomail Going offline? Don't AutoReply us! email listserv@mitvma.mit.edu with SET PICList DIGEST in the body