I currently have a device connected to my serial port. If I reboot
the device after I reboot my XP system, then things work fine. My
program talks to the device and they pass information back and forth
with no problems.
The problem is when I restart my XP system with the device connected
to the serial port - I do not reboot the connecting device. When I
run my program, the last error after CreateFile is ACCESS_DENIED. I
have also tried to connect with Hyperterminal after a reboot of the
system and it says the port is busy. If I reboot the serial device,
then things behave fine again. I know the simple solution is to
reboot the connecting device but that is not a possibility in my
application. Has anyone ever run into something similar?
I am calling CreateFile as
serialHandle = CreateFile(port,
GENERIC_READ | GENERIC_WRITE,
0,
NULL,
OPEN_EXISTING,
FILE_FLAG_OVERLAPPED,
NULL);
I have also tried to view the security information with
GetNamedSecurityInfo before I call CreateFile to see what the port is
doing, but this also returns invalid.
Thanks.
Regina Joiner