This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Nrf51 IOT TCP Client testing

Hi All,

we have PCA10028 v1.10 nordic development board, i tested the normal ping from local ip and global ip of device from my linux PC by flashing tcp client iot application , which is working fine.

but data transmission between client and server is not working , basically server is not connecting to client by using phyton server code.

Here my server ip config.

bt0 Link encap:UNSPEC HWaddr 68-94-23-FF-FE- 8A-45-50-00-00-00-00-00-00-00-00
inet6 addr: fe80::6a94:23ff:fe8a:4550/64 Scope:Link inet6 addr: 2001:db8::9586:dfba:1684:a501/64 Scope:Global inet6 addr: 2001:db8::1/64 Scope:Global inet6 addr: 2001:db8::6a94:23ff:fe8a:4550/64 Scope:Global UP POINTOPOINT RUNNING MTU:1280 Metric:1 RX packets:630 errors:0 dropped:0 overruns:0 frame:0 TX packets:1019 errors:579 dropped:120 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:32434 (32.4 KB) TX bytes:70649 (70.6 KB)

So i changed the ip in server with my pc ip (2001:db8::6a94:23ff:fe8a:4550). but connection is not happened.

Kindly let me know what is the issue.

and also i bit confused with how to access device from internet. kindly let us know.

Regards Punith

  • Could you please explain a bit more about your setup? How are you routing this? Are you using a RPi? Have you performed any other ping tests than PC to nRF51 DK?

  • Hi Petter,

    I am doing in My ubuntu PC 14.04 linux 3.17. Now tcp client is working fine with my PC and problem is , i did not change the client code with proper server ip.Once i change it works fine.

    Right now my server code is running on router itself , so i can control device. But if i want to control the device from outside world , how to do it. Give any example code for that , i am good at linux also , kindly suggest any solution. I assigned global ip for both device and router.

    Regards Punith

  • Hi All,

    I able to control device (DK) from my router and my PC (both are connected to LAN). Now i want to control device from outside world ?. How to do it?.

    My router is pinging both google.com and ipv6.google.com. And also both device and router has global ipv6 address.

    Kindly suggest me.

    Regards Punith

  • Hi,

    It seems you have native IPv6 connectivity. What ipv6 address and prefix is your router getting?

    Have you set up RADVD so that the nRF51 DK gets the correct prefix? It should be something like:

    interface bt0
    {
    	AdvSendAdvert on;
    	prefix 2002:c213:5692::1/64
        {
    	    AdvOnLink off;
        };
    };
    

    (This is from my 6to4 tunneling setup)

    You also need to add the prefix to the bt0 interface and restart radvd:

    ifconfig bt0 add 2002:c213:5692::1/64
    service radvd restart
    

    You can try to ping the nRF51 DK from the internet here.

    Edit 21.05.2015: Corrected IPv6 address/prefix of bt0 interface

  • yes i added prefix and started radvd service also but device is not pinging from internet.

    Here is my configuration

    interface eth0
    {
    AdvSendAdvert on;
    prefix 2005:abc::/64 {
    AdvOnLink on;
    AdvAutonomous on; AdvRouterAddr on;
    };
    route ::/0
    {
    };
    };

    interface bt0
    {
    AdvSendAdvert on;
    prefix 2001:db8::/64
    {
    AdvOnLink off;
    AdvAutonomous on;
    AdvRouterAddr on;
    };
    };

    And also i added these from command line

    ifconfig bt0 add 2001:db8
    ifconfig eth0 add 2004:abc::1/64::1/64
    service radvd restart

    Now able to ping device from my pc and by router but not by internet.

    Kindly suggest me , where i am missing.

    Regards Punith

Related