Re: 89C51ED2





MooseFET wrote:

Eeyore wrote:
MooseFET wrote:
"TT_Man" <Some...@xxxxxxxxxxxx> wrote:
">>>> >> I think he said it was all written in asssembler <yuk>.

On an 8051, asm is really the way to go. The OP was making comments
about DPTR so I suspected asm but vagueness of his descriptions
sounded like a C programmer who doesn't really know what is going on
under the hood. Many C compilers overlay variables on the 8051 if he
is doing interrupts in C code he may be running a routine in the
interrupt code that overlays one of his variables.

Graham

Not a prayer in hell 100% assembler. :)

Are you using interrupts?

Everything is interrupt driven. Processor spends 99% in sleep mode.Int
routines set flags and the background processes flags, then goes back to
sleep. Dual 3 of 5 uarts are processed with 125uS RTC.

I think you need to look very carefully at the interrupt code to make
sure that it doesn't forget to save part of the context. This sounds
like it is either timing related or an uninitialized flag.

Hmmm that's not how to code 8051 inrterrupts.

Huh??????

Do you mean that you don't save the interrupted context???? !!!!!

I can't remember my reason for saying that now. Flags perhaps ?

Anyway PL/M handles all that for one. Declare procedure interrupt !

Graham

.



Relevant Pages

  • [S390] cio: update documentation.
    ... -Prior to call ccw_device_startthe device driver must assure disabled state, ... -by calling local_save_flags(flags). ... -environment an interrupt might be presented prior to the ccw_device_start ... +ccw_device_startmust be called disabled and with the ccw device lock held. ...
    (Linux-Kernel)
  • Re: [PATCH] serial: 8250: add IRQ trigger support
    ... serial IRQs with triggering requirements ... Note that this patch doesn't allow the interrupt to trigger on both ... the irqflags the flags field. ...
    (Linux-Kernel)
  • Re: 89C51ED2
    ... Flags perhaps? ... Anyway PL/M handles all that for one. ... Declare procedure interrupt! ... doing the same thing or calling functions with in that block that are also ...
    (sci.electronics.design)
  • [patch] consolidate interrupt-related constants
    ... handling code was recently consolidated, ... it looks likely that the related flags ... for interrupt handling. ... a flags into an i386-specific header ...
    (Linux-Kernel)
  • Re: 89C51ED2
    ... Everything is interrupt driven. ... routines set flags and the background processes flags, ... But I've never trusted "sleep mode" - probably because it takes me about ...
    (sci.electronics.design)