Setting up RTCS for FRDM64KF gateway pourposes and PPP

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Setting up RTCS for FRDM64KF gateway pourposes and PPP

548 Views
tiagogermano
Contributor I

Hi,

I´m using the FRDMK64F kit to test the firmware while the PCB is being developed.

The final pourpose if to create a Gateway with a 3G module.

I´m using MQX 4.1 and RTCS, using the KDS IDE.

In my application, I´m redirecting IP packets from the Ethernet to the PPP channel in the serial.

The PPP in serial is already working. I have a 3G modem connected in it and I´m able to establish a connection to the mobile network without problems.

My MK64F will be used as a gateway.

I have some issues to get reply from the Internet for a host request in the Ethernet

2 cases:

Case A)

In this case, I enabled the NAT. Now I´m able to get replies for IP packets from the Ethernet host to the Internet via the PPP channel, but, there is a problem:

- With NAT enabled, the host in the Ethernet can PING a address in the Internet and also some telnet connections are possible too.

- But, when I try to open a HTTP connection, it does not work. I see some replies in the PPP channel. I´m using also a ethernet sniffer where I can see that there are problems with "fragment packets".

So, by looking at the MQX_RTCS_USER_GUIDE.pdf I see that this is really a limitation when using NAT. It is written there.

Case B)

* Withou NAT enabled.

- I think I do not need to use NAT. I just enabled NAT (in case A) bacause I could not get a reply from the internet even for a PING sent from the Ethernet Host. I wonder if the gateway protocols work well, like EGP or GGP or RIP, and if this could be the reason for the reply from the internet is not coming back to my PING request from the Ethernet host. I see that no EGP, GGP or other gateway protocol is coming out throught the PPP channel. May be there is something missing in my setup of the RTCS library.

Do you have any suggestions for the case A or case B? I think case B is just a matter of setting up the RTCS correctly, but I did not find what to do and not sure if the RCTS support this GGP or EGP protocols.

I tried to use

"RTCSCFG_ENABLE_RIP=1"

"RTCSCFG_ENABLE_GATEWAYS=1"

without success so far.

Any help is very welcome.

Thanks in advance,

Labels (1)
0 Kudos
2 Replies

260 Views
RadekS
NXP Employee
NXP Employee

Yes, some of protocols didn’t work with NATs.

I agree that you shouldn’t need NAT.

I suppose that there will be some problem in routing.

As first, I would like to recommend add default gateway as:

RTCS_gate_add(ip_address, 0, 0) where ip_address will be remote IP of your PPP connection.

This way RTCS will check routing rules and if it doesn’t found any record for destination address, it will send packet to default gateway.

Optionally you can try work directly with IP_route_add_xxx() function to create routing rule for RTCS stack.

Note:

To add a gateway with address ip_address to reach subnet e.g 192.168.1.0/24, call:

RTCS_gate_add(ip_address, 0xC0A80100, 0xFFFFFF00)

I hope it helps you.

Have a great day,
RadekS

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos

260 Views
Martin_
NXP Employee
NXP Employee

for A) try with RTCSCFG_ENABLE_IP_REASSEMBLY=1

-Martin

0 Kudos