OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [tags/] [nog_patch_61/] [or1ksim/] [peripheral/] [16450.c] - Diff between revs 529 and 530

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 529 Rev 530
Line 408... Line 408...
          uarts[i].istat.break_set = 0;
          uarts[i].istat.break_set = 0;
      }
      }
 
 
    /***************** Transmit *****************/
    /***************** Transmit *****************/
    if (!uarts[i].istat.txser_full) {
    if (!uarts[i].istat.txser_full) {
      uarts[i].regs.lsr |= UART_LSR_TXBUFE;
//      uarts[i].regs.lsr |= UART_LSR_TXBUFE;
      if (uarts[i].istat.txbuf_full) {
      if (uarts[i].istat.txbuf_full) {
        uarts[i].iregs.txser = uarts[i].regs.txbuf[uarts[i].istat.txbuf_tail];
        uarts[i].iregs.txser = uarts[i].regs.txbuf[uarts[i].istat.txbuf_tail];
        uarts[i].istat.txbuf_tail = (uarts[i].istat.txbuf_tail + 1) % uarts[i].fifo_len;
        uarts[i].istat.txbuf_tail = (uarts[i].istat.txbuf_tail + 1) % uarts[i].fifo_len;
        uarts[i].istat.txser_full = 1;
        uarts[i].istat.txser_full = 1;
        uarts[i].istat.txbuf_full--;
        uarts[i].istat.txbuf_full--;
        uarts[i].regs.lsr &= ~UART_LSR_TXSERE;
        uarts[i].regs.lsr &= ~UART_LSR_TXSERE;
        uarts[i].istat.thre_int = 1;
        uarts[i].istat.thre_int = 1;
      } else
      } else {
        uarts[i].regs.lsr |= UART_LSR_TXSERE;
        uarts[i].regs.lsr |= UART_LSR_TXSERE;
 
        uarts[i].regs.lsr |= UART_LSR_TXBUFE;
 
      }
    } else if (uarts[i].char_clks <= uarts[i].istat.txser_clks++) {
    } else if (uarts[i].char_clks <= uarts[i].istat.txser_clks++) {
      send_char(i, (uarts[i].regs.lcr & UART_LCR_WLEN8) + 5); /* We've sent all bits */
      send_char(i, (uarts[i].regs.lcr & UART_LCR_WLEN8) + 5); /* We've sent all bits */
    } else {
    } else {
      /* We are still sending char here*/
      /* We are still sending char here*/
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.