2008-12-02 02:51:53 Software UART on BF537
Patrick Hotz (GERMANY)
Message: 66122
Is there any way to get more than two UARTS on BF537?
I need four UARTS and think there should be a possibility to emulate the two other UARTS through software with some GPIOs.
Is there any ready software to do this?
Thanks,
Patrick
TranslateQuoteReplyEditDelete
2008-12-02 02:56:44 Re: Software UART on BF537
Mike Frysinger (UNITED STATES)
Message: 66124
there is no GPIO UART bit banging driver ... seems pretty unlikely that there will be one as keeping the output stable and exact for clocking is a pretty tough job, especially at higher speeds.
review the SPORT/UART emulation to see if it'll meet your needs:
http://docs.blackfin.uclinux.org/doku.php?id=linux-kernel:drivers:bfin_sport_uart
QuoteReplyEditDelete
2008-12-02 03:30:40 Re: Software UART on BF537
Patrick Hotz (GERMANY)
Message: 66125
I am not shure if i understand the SPORT/UART emulation.
The SPORT has 8 pins but the UART only two....
Which pins should i use?
The UART0 use one Tx and one Rx....
The cause I want to use four UARTS is that i want to connect the UART0 to my PC, the UART1 to a microcontroller ant the other two UARTS to a electric water-meter and a electric power-meter.
TranslateQuoteReplyEditDelete
2008-12-02 03:50:16 Re: Software UART on BF537
Mike Frysinger (UNITED STATES)
Message: 66126
the documentation refers to the appnote EE-191 which contains plenty of hardware info
QuoteReplyEditDelete
2008-12-02 06:39:48 Re: Software UART on BF537
Patrick Hotz (GERMANY)
Message: 66157
Hi Mike,
the SPORT-UART emulation is unhappily not the answer of my problem.
I have already a Sound-Codec connected to my SPORT0.
Is there a chance to use a SPI-UART adapter or something like that?
TranslateQuoteReplyEditDelete
2008-12-02 06:55:42 Re: Software UART on BF537
Mike Frysinger (UNITED STATES)
Message: 66159
the BF537 has two SPORTs ...
i'm not aware of anyone hooking a UART directly to the SPI bus, nor do i think it's possible. you'd need some logic in between to regulate things. and you'd need to write a new driver to glue the two layers together (SPI and serial core).
i imagine it's possible to make it work eventually, but i'm not aware of any easy drop-in solutions. you'd probably get better info from googling "SPI UART" ...
QuoteReplyEditDelete
2008-12-08 12:02:45 Re: Software UART on BF537
Steve Strobel (UNITED STATES)
Message: 66509
We are using a SC16C554 quad-UART on a BF537. It is connected to the parallel rather than SPI bus, so I don't know if it would be an option for you or not. We are just polling it from our application software rather than using a typical tty driver, so I can't help you there, but I would be glad to send the polling driver we use.
It may not be a great choice if you need to send lots of data quickly at least if you poll it like we do, because as I recall, there isn't a great way to know when the transmit fifo is full. I think we count characters sent to avoid overflowing it, wait until it is empty and repeat. That results in a short delay each time the fifo empties before we fill it again. Using the UART's interrupt output might allow for a better solution.
Steve