Strange problem

In a PC with windows 7 happens to characters sent or received can not be read. Eg I expect to receive a string instead I receive non-ascii characters, as if it were different baud rate or a value was added to the character. This happens also if i wrte a string on serial terminal. If I open the same COM before activating my program with another application type TeraTerm, after my application receives the correct characters (but not always). This happens on more than one PC (vista & seven 64 bit). I'm using latest version of Async32 1.5 on C++ 2009.

 
Any suggestion?
thanks!
 
Mirco
 

We're not aware of such issue and it's unclear (other than mismatch in COM port settings) what might be causing this. Did you try with the debug test app that is provided if you can make a proper PC to PC connection first?

If I run the terminal emulator demo before my application the port work fine. If my application open the port before, the port do not work.

this is the result of latest test on a USB-COM triyng to remove and reinsert the com.

I have no idea what is causing this. The information seems contradictory to me. In Windows, a serial port can only be opened once. If one application opened the port, the Windows call to open the serial port one more time should block, ie. other apps can not longer open the port. Perhaps you're not doing a correct initialization in your app? Are you sure you setup ALL your COM port parameters correct?

Of course I open and close the port before starting my application, the port is used by one application at a time.

Ok I found the problem.... UpdateDCB is set to false
sorry
thanks