Serial Communication in Visual C++



Hello,
I am communicating with a programmable power supply using an RS-232
interface through Visual Studio and having a slight problem. The power
supply documentation supplied very little information about communicating
this way except for the following:

Baud Rate: 1200, 2400, 4800, or 9600
Parity Bit: none
Data Bit: 8 bits
Stop Bit: 1 stop bit
Data flow control: none

I have set up a DCB (Platform SDK) structure in code and am able to actually
communicate with the power supply and it carries out the action I ask it to,
but it is painfully slow (on the order of 2-3 seconds per command). The
following is what I have set up in code (as far as serial parameters are
concerned):

DCB Parms;
Parms.BaudRate = CBR_9600;
Parms.ByteSize = 8;
Parms.Parity = NOPARITY;
Parms.StopBits = ONESTOPBIT;

and again, this works, but it is running way too slow for the current
purposes. I have carried out the same actions through MATLAB's serial
interface and also just through HyperTerminal (Start
Menu-->Accessories-->Communications) and the power supply responds
instantaneously to inputs through those interfaces.

Can anybody provide any guidance as to what I can do to achieve
instantaneous responses through Visual Studio? Thanks in advance.

-Ryan



.



Relevant Pages

  • Re: Serial Communication with Visual C++
    ... I am communicating with a programmable power supply using an RS-232 ... interface through Visual Studio and having a slight problem. ... instantaneous responses through Visual Studio? ...
    (microsoft.public.win32.programmer.tools)
  • Serial Communication with Visual C++
    ... I am communicating with a programmable power supply using an RS-232 ... interface through Visual Studio and having a slight problem. ... instantaneous responses through Visual Studio? ...
    (microsoft.public.win32.programmer.tools)
  • Re: Serial Communication in Visual C++
    ... I am communicating with a programmable power supply using an RS-232 ... interface through Visual Studio and having a slight problem. ... Please post a minimal program ...
    (microsoft.public.vc.language)
  • Subject: [PATCH] Linux JOB for 2.6.10
    ... new interface for communicating with user space. ... A new small virtual filesystem called jobfs is implemented to replace the ...
    (Linux-Kernel)
  • Cached definitions in VC++
    ... Visual Studio 2003.net is showing function that are of obsolete code ... interface and made changes to the parameter list of one method. ... showing tips (or balloon help) for the function definitions in my program. ...
    (microsoft.public.win32.programmer.directx.video)

Loading