discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Discuss-gnuradio] putchar function


From: Eric Blossom
Subject: Re: [Discuss-gnuradio] putchar function
Date: Mon, 1 Feb 2010 14:51:18 -0800
User-agent: Mutt/1.5.20 (2009-08-17)

On Mon, Feb 01, 2010 at 05:57:04PM +0100, Christoph Thein wrote:
> Hi,
> 
> I am trying to figure out how it is possible to get more than the "U" message 
> from the USRP2 to the host via the UART port but I am stucked at some point. 
> When I try to transmit other characters than "U" I am receiving something 
> completely unpredictable (at least it looks like that to me at the moment). I 
> am using the putchar-function in the txrx.c file in the firmware/apps 
> directory 
> with the gnuradio version 3.3git-601-g18578e23 . 
> 
> I dug deeper into the code and tried the hal_uart_putc function also but with 
> no results. 
> 
> Does anyone have an idea how to achieve a working signaling throught the UART 
> port? 
> 
> Thanks a lot,
> Cheers,
> Christoph

Christoph,

It's just about impossible to get anything more than a few characters
out in the hard real-time part of the code (pretty much everything
after start-up), without causing a problem.  This is because we don't
have "infinite buffering", and eventually the code calling the uart
output primitive blocks, causing all kinds of bad things to happen.
You could make the uart output code interrupt driven, but in general,
that will only buy you another 128 bytes or so (whatever memory you're
willing to dedicate to the buffer) before the problem occurs.

If you've got a logic analyzer to grab the data, and the ISE tools,
it's not too hard to add an additional "setting register" that when
written to, will end up on the mictor debug connector on the
motherboard, or on the GPIO pins of a Tx or Rx Basic/LF daughterboard.
(In lib/memory_map.h add an entry to output_regs_t, and add the
setting register itself in fpga/top/u2_core/u2_core.v).

Eric




reply via email to

[Prev in Thread] Current Thread [Next in Thread]