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.

RTOS/LAUNCHCC3220MODASF: Example tcpEcho

Part Number: LAUNCHCC3220MODASF
Other Parts Discussed in Thread: CC3220SF

Tool/software: TI-RTOS

Hi all,

I have a problem with the tcpEcho example. The board starts, connects to my Wifi environment, opens the socket 1000 and I can connect with a telnet client. I can send messages and receive the echo.

The program runs in a debug session (not flashed).

[NETAPP EVENT] IP Acquired: IP=192.168.178.30 , Gateway=192.168.178.1                                                                                         
TCP Echo example started
tcpHandler: Creating thread clientfd = 1
tcpWorker: start clientfd = 0x1                                                 
tcpHandler: Creating thread clientfd = 2                                        
tcpWorker: start clientfd = 0x2

So far so good. But some seconds/ minutes later the board stops communication. The board also disappears from the list of connected devices in my AP.

There is also no serial debug output at this moment. Some minutes later I got the debug output: "tcpWorker stop clientfd" for each opened connection. The board is in a disconnected state and doesn't reconnect.

The same things happens if I ping the board. After some time the ping command tells me: "Destination Host Unreachable".

Does anybody know what could be the reason for this? The level of the Wifi signals seems to be all right.

Is there an callback which I can connect to my serial debug output?

I am new to this area so please forgive me if that is a stupid question. ;)

Many thanks,

Roman Jordan

  • Hi,

    I tried reproducing what you're seeing with my CC3220SF launchpad and the tcpecho example but could not get it to fail in the way that you are describing. I had my PC connected using telnet to the CC3220, and also had another device running the python script provided in the SDK to continuously send the CC3220 data. The CC3220 was running off of a CCS debug session during this test. Nothing unusual happened over the 2 hours I had the CC3220 + connected devices running.

    Do you have the latest servicepack flashed onto the CC3220?
    Exactly what are you running on your setup? Are you using an untouched tcpecho example from the latest SDK? What programs are you running to connect to the CC3220? Have you tried reproducing this behavior when running the test python script located at <sdk dir>/tools/cc32xx_tools/echo-python-scripts/ ?

    Regards,
    Michael
  • Hi Michael,

    many thanks for your help.

    Yes I flashed the latest service pack (from SDK 3.x) onto the board. I use telnet client on a CentOS7 system . In the example code I only changed the Wifi access data.

    No, I not tried the echo-python-scripts until now. It seems to be a python 3.x script and there is no offical Python 3 for CentOS7. I will check it with an computer running Python 3 soon.

    There are also a lot of Wifi networks around me. Maybe that is a problem too. I also implemented Debug prints in some SL-callback functions. I only see an output if I disable the Wifi AP. In my normal test environment the connections simply stops without any debug message.

    My next steps are: flash it, check Python script, bring the board closer to the AP,

    Many thanks,

    Roman

  • Hi Roman,

    I assume that you have resolved your issue since I have not heard back from you. If not, feel free to post a response to this thread, or open a new thread regarding this issue.

    Regards,
    Michael

  • Hello,

    I made some tests about it. The problem still exists if I start the test with the python scripts some minutes later after I started the board.

    If I start the board and some seconds later the python scripts everything works fine. I tested for several hours. If I disconnect for some minutes the connection will not be  rebuilt. I need a hardware reset on the board.

    I see this behaviour also if I start the application on the board and do nothing for 2 or 3 minutes. The serial debug output shows me that the board is connect to my Wifi. But I can't connect with the python scripts. The router tells me in this case: Yes, there was something with that MAC id, but it is gone some seconds ago.

    I think I have to take a look into the power documentation of this module. I remember there was one document which describes it (ti_drivers_net_wifi_config).

    Thanks a lot and best regards, Roman

  • Hi Roman,

    The ti_drivers_net_wifi_config affect some of the Wi-Fi startup settings, but it does not directly affect the power saving settings of the device. Those settings would be in CC3220SF_LAUNCHXL.c, in the PowerCC32XX_config struct. However, those power settings by default should be set at the stable, high-power normal power settings as enablePolicy = false.

    Given that you mention the particularly congested Wi-Fi environment, have you tried running your setup while connected in a less crowded environment? Perhaps using a different AP will also affect things.

    Do you get any error messages from the async event handlers such as SimpleLinkNetAppEventHandler()? If you get disconnected from your AP or some error happens, you should get some event to handle in those functions.

    Regards,

    Michael

  • Hello,

    i will come back soon. First I have to think about my own board.

    Please stay tuned and many thanks,

    Roman