This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

lwip settings to access embedded device from different network

Other Parts Discussed in Thread: TM4C1294KCPDT, LM3S6965

Hello ,

Can any one suggest me what settings do I need to access my device from different network? Two different networks are connected to each other using router.

Example: My device IP & Gateway are: 192.168.4.abc .

Now i want to access it from PC having IP & Gateway as: 168.194.4.xyz.

Note: Both networks are connected to each other via router.

Any help is appreciable.

  • Hi,

    LWIP can be used in multiple TI device families. In order to redirect you to the proper experts that can help you, I need to know: which device are you using?

    Regards,
    Rafael
  • Thank you for the reply.

    I am using Tiva TM4C1294KCPDT device. 

    Need some lwIP 1.4.1 version library settings to allow gateway access via routers.

    Previously I was using lwIP 1.3.2 on Luminary controller and on that Gateway concept was working properly...

  • Hello Urvi,

    This is an interesting application and I have not done this before. Can't you use the same settings that worked with lwIP 1.3.2 on lwIP 1.4.1? Can you share the settings that worked with lwIP 1.3.2?

    Thanks,
    Sai
  • Hello Sai,

    My application is: I have 1 TI based device in one network i.e. 192.168.0.1 and PC in other network i.e. 192.168.1.1

    When I try to open (or even ping) tcp socket through ethernet, its not opening socket.

    (Note: Same application is working with Luminary LM3s6965 device with lwIP1.3.2.)

    Then We tried to implement lwIP1.3.2 on TI & removed lwIP 1.4.1. But then also its not working on TI.

    Kindly send me your email id so that i can send you my .c & .h files. You can check and suggest me where am i going wrong?

  • Hello Urvi,

    Looks like you are configuring the TM4C device and PC as Gateways (because you are assigning the IPs xxx.xxx.x.1). Is this assumption correct? In an earlier post you say that a router is used in between both the networks. I am not clear how this is supposed to work.

    Typically two networks are connected using a router and the router manages where the packets end up. So ideally you should not change anything on the lwIP front.

    Are you able to ping the TM4C device (running lwIP 1.4.1) from a PC that is on the same network?

    Thanks,
    Sai
  • Hello everyone,

    Problem solved. The MAC address is written wrong (MSB & LSB bytes are swapped while configuring Ethernet). 

  • Hello Urvi,

    Glad you were able to resolve this issue!

    Just out of curiosity I wanted to know if you were able to ping the TM4C device from a PC in the same network (before you fixed the MAC address swap issue). I would imagine you would have had the same problem, but wanted to check.

    Thanks,
    Sai
  • Hello Sai,

    Yes, I was able to ping TM4C device from same network (before you fixed the MAC address swap issue). Bcoz, the router doesn't come into picture in this case.

    But when I tried to ping device from other network, the router comes into picture. In this case, router checks the device in its routing table and as my MAC was incorrect, i won't allow me to ping/access my device.