Good method to reset the tcp connection after timeout error

I have an application that I build that communicates with a Modbus TCP device.  If a communication occurs error I wish I could reset it TCP communication.  What I have is a control that raises an event when pushed.  In this case, I have a sequence that closes first the tcp connection and then opens a new connection.  My application starts and works very well.  To test the reset function, I removed the ethernet cable from the camera and waited until a timeout occurs.  I plugged the cable reset back to and pushed my control. Sometimes the reset will take place, but most of the time I'll get a timeout in the TCP vi open error.  After that, the only way I can establish communications must leave my application, disable and then enable the network device.  Then, when I restart my application I have communication with my camera.

Any help would be appreciated on how I should be reset my TCP connection.

Thank you

Terry

Terry S of a. in writing:

I've attached an example vi (LV10) that shows just the connection TCP and Reset.  An error occurs when you try to run the open in the event of reset tcp protocol.

As writing that your code should be fine. There is nothing inherently wrong with it. However, depending on the device, you communicate with you can try to restore the connection too quickly once you have closed the connection. The device allows multiple connections to it and may require some time to clean up the things on his end after you close a connection. An experimental basis try wait little time between TCP and the TCP Open shut it down. If possible you can try using Wireshark to see what is happening on the network. It may be useful to diagnose what is happening.

Tags: NI Software

Similar Questions

  • I lost the internet connection after acceptance of your latest updates. How can I cancel the updates?

    I lost the internet connection after acceptance of your latest updates. How can I cancel the updates?

    Debbie

    How do you know that the loss of your internet connection has nothing to do with the Windows updates? You must find the reason for the loss of the connection.

    How do you connect? Is a wired or wireless with a modem or a router? If a router is the router shared with another computer and this computer can connect to the internet? You need to determine if the problem is a fault on your computer or a failure to connect to your internet access provider?

    What error messages are reported?

    Event Viewer reports

    1. normally, when an error occurs on your computer looking in Event Viewer should be your starting point to find a solution. More related system errors are recorded and get an exact copy of the relevant report is important. Unfortunately, is not easy to understand reports and most of the users computer need help with their interpretation. I have to say later interpretation.

    2 Event Viewer includes three main newspapers of Windows. Here's the Application, security, and system. For purposes of troubleshooting system is by far the most important.

    3. to access the system log, select Start, Control Panel, administrative tools, Event Viewer, in the list on the left of the window select Windows and the system logs. Place the cursor on the system, right click and select filter current log. Check the front of the error and click OK and see you only reports errors. Click the Date and time column header to sort. You may need to click a second time to see the last report above.

    4. a tip for posting copies of error reports! Run Event Viewer and double-click the error you want to copy. Select the Details tab and check the box in front of the XML view. Click the copy button to place a copy in the Clipboard and close Event Viewer. Now start your message and paste it into the body of the message. Make sure that it is the first dough right out of the event viewer.

    5. He cautioned against three types of reports, information, and reports errors. In most situations, it is the error reports that offer the best information but sometimes WARNING reports provide useful clues.

    6. all reports have stamps date and hour and when troubleshooting, it is important to focus on the latest reports. Reports of studies from the point when the computer is started, and then check if a similar report appeared in the previous session. If errors do not repeat investigation as to why they happen is wasted effort.

    7. in the individual reports the most important information is the event ID and Source such as these help when looking for help on the internet. The description is just as important and copy the exact text to use as search criteria greatly helps achieve better results when using Google. Not paraphrase descriptions when other people asking for help.

  • Problem of test Signal before using the TCP connection

    Right now my application uses a SocketConnection TCP to communicate with a remote server.  It works fine, but I'm trying to make sure that my program can correctly handle the situation to move to an area with no coverage.

    When I run my application, if I uncheck the box "on the cover" for GSM and CDMA under Network properties, my app fine until it calls the OutputStreamWriter.write () function to send something on the socket connection.  I have it in a try/catch block, but it just seems to hang instead of throwing an exception.

    How can I check the signal before attempting to send data on the SocketConnection?

    To facilitate clear life upwards, here's the order of what happens:

    1 application starts on the cover.

    2 SocketConnection made successfully.

    3 OutputStreamWriter successfully SocketConnection.

    4. coverage is lost

    5 OutputStreamWriter.write () is called, but freezes instead of throwing an exception.

    The socket connection output stream write operations do not throw an exception when there is no coverage is the correct behavior. That's because on cellular networks the IP tunnel to the carrier (and therefore the TCP connections on this tunnel) survives loss of coverage. For example, if your application opens a connection TCP from a BlackBerry, then the BlackBerry loses coverage, then take cover, say, 1 minute later, the TCP connection opened by your application will continue works fine, unless intermediate network component or your server closes the connection due to inactivity.

  • Lose the FTP connection after you put the computer to sleep

    I usually work in Dreamweaver on my Macbook. However, if I'm working on a Web site and decide to stop for a while (it's how I closed my Macbook), everytime I open my Macbook again, so lost FTP connection. Sometimes it comes back after a long period of time, and other times I can do return disconnection/reconnection airport several times. But most of the time, I just closed Dreamweaver and reopen it. If I do this, the connection works perfectly again.

    Does anyone know how to avoid to have to close and restart Dreamweaver in order to maintain the FTP connection after having put a Macbook to sleep?

    The FTP queue time is set by your web hosting provider.  I don't think DW has mechanisms in place to send empty commands to keep the connection alive, and even if it did, it would take the computer to be operational.  You shouldn't have to restart DW well in order to get a connection.  Simply by clicking on the login button in the files panel should do the trick.

  • Reset the fingerprint reader after you remove all the prints/pw does not

    Yes Im a fool, but is anyone know how to reset the reader of fingerprints for U200-115. I deleted my fingerprints after reviewing the password but now can't get to do something that the password does not work. I was informed that a BIOS password reset is the only way (i.e., a visit to the people service Tosh).

    Does anyone know a work around?

    Unfortunately there is no work around. The BIOS password can be removed by only authorized service provider. I really don't understand why the password still exists but ASP is your last chance.

    The closest contact with ASP and they will do it for you. If you need addresses and phone numbers please visit http://eu.computers.toshiba-europe.com > support & downloads > find an ASP.

    Good bye

  • interruption of the internet connection after installing vista sp2, only a local network

    Hello
    Since I installed vista sp2 last week, I have no internet connection. Just, my laptop connects to the local network. I had already tried to uninstall sp2, but this does not resolve the issue. A restore of the system has not been successful (do not know why, windows just said failure of system restore). I also deleted my antivirus program and my firewall...
    The internet works occasionally for a short time and when I start in safe mode.
    Because I live in a House that I have to use a fix ip, gateway and dns. After you install sp2, windows says my default gateway does not match my ip address and subnet mask when I change the properties of TCP/IPv4. Using another laptop with XP, the internet connection works with the same settings.
    I would be grateful for a quick solution, without formatting ;)

    I've highlighted the TCP/IPv6 line of course ;) the button was inactive when even
    in the registry, I saw WHAT TCP/IPv6 is already disabled

    my internet actually works, but I don't know why
    I deleted the file DisabledComponets for TCP/IPv6 in the registry, rebooted, create one, rebooted and it worked
    but I do not know why :)
    I hope that my internet is still functional

    Thank you for your support
    concerning

  • Satellite T130-11U, lost the Bluetooth connection after installing Mobile Broadb

    I recently bought a Satellite T130-11U and established a connection with my Nokia N82, using PC Suite.
    Then I installed my broadband Mobile (operator TMN) and lost the Bluetooth connection.

    There must be a way to overcome this 'conflict '.
    Anyone with the same problem?

    Thank you.

    Hello

    Perhaps this 3rd party application is not compatible and that is the reason why this happens
    But first, you should check if the Bluetooth is always enabled

    In addition, you should check if this issue happen after installation of the new BT stack

    Here you will find the new BT stack:
    http://APS2.toshiba-tro.de/Bluetooth/

    Welcome them

  • Satellite L650 - lost the WLAN connection after upgrade to Win8

    I downloaded windows 8 on laptop Toshiba Satellite L650 of my partner and now the wireless connection does not work.
    Get Wi - Fi devices but the Toshiba is not now after the upgrade.

    I read somewhere that it may need new drivers or something like that, but I'm not tech savvy and don't know where to start.

    Can anyone help? I use another laptop for this post because there is no connection on the Toshiba.

    Thank you

    In a first time can you please post exact model laptop (L650-xxx) number?
    I want to check what WLAN card is inside.

    Open the Device Manager and check the status of the WLAN card. Please post comments on this basic information.

  • Read bit in the TCP connection

    Hello

    I'm trying to read data from TCP connection.

    As I understand it, I get a string as this login data.

    I need to play different songs in these data

    What will be the best way to do it?

    Thank you

    In this case, you will get a string of one character in the TCP/IP Read function. You said you want to see if, for example, the character ".<". the="" ascii="" code="" for=""><" is="" hex="" 3c,="" which="" corresponds="" to="" 00111100.="" thus,="" it="" sounds="" like="" you="" just="" need="" to="" make="" a="" comparison="" against="" a="" character.="" if="" you="" want="" to="" check="" a="" specific="" bit="" pattern="" then="" the="" easiest="" way="" to="" do="" this="" is="" to="" simply="" convert="" the="" string="" character="" to="" a="" u8="" and="" compare="" to="" a="" u8="" constant,="" like="">

  • Vista 32 bit loses the internet connection after about 10-15 minutes.

    I lose my internet connection after 10-15 minutes.

    The message says local access only.

    The only way to reconnect is to restart the computer.

    I use a devolo home plug network system. It is connected to a 210 of BT router travel.

    I also have a new computer recently bought and installed Windows 7. There is no problem with that.

    Maybe it's a coincidence, but the problem started only since the installation of the new model.


    Hello Cody C.

    Thanks for your reply. I tried this. It is said that the drivers are up to date.

    I go into the settings of power network and checked the box "turn off network card to save energy.

    Since that seems to be OK. Only time will tell if.

    Thanks a lot for all the replies. EXTED

  • I can't view the network connection after downgrade from Windows Vista business to Windows XP Professional.

    How can I view network connections after downgrade from Windows Vista business to Windows XP Professional. I have problems to install the drivers of my HP dc7800.

    Click Start > my network places > view network connections in the left pane.

    XP forums:

    http://social.answers.Microsoft.com/forums/en-us/category/WindowsXP

    Link above is for XP Forums.

    There is a list of the different Forums XP to the link above to help you.

    You get the help you need there.

    Here is the Vista Forums.

    See you soon

    Mick Murphy - Microsoft partner

  • How can I get Word 2007 to reset the default printer after each draw?

    I'm not the most tech savvy person in the world, but I know my way around MS Office well enough; When my boss got a new computer last month, I helped to set up, install the MS Office, etc.  Now, she complains constantly that he does not restore the default printer after each draw and "my old computer used to do that for me - I never know where it'll print now."

    How can I configure sound MS Word to print from the default printer each time unless otherwise selected?

    I have the default printer specified in Windows, but each time she chooses an active printer, MS Word uses the current printer instead of the default printer.  I just need to know how to solve this problem?

    If you open a doc Office that it allows to print to the printer origonal used when saving this doc.

    If you use the Btn Office Orb, you can select the printer

  • EA6500 loses the WIFI connection after inactivity, how to fix this?

    Hi guys, Ive had this problem with some routers now and I was hoping that this new EA6500 would fix it but no. Every time that I do not use wifi during the night, the day depending on whether it does not work, I need to restart the router for WIFI to work again. Wired connections still works and does not descend. Someone knows how can I fix?

    Try to change the local IP address of the EA6500 192.168.2.1.

    It is possible that a conflict NAT is fouling things up. Through feeding cycle usually is a big red flag for a NAT conflict.

    The EA6500 is designed to avoid conflicts NAT for the devices connected to the wan port, but I do not think that it will avoid conflicts with the LAN port.

  • Reset the default printer after each print job.

    I wish that my printer to reassign the default printer after each print job.  I have a Hp LaserJet 1020 on my desk as my default.  Sometimes however, I print on our printer color etc.  Then when I go to print again immediately after the color printing - it is (and not my default).  I looked in the printer properties, devices, etc. - but do not see where I could update this?  Can you let me know.  Thank you.

    You don't say how you make that decision to change printers. I have two printers, all-in-one (default) HP4135 and HP6122 duplexer.

    Example: Leave in MS Office Word 2007 default print would always be. But I can choose a printer to use. With this selection, as long as I stay within this project, the HP6122 could be used. It would default to the HP4135 if I closed the project.

    If you go: start, Control Panel, printers, you will see all printers. The default value has a green check mark. Right-click on the printer icon and a menu descends with an extra function "Set as default printer".

  • Reset the user database after the removal of field

    Hello

    We use ES2.5 and we discovered this strange Act of user database. We have a Web service that gets the data user of LiveCycle. He former users are displayed that was stored in the old domain I already deleted the directory of the user.

    So... is there a way to reset the user database?

    Floh Cu

    I just idea... I've recreated the field again with the same ID/name but without the directories and resynced the field. Now, all the old users are marked obsolete.

Maybe you are looking for

  • Installation of linux on Qosmio G20

    Has anyone managed to do this? If for what flavor linux has been used or that drivers were used for hard drives?

  • Satellite A110-195 does not recognize my camera JVC

    I just bought this camera and tried to connect my JVC digital camera.In vain.I spent a few days looking for solution on many forums (of course, I called in the service of JVC and Toshiba also), so I've got a big mess in my head.Everything is OK on my

  • 0 x 645 a code when I try to download updates automatically.

    Since yesterday, I am not able to download the updates (automatically).  Six updates are available and none of her could be downloaded.  The error number by one of the updates is: 0 x 645.  In addition, I'm unable to email Microsoft.  Reach the corre

  • Thinkpad IBM T41p gel

    My T41p crashes after a few minutes. I decided to shut it down and when I run upward it lights but will not show all the lights and custom begin to run until I have power on/off or unplug and turn the computer back on. The weird part is that when I r

  • Error code 66A, 800706BE and 800706BA when installing updates.

    What should I do? All updates are important, and some have been waiting for a long time now that I have not had time to find solutions (and I'm still you wonder why should it be me who find solutions to AUTOMATIC updates...) Please advice clearly, I'