discuss-gnuradio
[Top][All Lists]
Advanced

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

Re: [Discuss-gnuradio] Regarding 371 samples/frame in usrp2


From: Eric Blossom
Subject: Re: [Discuss-gnuradio] Regarding 371 samples/frame in usrp2
Date: Wed, 5 Nov 2008 09:20:38 -0800
User-agent: Mutt/1.5.18 (2008-05-17)

On Wed, Nov 05, 2008 at 06:15:03PM +0100, Mattias Kjellsson wrote:
> I have been playing with ioctl's today and while browsing the USRP2-  
> code i found that max length of a packet is defined to 371 which results  
> in 1484 bytes of "data", and 16 bytes left, leaving room for the 14 byte  
> ethernet header, but not a 372:nd sample, since each sample is 4 bytes.
>
> But when I look at the output of ifconfig my MTU is set to 1500, but  
> when I print out how much data is received from a raw socket (listening  
> to some random network traffic), it tells me it reads max 1514 bytes,  
> which I figured is 1500 bytes of data, and 2*6 bytes mac- addresses + 2  
> bytes of protocol. This gives me two questions. Is there (probably)  
> something I missed here, or should we be able to increase U2_MAX_SAMPLES  
> to 375 (1500/4 = 375), not that four samples might make a huge  
> difference in the end, but still... And the other question, shouldn't  
> one check for the MTU set by the nic and calculate this number, instead  
> of having it #defined? But then again, it would be a whole lot of re-  
> writing, since U2_MAX_SAMPLES is #defined... Or have I missed some  
> fundamental here?
>
> BR
> Mattias Kjellsson

There are a couple of headers.  See usrp2_eth_packet.h (This format is
all subject to change.)  We'll be modifying the code so that it checks
for the actual MTU and does the right thing.  It's ticket:310.

Thanks for your concern,
Eric




reply via email to

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