Sign in

username:

password:



Not a member?

Search Comp.Arch.Embedded



Search tips

embedded by Keywords

68HC11 | 68HC12 | 8051 | 8052 | ARM | ARM7 | Asic | AT91 | AT91RM9200 | Atmel | AVR | AVRStudio | Bootloader | CFP | CompactFlash | Cygnal | Cypress | Dataflash | DSP | eCos | EEPROM | Embedded Linux | Emulator | Endian | Ethernet | Firewire | FPGA | Freescale | GCC | GNUARM | GSM | H8 | HDLC | I2C | Infineon | Interrupts | Java | JTAG | LCD | LED | LPC2000 | MCU | Microchip | MMC | MPLAB | MSP430 | PC104 | PCB | PCI | PCMCIA | PowerPC | Rabbit | RS232 | RS485 | RTOS | SBC | SDRAM | Sensor | SPI | STK500 | UART | UML | USART | USB | Verilog | VHDL | VxWorks | Xilinx

Ads

Discussion Groups

Discussion Groups | Comp.Arch.Embedded | UARTs and interrupts

There are 27 messages in this thread.

You are currently looking at messages 20 to 27.

Re: UARTs and interrupts - Grzegorz Mazur - 11:10 16-05-05

Neil Kurzman wrote:
>>My own experience follows the teaching of one of my mentors in that one very
>>rarely  (if ever)  needs to disable interrupts.  In the 8051 world, use
>>interrupt priority, short service routines and amenable data structures.  In all
>>of our 8051 communication products, I can not think of one that runs with
>>interrupts disabled.  Being an assembly language dinosaur helps here.
> 
> 
> OK so how do you do a ring buffer without disabling interrupts during RX read , or a
> Tx write?
> The Interrupt could hit during that time.  The Keil C sample disables RI during that
> time.

The 51 core disables the interrupts while servicing an interrupt. It's 
THAT simple. Assuming you don't use different priorities for the 
interrupts refering to the same resource.



Re: UARTs and interrupts - Ian Bell - 15:45 16-05-05

Grzegorz Mazur wrote:

> 
> The 51 core disables the interrupts while servicing an interrupt. It's
> THAT simple. Assuming you don't use different priorities for the
> interrupts refering to the same resource.

The 8051 core disables interrupts OF THE SAME PRIORITY while servicing an
interrupt. An interrupt of a higher priority can interrupt one of a lower
priority. In the old days it was still simple because the original 8051 had
only two interrupt priority levels. However, some modern derivatives have
more.

Ian


Re: UARTs and interrupts - Neil Kurzman - 01:19 17-05-05

I did not quite get a yes or no. I am using this on a PIC and 8051.
The Keil C example had interrupt disabled, so I did not look at it in detail.  I will
look to see if it can be done.
I an not a big fan of disabled interrupts.  I messes up the latency of the other
interrupts.


Re: UARTs and interrupts - Frieder Ferlemann - 03:44 17-05-05

Neil Kurzman schrieb:
> I did not quite get a yes or no. I am using this on a PIC and 8051.
> The Keil C example had interrupt disabled, so I did not look at it in detail.  I will
> look to see if it can be done.
> I an not a big fan of disabled interrupts.  I messes up the latency of the other
> interrupts.
> 

An example for a buffer feeding routine without disabled interrupts
for the 8051 is given in section 3.12 "Inline Assembler Code" of
http://sdcc.sourceforge.net/doc/sdccman.pdf

Greetings,
Frieder

Re: UARTs and interrupts - Grant Edwards - 11:42 17-05-05

On 2005-05-17, Neil Kurzman <n...@mail.asb.com> wrote:

> I did not quite get a yes or no.

Gee.  Maybe there is no "yes or no" answer.

-- 
Grant Edwards                   grante             Yow!  Put FIVE DOZEN red
                                  at               GIRDLES in each CIRCULAR
                               visi.com            OPENING!!

Re: UARTs and interrupts - Neil Kurzman - 00:26 18-05-05


Frieder Ferlemann wrote:

> Neil Kurzman schrieb:
> > I did not quite get a yes or no. I am using this on a PIC and 8051.
> > The Keil C example had interrupt disabled, so I did not look at it in detail.  I will
> > look to see if it can be done.
> > I an not a big fan of disabled interrupts.  I messes up the latency of the other
> > interrupts.
> >
>
> An example for a buffer feeding routine without disabled interrupts
> for the 8051 is given in section 3.12 "Inline Assembler Code" of
> http://sdcc.sourceforge.net/doc/sdccman.pdf
>
> Greetings,
> Frieder

Thanks I will look.



Re: UARTs and interrupts - Neil Kurzman - 00:26 18-05-05


Grant Edwards wrote:

> On 2005-05-17, Neil Kurzman <n...@mail.asb.com> wrote:
>
> > I did not quite get a yes or no.
>
> Gee.  Maybe there is no "yes or no" answer.
>
> --
> Grant Edwards                   grante             Yow!  Put FIVE DOZEN red
>                                   at               GIRDLES in each CIRCULAR
>                                visi.com            OPENING!!

I hate when that happens.



previous | 1 | 2 | 3