We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
what is a re-entrant code? again what is re-entrant kernel?
thank you ece tech
To make Per happy: This relates to the '51 Since the OP started the thread with C51 I have changed MCU back to the C51 to stay with the OPs intent.
I have never used reentrant code. Yes, I have had cases where it might have been desirable (e.g. a function shared by an ISR and main) but the potential debugging nightmare has kept me from using reentrant code.
I think the OPs worry that he 'might' have reentranr code is greatly overblown. Just make sure that all functions called from ISRs (if you absolutely have to have them) have names that are e.g. ISR..... and no ISR.... function is called from main.
Erik
PS the one '51 case I can see for reentrant code would be to 'core use squeeze' a unit that was to be made in millions.