Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. Serial port behaviour in XP and windows 2000

Serial port behaviour in XP and windows 2000

Scheduled Pinned Locked Moved C / C++ / MFC
question
4 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    sunny_vc
    wrote on last edited by
    #1

    Hi all, I am working on serial port application on VC6 using non overlapped IO. I used the following time out values. ReadIntervalTimeout = 1; ReadTotalTimeoutMultiplier =1; ReadTotalTimeoutConstant =2; In XP operating system for these settings my application is working fine. But when I use these settings in windows 2000, the application does not send and receive properly. In 2000, if I change the settings to ReadIntervalTimeout = 0xffffffff; ReadTotalTimeoutMultiplier =0; ReadTotalTimeoutConstant =0; it works properly.But If I use these values, my application receiving thread shows CPU usage much high. Are the settings for read interval are correct? Please clarify..

    Regards, Sunil Kumar

    CPalliniC M 2 Replies Last reply
    0
    • S sunny_vc

      Hi all, I am working on serial port application on VC6 using non overlapped IO. I used the following time out values. ReadIntervalTimeout = 1; ReadTotalTimeoutMultiplier =1; ReadTotalTimeoutConstant =2; In XP operating system for these settings my application is working fine. But when I use these settings in windows 2000, the application does not send and receive properly. In 2000, if I change the settings to ReadIntervalTimeout = 0xffffffff; ReadTotalTimeoutMultiplier =0; ReadTotalTimeoutConstant =0; it works properly.But If I use these values, my application receiving thread shows CPU usage much high. Are the settings for read interval are correct? Please clarify..

      Regards, Sunil Kumar

      CPalliniC Offline
      CPalliniC Offline
      CPallini
      wrote on last edited by
      #2

      sunny_vc wrote:

      ReadIntervalTimeout = 1; ReadTotalTimeoutMultiplier =1; ReadTotalTimeoutConstant =2;

      Why such low values? What is your communication speed?

      If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
      This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong. -- Iain Clarke
      [My articles]

      In testa che avete, signor di Ceprano?

      S 1 Reply Last reply
      0
      • CPalliniC CPallini

        sunny_vc wrote:

        ReadIntervalTimeout = 1; ReadTotalTimeoutMultiplier =1; ReadTotalTimeoutConstant =2;

        Why such low values? What is your communication speed?

        If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
        This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong. -- Iain Clarke
        [My articles]

        S Offline
        S Offline
        sunny_vc
        wrote on last edited by
        #3

        My application is communicating at 115200 baud rate speed with an embedded device.

        Regards, Sunil Kumar

        1 Reply Last reply
        0
        • S sunny_vc

          Hi all, I am working on serial port application on VC6 using non overlapped IO. I used the following time out values. ReadIntervalTimeout = 1; ReadTotalTimeoutMultiplier =1; ReadTotalTimeoutConstant =2; In XP operating system for these settings my application is working fine. But when I use these settings in windows 2000, the application does not send and receive properly. In 2000, if I change the settings to ReadIntervalTimeout = 0xffffffff; ReadTotalTimeoutMultiplier =0; ReadTotalTimeoutConstant =0; it works properly.But If I use these values, my application receiving thread shows CPU usage much high. Are the settings for read interval are correct? Please clarify..

          Regards, Sunil Kumar

          M Offline
          M Offline
          Marcelo Miacca
          wrote on last edited by
          #4

          Is the problem that you receive part of the total string from the external equipement? Is the comunication an answer and a response, or full duplex?

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups