COM1 Port Settings

M

Mark Griffiths

Hi all,
Wondered if anyone could throw any light on this problem I have.

I have a customer who uses an old DOS based program to read in data from two
way radios in order to program them.
They attach the equipment to COM1 and on Win98 machines, when they run the
program it re-boots into DOS mode and they can read in the information in
seconds.

I tried to put in a newer PC with Win2000 SP4 on the machine because it runs
the program without the need to reboot - hence it should have been quicker
for them - i.e. not having to wait for the machines to re-boot every time
they go in and out of the program (and these aren't state of the art PC's -
about 3/4 years old).

However - and here's the problem - now the program takes about 5 minutes to
read in the code - instead of 10 seconds.

I've tried looking at the COM port settings in device manager and it's set
at 9600, N , 8 ,1 XON/XOFF, yet after a reboot and going straight into CMD
the port settings are 1200, E, 7,1.??

I've tried running the program from a batch file and setting the mode com1:
9600,N,8,1,P yet this still doesn't work.

Does any one know what might be going on here and how I can fix this
problem.

All/Any Help VERY MUCH appreciated.
Thanks In Advance
Mark
 
W

Wolf Kirchmeir

Mark Griffiths wrote:

[snip Tale Of Woe about running a DOS app on Win2k]
Does any one know what might be going on here and how I can fix this
problem.

All/Any Help VERY MUCH appreciated.
Thanks In Advance
Mark

What's going on is that W2K is not DOS. W2K is not based on DOS like
Win98/ME (which are basically DOS with a pretty face.) W2K is an
NT-based OS, a profoundly different architecture than DOS.

In order to run a DOS program, W2K runs a DOS emulator, but the emulator
cannot do everything DOS can do. One thing DOS can do is address
hardware directly; the emulator must translate every DOS harwdare access
to a W2K hardware access and vice versa. This is inherently slower than
DOS's hardware access (which is very fast, actually, and can make DOS
run faster on a slow machine than W2K can run on a fast machine.) If
your friend's DOS app retrieves and sends the data bit- or byte-wise,
then there could well be thousands of hardware calls every time you run
that radio-programming app. Also, W2K is a slow OS - only the fact that
hardware has speeded up faster than the NT family of OS's has slowed
down has hidden this fact from most people. No wonder the app runs so
slowly on the W2K system. In fact, I'm somewhat surprised it runs at all
- many DOS programs simply won't run on W2K. (In fairness, XP is
speedier - that seems to be its main difference from W2K. But it's just
as incapable of running DOS programs).

OK, if you've read this far, you have some idea of what's going on. Can
you fix it? Sadly, I doubt it, short of rewriting the app. to run as a
W2K program.

Anyhow, it looks like even though it's a hassle to reboot the W98
machine, it' still faster than the W2K one.

Sorry to be the bearer of bad news. I'll be as happy as you if my
opinion is proven wrong.
 
R

Rick

Wolf Kirchmeir said:
- many DOS programs simply won't run on W2K. (In fairness, XP is
speedier - that seems to be its main difference from W2K. But it's just
as incapable of running DOS programs).

Through a few slight-of-hand tricks XP does load faster than
Win2K, but it's still the same core OS. Apps do NOT run
faster on XP. Or if they do, I've never seen any benchmarks
that demonstrate this.

Rick
 
W

Wolf Kirchmeir

Rick said:
Through a few slight-of-hand tricks XP does load faster than
Win2K, but it's still the same core OS. Apps do NOT run
faster on XP. Or if they do, I've never seen any benchmarks
that demonstrate this.

Rick

Noted with thanks.
 
M

Mark Griffiths

Thanks for the advice guys,

Unfortunately the program they use is specifically for these old radios -
there is no alternative, even from the manufacturer.

Harsh reality is, that I'll have to put them back on W98 then - Pants!

Thanks again everyone and Regards
Mark
 
G

Gert B. Frob

If Win 2000 is desirable in other respects (would be for me), you could set
up a DOS partition followed by Win 2000 and dual boot. Same effect as you
have now with Win 98.
 
T

Thomas Lutz

You should be able to run your DOS serial I/O program under Windows
without any problems however you may need to create a PIF file and
modify the DOS session settings so that your DOS program runs
correctly.

For creating the PIF file, the following article on the Microsoft web
site should be of help.

http://www.microsoft.com/resources/...all/proddocs/en-us/windows_dos_configure.mspx

After you create the PIF file, I would recommend setting the following
settings:

Right click on the PIF file that you create in the Windows Explorer
and select "Properties" from the context menu.
When the Properties dialog box appears, select the "Program" tab and
click the "Advanced" button.
In the dialog that appears, select the option "Compatible timer
hardware emulation" and click OK.
Select the "Misc" tab and set the "Idle Sensitivity" to the lowest
setting and clear the "Always Suspend" option in the "Background"
section.
If the above settings do not clear up the problem, select the
"Compatibility" tab and set the Compatibility Mode to the Windows 98
option.

After you make the above changes, your DOS serial communications
program shoudl run just fine.

For more serial I/O tips, tricks and free utility programs, please
visit www.taltech.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top