EmbeddedRelated.com
Forums
The 2024 Embedded Online Conference

RCM4300 MTU Stuck at 16

Started by "Fem...@femtodesigns.com [rabbit-semi]" January 28, 2016
>> Good day,
>> I'm hoping that someone could assist me with setting the MTU value for the RCM4300.
>> On boot-up the interface table reports that "eth MTU 16".
>
> Using the ETH_MTU macro has no effect, no matter which value I chose it remains at 16.
>
>> I can change the MTU of my RCM4010 to a value of my choice using the ETH_MTU macro.
>
>> Both modules are loaded with the same code.
>> I'm using DC 10.7.
>> Any idea where I can go and look?
>>
>> Regards
>> Mike
If ETH_MTU is not defined in your code, the value is defined in net.lib and is either 1500 or 1489, depending on whether WIFI is used and if the board is a R5000 series. 
 Are you sure you haven't defined it somewhere? I suggest using a printf() statementto send the value to the output window of the debugger and verify the value set.
printf("MTU: %d\r\n", ETH_MTU);
Steve

From: "Femto Com m...@femtodesigns.com [rabbit-semi]"
To: r...
Sent: Thursday, January 28, 2016 4:02 AM
Subject: [rabbit-semi] RCM4300 MTU Stuck at 16

 

Good day,
I'm hoping that someone could assist me with setting the MTU value for the RCM4300. 
On boot-up the interface table reports that "eth MTU 16". 

Using the ETH_MTU macro has no effect, no matter which value I chose it remains at 16. 
I can change the MTU of my RCM4010 to a value of my choice using the ETH_MTU macro. 
Both modules are loaded with the same code. 
I'm using DC 10.7. 
Any idea where I can go and look?

Regards
Mike

#yiv1099297717 #yiv1099297717 -- #yiv1099297717ygrp-mkp {border:1px solid #d8d8d8;font-family:Arial;margin:10px 0;padding:0 10px;}#yiv1099297717 #yiv1099297717ygrp-mkp hr {border:1px solid #d8d8d8;}#yiv1099297717 #yiv1099297717ygrp-mkp #yiv1099297717hd {color:#628c2a;font-size:85%;font-weight:700;line-height:122%;margin:10px 0;}#yiv1099297717 #yiv1099297717ygrp-mkp #yiv1099297717ads {margin-bottom:10px;}#yiv1099297717 #yiv1099297717ygrp-mkp .yiv1099297717ad {padding:0 0;}#yiv1099297717 #yiv1099297717ygrp-mkp .yiv1099297717ad p {margin:0;}#yiv1099297717 #yiv1099297717ygrp-mkp .yiv1099297717ad a {color:#0000ff;text-decoration:none;}#yiv1099297717 #yiv1099297717ygrp-sponsor #yiv1099297717ygrp-lc {font-family:Arial;}#yiv1099297717 #yiv1099297717ygrp-sponsor #yiv1099297717ygrp-lc #yiv1099297717hd {margin:10px 0px;font-weight:700;font-size:78%;line-height:122%;}#yiv1099297717 #yiv1099297717ygrp-sponsor #yiv1099297717ygrp-lc .yiv1099297717ad {margin-bottom:10px;padding:0 0;}#yiv1099297717 #yiv1099297717actions {font-family:Verdana;font-size:11px;padding:10px 0;}#yiv1099297717 #yiv1099297717activity {background-color:#e0ecee;float:left;font-family:Verdana;font-size:10px;padding:10px;}#yiv1099297717 #yiv1099297717activity span {font-weight:700;}#yiv1099297717 #yiv1099297717activity span:first-child {text-transform:uppercase;}#yiv1099297717 #yiv1099297717activity span a {color:#5085b6;text-decoration:none;}#yiv1099297717 #yiv1099297717activity span span {color:#ff7900;}#yiv1099297717 #yiv1099297717activity span .yiv1099297717underline {text-decoration:underline;}#yiv1099297717 .yiv1099297717attach {clear:both;display:table;font-family:Arial;font-size:12px;padding:10px 0;width:400px;}#yiv1099297717 .yiv1099297717attach div a {text-decoration:none;}#yiv1099297717 .yiv1099297717attach img {border:none;padding-right:5px;}#yiv1099297717 .yiv1099297717attach label {display:block;margin-bottom:5px;}#yiv1099297717 .yiv1099297717attach label a {text-decoration:none;}#yiv1099297717 blockquote {margin:0 0 0 4px;}#yiv1099297717 .yiv1099297717bold {font-family:Arial;font-size:13px;font-weight:700;}#yiv1099297717 .yiv1099297717bold a {text-decoration:none;}#yiv1099297717 dd.yiv1099297717last p a {font-family:Verdana;font-weight:700;}#yiv1099297717 dd.yiv1099297717last p span {margin-right:10px;font-family:Verdana;font-weight:700;}#yiv1099297717 dd.yiv1099297717last p span.yiv1099297717yshortcuts {margin-right:0;}#yiv1099297717 div.yiv1099297717attach-table div div a {text-decoration:none;}#yiv1099297717 div.yiv1099297717attach-table {width:400px;}#yiv1099297717 div.yiv1099297717file-title a, #yiv1099297717 div.yiv1099297717file-title a:active, #yiv1099297717 div.yiv1099297717file-title a:hover, #yiv1099297717 div.yiv1099297717file-title a:visited {text-decoration:none;}#yiv1099297717 div.yiv1099297717photo-title a, #yiv1099297717 div.yiv1099297717photo-title a:active, #yiv1099297717 div.yiv1099297717photo-title a:hover, #yiv1099297717 div.yiv1099297717photo-title a:visited {text-decoration:none;}#yiv1099297717 div#yiv1099297717ygrp-mlmsg #yiv1099297717ygrp-msg p a span.yiv1099297717yshortcuts {font-family:Verdana;font-size:10px;font-weight:normal;}#yiv1099297717 .yiv1099297717green {color:#628c2a;}#yiv1099297717 .yiv1099297717MsoNormal {margin:0 0 0 0;}#yiv1099297717 o {font-size:0;}#yiv1099297717 #yiv1099297717photos div {float:left;width:72px;}#yiv1099297717 #yiv1099297717photos div div {border:1px solid #666666;height:62px;overflow:hidden;width:62px;}#yiv1099297717 #yiv1099297717photos div label {color:#666666;font-size:10px;overflow:hidden;text-align:center;white-space:nowrap;width:64px;}#yiv1099297717 #yiv1099297717reco-category {font-size:77%;}#yiv1099297717 #yiv1099297717reco-desc {font-size:77%;}#yiv1099297717 .yiv1099297717replbq {margin:4px;}#yiv1099297717 #yiv1099297717ygrp-actbar div a:first-child {margin-right:2px;padding-right:5px;}#yiv1099297717 #yiv1099297717ygrp-mlmsg {font-size:13px;font-family:Arial, helvetica, clean, sans-serif;}#yiv1099297717 #yiv1099297717ygrp-mlmsg table {font-size:inherit;font:100%;}#yiv1099297717 #yiv1099297717ygrp-mlmsg select, #yiv1099297717 input, #yiv1099297717 textarea {font:99% Arial, Helvetica, clean, sans-serif;}#yiv1099297717 #yiv1099297717ygrp-mlmsg pre, #yiv1099297717 code {font:115% monospace;}#yiv1099297717 #yiv1099297717ygrp-mlmsg * {line-height:1.22em;}#yiv1099297717 #yiv1099297717ygrp-mlmsg #yiv1099297717logo {padding-bottom:10px;}#yiv1099297717 #yiv1099297717ygrp-msg p a {font-family:Verdana;}#yiv1099297717 #yiv1099297717ygrp-msg p#yiv1099297717attach-count span {color:#1E66AE;font-weight:700;}#yiv1099297717 #yiv1099297717ygrp-reco #yiv1099297717reco-head {color:#ff7900;font-weight:700;}#yiv1099297717 #yiv1099297717ygrp-reco {margin-bottom:20px;padding:0px;}#yiv1099297717 #yiv1099297717ygrp-sponsor #yiv1099297717ov li a {font-size:130%;text-decoration:none;}#yiv1099297717 #yiv1099297717ygrp-sponsor #yiv1099297717ov li {font-size:77%;list-style-type:square;padding:6px 0;}#yiv1099297717 #yiv1099297717ygrp-sponsor #yiv1099297717ov ul {margin:0;padding:0 0 0 8px;}#yiv1099297717 #yiv1099297717ygrp-text {font-family:Georgia;}#yiv1099297717 #yiv1099297717ygrp-text p {margin:0 0 1em 0;}#yiv1099297717 #yiv1099297717ygrp-text tt {font-size:120%;}#yiv1099297717 #yiv1099297717ygrp-vital ul li:last-child {border-right:none !important;}#yiv1099297717
Hi Steve,
Thanks for the reply.
I only set the MTU once right in beginning of my code.

I did as you suggested and added;

“printf("MTU:%d\r\n",ETH_MTU);”

I chose a value of 1400, and when I run it this I get:
“MTU:1400 “.

But if I also add “ip_print_ifs();” then I get this;
“Interface table:

# IP addr. Mask Up Lnk Type MTU Flags Peer/router
-- --------------- --------------- --- --- ---- ---- ------ ---------------
0 192.168.1.10 255.255.255.0 yes yes eth 16 * 192.168.1.254 “

I run this in a loop to see if anything is changing and it provides the same output messages.

To me it appears if the macro value is being set correctly but not being implemented?

Below are the only macros that I set;
//-----------------------------------
#define HTTP_MAXSERVERS 4
#class auto
#define RWEB_ZHTML_MAXVARLEN 1024
#define HTTP_MAXBUFFER 1024
#define USE_RABBITWEB 1
//

The complete system works fine but I must know if the MTU is set to 1500 or some higher value than 16.

Regards,
Mike

From: r... [mailto:r...]
Sent: Thursday, January 28, 2016 5:01 PM
To: r...
Subject: Re: [rabbit-semi] RCM4300 MTU Stuck at 16

If ETH_MTU is not defined in your code, the value is defined in net.lib and is either
1500 or 1489, depending on whether WIFI is used and if the board is a R5000 series.

Are you sure you haven't defined it somewhere? I suggest using a printf() statement
to send the value to the output window of the debugger and verify the value set.

printf("MTU: %d\r\n", ETH_MTU);

Steve

_____

From: "Femto Com m...@femtodesigns.com [rabbit-semi]"
To: r...
Sent: Thursday, January 28, 2016 4:02 AM
Subject: [rabbit-semi] RCM4300 MTU Stuck at 16

Good day,
I'm hoping that someone could assist me with setting the MTU value for the RCM4300.
On boot-up the interface table reports that "eth MTU 16".

Using the ETH_MTU macro has no effect, no matter which value I chose it remains at 16.

I can change the MTU of my RCM4010 to a value of my choice using the ETH_MTU macro.

Both modules are loaded with the same code.
I'm using DC 10.7.
Any idea where I can go and look?
Regards
Mike
From what I can see ip_print_ifs() actually prints the minimum MTU across all the interfaces.

Regards,
Peter
Hi Peter,

Thanks.
If I use my RCM4010 then ip_print_ifs() correctly reports the MTU as set by the macro.
So the problem is specific to the RCM4300 module.
If you're using Dynamic C 10.70, please try with 10.72 and see if that changes anything.

If not, can you take one of the simplest networking samples (maybe one of the PING samples) and see what ip_print_ifs() reports there? We need to isolate the issue, and find out if its present in the 10.72 libraries, or if it's something in the configuration of your particular program.

-Tom
On Jan 28, 2016, at 9:45 PM, m...@gmail.com [rabbit-semi] wrote:

> Hi Peter,
>
> Thanks.
> If I use my RCM4010 then ip_print_ifs() correctly reports the MTU as set by the macro.
> So the problem is specific to the RCM4300 module.
Hi Tom,

I am using DC 10.72.

I see that there is a patch "DC10.72_tcp_patch.zip" available, I haven't applied this yet.
After I have applied this I will repeat the tests again.

Regards,
Mike
Hi Tom,

I am using DC 10.72.

I see that there is a patch "DC10.72_tcp_patch.zip" available, I haven't applied this yet.
After I have applied this I will repeat the tests again.

Regards,
Mike
Hi Tom,

I am using DC 10.72.

I see that there is a patch "DC10.72_tcp_patch.zip" available, I haven't applied this yet.
After I have applied this I will repeat the tests again.

Regards,
Mike
Hi Tom,

I am using DC 10.72.

I see that there is a patch "DC10.72_tcp_patch.zip" available, I haven't applied this yet.
After I have applied this I will repeat the tests again.

Regards,
Mike

The 2024 Embedded Online Conference