473,757 Members | 2,066 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Serial Comm Problem

I wrote a program that communicate with SerialComm. In every 300
milliseconds, my program continuously send & receive data via the serial
port once the program starts.

My program is once in a while, the serial port seems corrupted because when
my data is sent, it doesn't go through the serial port, so as same to
receive process. In order to fix this, I have to close the port and reopen
the port again.

Why?!! Is there any way to fix this problem or I have to check for
corruption port, then I reopen the serial port again?

Thanks!

Michael
Nov 17 '05 #1
7 2765
"Michael Chong" <mi*****@cyob.c om.my> wrote in message
news:uQ******** ******@TK2MSFTN GP14.phx.gbl...
I wrote a program that communicate with SerialComm. In every 300
milliseconds, my program continuously send & receive data via the serial
port once the program starts.
I am puzzled by the idea that your program can
receive data every 300 mS. To me, that would
be determined by the sender, at the other end of
the serial link. So I wonder what you really mean.
My program is once in a while, the serial port seems corrupted because when
my data is sent, it doesn't go through the serial port, so as same to
receive process. In order to fix this, I have to close the port and reopen
the port again.
I translate your report thusly: My code does not
act as I would like after a time, and since it acts as
I would like for a short time, I can get longer periods
of likable behavior by restarting the failing operation.
Rather than diagnose this as a problem with my code,
I would prefer to call it a corruption of something
outside of my code.
Why?!! Is there any way to fix this problem or I have to check for
corruption port, then I reopen the serial port again?
As someone who has used the Comm API in a few
different ways, some of them with high throughput
requirements, and seen millions of messages complete
without error going thru the serial port driven by such
code, I can assure you that there is probably a way
to make your code work and there is no such thing
as "corruption port" of the kind you suspect.

However, to have any chance of helping you find out
how to fix your code, more details on what you are
now doing would be necessary.
Thanks! You're welcome.
Michael

--
--Larry Brasfield
email: do************* **********@hotm ail.com
Above views may belong only to me.
Nov 17 '05 #2
I am not very good in C++ problem and this is my codes below. I do not know
whether I got handshaking involve in my code. Could you guys let me know?
HANDLE OpenComm(char *lpszPort, int nBaud, char *nParity, int nData, int
nStop)
{
HANDLE hCom;
LPDCB lpDcb;

char szCom[10];
memset(szCom, 0, sizeof(szCom));
strcpy(szCom, "\\.\\COM") ;
strcat(szCom, lpszPort);
strcat(szCom, ":");

lpDcb = new(DCB);

//create port handle
hCom =
CreateFile(szCo m,GENERIC_READ| GENERIC_WRITE,0 ,NULL,OPEN_EXIS TING,FILE_FLAG_ O
VERLAPPED,NULL) ;

//failed coz invalid handle provided
if (hCom == INVALID_HANDLE_ VALUE)
{
hCom = NULL;
}

//fail to get port state
if (!GetCommState( hCom,lpDcb))
{
hCom = NULL;
}

//set setting [COM1: baud=9600 parity=N data=8 stop=1]
char strTemp[50];
memset(strTemp, 0, sizeof(strTemp) );
sprintf(strTemp , "baud=%d parity=%s data=%d stop=%d", nBaud, nParity,
nData, nStop);

if (!BuildCommDCB( strTemp,lpDcb))
{
hCom = NULL;
}

if (!SetCommState( hCom,lpDcb))
{
hCom = NULL;
}

// set communication timeouts
// get default values
BOOL bPort;
COMMTIMEOUTS CommTimeouts;

bPort = GetCommTimeouts (hCom, &CommTimeout s);
// set new values
CommTimeouts.Re adIntervalTimeo ut = 15;
CommTimeouts.Re adTotalTimeoutC onstant = 250;
CommTimeouts.Re adTotalTimeoutM ultiplier = 1;
CommTimeouts.Wr iteTotalTimeout Constant = 250;
CommTimeouts.Wr iteTotalTimeout Multiplier = 1;
bPort = SetCommTimeouts (hCom, &CommTimeout s);

return hCom;
}
Michael.


"Larry Brasfield" <donotspam_> wrote in message
news:eY******** ******@TK2MSFTN GP15.phx.gbl...
"Michael Chong" <mi*****@cyob.c om.my> wrote in message
news:uQ******** ******@TK2MSFTN GP14.phx.gbl...
I wrote a program that communicate with SerialComm. In every 300
milliseconds, my program continuously send & receive data via the serial
port once the program starts.


I am puzzled by the idea that your program can
receive data every 300 mS. To me, that would
be determined by the sender, at the other end of
the serial link. So I wonder what you really mean.
My program is once in a while, the serial port seems corrupted because when my data is sent, it doesn't go through the serial port, so as same to
receive process. In order to fix this, I have to close the port and reopen the port again.


I translate your report thusly: My code does not
act as I would like after a time, and since it acts as
I would like for a short time, I can get longer periods
of likable behavior by restarting the failing operation.
Rather than diagnose this as a problem with my code,
I would prefer to call it a corruption of something
outside of my code.
Why?!! Is there any way to fix this problem or I have to check for
corruption port, then I reopen the serial port again?


As someone who has used the Comm API in a few
different ways, some of them with high throughput
requirements, and seen millions of messages complete
without error going thru the serial port driven by such
code, I can assure you that there is probably a way
to make your code work and there is no such thing
as "corruption port" of the kind you suspect.

However, to have any chance of helping you find out
how to fix your code, more details on what you are
now doing would be necessary.
Thanks!

You're welcome.
Michael

--
--Larry Brasfield
email: do************* **********@hotm ail.com
Above views may belong only to me.

Nov 17 '05 #3
[Top-posting undone for clarity.]
"Michael Chong" <mi*****@cyob.c om.my> wrote in message
news:%2******** ********@TK2MSF TNGP09.phx.gbl. ..
"Larry Brasfield" <donotspam_> wrote in message
news:eY******** ******@TK2MSFTN GP15.phx.gbl...
"Michael Chong" <mi*****@cyob.c om.my> wrote in message
news:uQ******** ******@TK2MSFTN GP14.phx.gbl...
>I wrote a program that communicate with SerialComm. In every 300
> milliseconds, my program continuously send & receive data via the serial
> port once the program starts.
I am puzzled by the idea that your program can
receive data every 300 mS. To me, that would
be determined by the sender, at the other end of
the serial link. So I wonder what you really mean.
It would still be useful to know what you are intending
to accomplish on the receive side, and what happens
every 300 mS.
> My program is once in a while, the serial port seems corrupted
> because when my data is sent, it doesn't go through the serial port,
> so as same to receive process. In order to fix this, I have to close
> the port and reopen the port again.

A more detailed set of observations would be useful.
What do you actually see? What did you expect?
However, to have any chance of helping you find out
how to fix your code, more details on what you are
now doing would be necessary.


That comment still applies. We see how you initialize
the comm port, but nothing reveals how you attempt
to send or receive data.
I am not very good in C++ problem and this is my codes below. I do not know
whether I got handshaking involve in my code. Could you guys let me know?
The BuildCommDCB() docs should tell you what the
default setting is. You've done nothing to override it.

A few minor code comments are inserted below.
HANDLE OpenComm(char *lpszPort, int nBaud, char *nParity, int nData, int
nStop)
{
HANDLE hCom;
LPDCB lpDcb;

char szCom[10];
memset(szCom, 0, sizeof(szCom));
strcpy(szCom, "\\.\\COM") ;
strcat(szCom, lpszPort);
strcat(szCom, ":");

lpDcb = new(DCB);
You may as well just define an auto DCB variable as
dynamically allocate such an object. I note that you
leak the one created above.
//create port handle
hCom =
CreateFile(szCo m,GENERIC_READ| GENERIC_WRITE,0 ,NULL,OPEN_EXIS TING,FILE_FLAG_ O
VERLAPPED,NULL) ;
Overlapped I/O is a great way to go when using the
comm API, but it is tricky to use. This is why it is
especially important to see what else you do with
the port, other than initialize it.
//failed coz invalid handle provided
if (hCom == INVALID_HANDLE_ VALUE)
{
hCom = NULL;
}
If the above fails, the other comm API calls should
not be made.
//fail to get port state
if (!GetCommState( hCom,lpDcb))
{
hCom = NULL;
}
If the above fails, it would be a good idea to
close the HANDLE, not just set it to 0.
//set setting [COM1: baud=9600 parity=N data=8 stop=1]
char strTemp[50];
memset(strTemp, 0, sizeof(strTemp) );
sprintf(strTemp , "baud=%d parity=%s data=%d stop=%d", nBaud, nParity, nData, nStop);

if (!BuildCommDCB( strTemp,lpDcb))
{
hCom = NULL;
Ditto.
}

if (!SetCommState( hCom,lpDcb))
{
hCom = NULL;

Ditto.
}

// set communication timeouts
// get default values
BOOL bPort;
COMMTIMEOUTS CommTimeouts;

bPort = GetCommTimeouts (hCom, &CommTimeout s);
I do not see why you want to get the timeouts when
you are setting them all anyway.
// set new values
CommTimeouts.Re adIntervalTimeo ut = 15;
CommTimeouts.Re adTotalTimeoutC onstant = 250;
CommTimeouts.Re adTotalTimeoutM ultiplier = 1;
CommTimeouts.Wr iteTotalTimeout Constant = 250;
CommTimeouts.Wr iteTotalTimeout Multiplier = 1;
bPort = SetCommTimeouts (hCom, &CommTimeout s);

return hCom;
}


So, what does your read code look like?

--
--Larry Brasfield
email: do************* **********@hotm ail.com
Above views may belong only to me.
Nov 17 '05 #4
Thanks Larry for helping, I do appreciated it. Below are my send and receive
comm port function. Basically this is a dll project that calls from vb.net.

int SendComm(HANDLE hCom, LPBYTE Buffer, unsigned int ByteCount)
{
DWORD dwWritten = 0;
OVERLAPPED OL={0};
OL.hEvent=Creat eEvent(NULL, TRUE, FALSE, NULL);

WriteFile(hCom, Buffer, ByteCount, &dwWritten, &OL);
CloseHandle(OL. hEvent);

PurgeComm(hCom, PURGE_TXABORT);

return GetLastError();
}
int ReceiveComm(HAN DLE hCom, LPBYTE Buffer, unsigned int ByteCount)
{
DWORD dwWritten = 0;
OVERLAPPED OL={0};
OL.hEvent=Creat eEvent(NULL, TRUE, FALSE, NULL);

ReadFile(hCom, Buffer, ByteCount, &dwWritten, &OL);
CloseHandle(OL. hEvent);

PurgeComm(hCom, PURGE_RXABORT);

return GetLastError();
}
Below are the sending and receiving process that vb.net program will call to
this dll above. This is a communication between PC and a hardware that made
by my engineer.
PC Send: 0x01
PC Recv: 0x01
PC Send: {0xBA|0x00|BCC| 0x00}
PC Recv: {0x00|0x03|0x34 |LSB|HSB|BCC|0x 00}

For example, I will keep on calling the above process every few seconds. But
after sometimes, I can't send command through the comm port (I don't know
why?). So I close the port and reopen it, it will return to normal again.
Why?!!

Thanks
Michael



"Larry Brasfield" <do************ ***********@hot mail.com> wrote in message
news:O2******** ******@TK2MSFTN GP09.phx.gbl...
[Top-posting undone for clarity.]
"Michael Chong" <mi*****@cyob.c om.my> wrote in message
news:%2******** ********@TK2MSF TNGP09.phx.gbl. ..
"Larry Brasfield" <donotspam_> wrote in message
news:eY******** ******@TK2MSFTN GP15.phx.gbl...
"Michael Chong" <mi*****@cyob.c om.my> wrote in message
news:uQ******** ******@TK2MSFTN GP14.phx.gbl...
>I wrote a program that communicate with SerialComm. In every 300
> milliseconds, my program continuously send & receive data via the serial > port once the program starts.

I am puzzled by the idea that your program can
receive data every 300 mS. To me, that would
be determined by the sender, at the other end of
the serial link. So I wonder what you really mean.
It would still be useful to know what you are intending
to accomplish on the receive side, and what happens
every 300 mS.
My program is once in a while, the serial port seems corrupted
> because when my data is sent, it doesn't go through the serial port,
> so as same to receive process. In order to fix this, I have to close
> the port and reopen the port again.
A more detailed set of observations would be useful.
What do you actually see? What did you expect?
However, to have any chance of helping you find out
how to fix your code, more details on what you are
now doing would be necessary.
That comment still applies. We see how you initialize
the comm port, but nothing reveals how you attempt
to send or receive data.
I am not very good in C++ problem and this is my codes below. I do not
know whether I got handshaking involve in my code. Could you guys let me know?
The BuildCommDCB() docs should tell you what the
default setting is. You've done nothing to override it.

A few minor code comments are inserted below.
HANDLE OpenComm(char *lpszPort, int nBaud, char *nParity, int nData, int
nStop)
{
HANDLE hCom;
LPDCB lpDcb;

char szCom[10];
memset(szCom, 0, sizeof(szCom));
strcpy(szCom, "\\.\\COM") ;
strcat(szCom, lpszPort);
strcat(szCom, ":");

lpDcb = new(DCB);


You may as well just define an auto DCB variable as
dynamically allocate such an object. I note that you
leak the one created above.
//create port handle
hCom =

CreateFile(szCo m,GENERIC_READ| GENERIC_WRITE,0 ,NULL,OPEN_EXIS TING,FILE_FLAG_ O VERLAPPED,NULL) ;


Overlapped I/O is a great way to go when using the
comm API, but it is tricky to use. This is why it is
especially important to see what else you do with
the port, other than initialize it.
//failed coz invalid handle provided
if (hCom == INVALID_HANDLE_ VALUE)
{
hCom = NULL;
}


If the above fails, the other comm API calls should
not be made.
//fail to get port state
if (!GetCommState( hCom,lpDcb))
{
hCom = NULL;
}


If the above fails, it would be a good idea to
close the HANDLE, not just set it to 0.
//set setting [COM1: baud=9600 parity=N data=8 stop=1]
char strTemp[50];
memset(strTemp, 0, sizeof(strTemp) );
sprintf(strTemp , "baud=%d parity=%s data=%d stop=%d", nBaud, nParity, nData, nStop);
if (!BuildCommDCB( strTemp,lpDcb))
{
hCom = NULL;


Ditto.
}

if (!SetCommState( hCom,lpDcb))
{
hCom = NULL;

Ditto.
}

// set communication timeouts
// get default values
BOOL bPort;
COMMTIMEOUTS CommTimeouts;

bPort = GetCommTimeouts (hCom, &CommTimeout s);


I do not see why you want to get the timeouts when
you are setting them all anyway.
// set new values
CommTimeouts.Re adIntervalTimeo ut = 15;
CommTimeouts.Re adTotalTimeoutC onstant = 250;
CommTimeouts.Re adTotalTimeoutM ultiplier = 1;
CommTimeouts.Wr iteTotalTimeout Constant = 250;
CommTimeouts.Wr iteTotalTimeout Multiplier = 1;
bPort = SetCommTimeouts (hCom, &CommTimeout s);

return hCom;
}


So, what does your read code look like?

--
--Larry Brasfield
email: do************* **********@hotm ail.com
Above views may belong only to me.

Nov 17 '05 #5
"Michael Chong" <mi*****@cyob.c om.my> wrote in message
news:%2******** ********@tk2msf tngp13.phx.gbl. ..
Thanks Larry for helping, I do appreciated it. Below are my send and receive
comm port function. Basically this is a dll project that calls from vb.net.

int SendComm(HANDLE hCom, LPBYTE Buffer, unsigned int ByteCount)
{
DWORD dwWritten = 0;
OVERLAPPED OL={0};
OL.hEvent=Creat eEvent(NULL, TRUE, FALSE, NULL);
What do you think this event is good for? I urge you
to look at the members of OVERLAPPED and the
docs describing overlapped I/O to see why an event
has a role in overlapped I/O.
WriteFile(hCom, Buffer, ByteCount, &dwWritten, &OL);
What do you suppose the API designers imagine the lifetime
of that OVERLAPPED object to be? Do you have a reason
to believe it will be as short as the lifetime of the one you
actually pass in here?
CloseHandle(OL. hEvent);

PurgeComm(hCom, PURGE_TXABORT);
Why is this call here?
return GetLastError();
}
int ReceiveComm(HAN DLE hCom, LPBYTE Buffer, unsigned int ByteCount)
{
DWORD dwWritten = 0;
OVERLAPPED OL={0};
OL.hEvent=Creat eEvent(NULL, TRUE, FALSE, NULL);

ReadFile(hCom, Buffer, ByteCount, &dwWritten, &OL);
CloseHandle(OL. hEvent);

PurgeComm(hCom, PURGE_RXABORT);

return GetLastError();
}
All the same comments apply to the above routine.
Below are the sending and receiving process that vb.net program will call to
this dll above. This is a communication between PC and a hardware that made
by my engineer.
PC Send: 0x01
PC Recv: 0x01
PC Send: {0xBA|0x00|BCC| 0x00}
PC Recv: {0x00|0x03|0x34 |LSB|HSB|BCC|0x 00}

For example, I will keep on calling the above process every few seconds. But
after sometimes, I can't send command through the comm port (I don't know
why?). So I close the port and reopen it, it will return to normal again.
Why?!!


When you open the port this way:
CreateFile(szCo m,GENERIC_READ| GENERIC_WRITE,0 ,NULL,
OPEN_EXISTING,F ILE_FLAG_OVERLA PPED,NULL);
then you are preparing to do your I/O using what is known as
"Overlapped I/O". This means that read and write operations do
not block. If they cannot complete immediately, the work is done
asynchronously relative to the thread that initiates the read or write,
and a notification of completion is signaled via the event in the that
OVERLAPPED object passed in upon read or write initiation.
This notification can happen awhile after the initiation call returns.

You need to rethink your decision to use overlapped I/O. Either
you do not need it, which is sort of suggested by how you have
coded your send and receive, or you need to use it the way it
was designed to be used. You may want to look at the MTTTY
sample to see some code that uses overlapped I/O.

--
--Larry Brasfield
email: do************* **********@hotm ail.com
Above views may belong only to me.
Nov 17 '05 #6
Do you have any website or sample that can refer me to serial port examples
in vc++.net

Thanks
Michael


"Larry Brasfield" <do************ ***********@hot mail.com> wrote in message
news:uk******** ******@TK2MSFTN GP15.phx.gbl...
"Michael Chong" <mi*****@cyob.c om.my> wrote in message
news:%2******** ********@tk2msf tngp13.phx.gbl. ..
Thanks Larry for helping, I do appreciated it. Below are my send and receive comm port function. Basically this is a dll project that calls from vb.net.
int SendComm(HANDLE hCom, LPBYTE Buffer, unsigned int ByteCount)
{
DWORD dwWritten = 0;
OVERLAPPED OL={0};
OL.hEvent=Creat eEvent(NULL, TRUE, FALSE, NULL);


What do you think this event is good for? I urge you
to look at the members of OVERLAPPED and the
docs describing overlapped I/O to see why an event
has a role in overlapped I/O.
WriteFile(hCom, Buffer, ByteCount, &dwWritten, &OL);


What do you suppose the API designers imagine the lifetime
of that OVERLAPPED object to be? Do you have a reason
to believe it will be as short as the lifetime of the one you
actually pass in here?
CloseHandle(OL. hEvent);

PurgeComm(hCom, PURGE_TXABORT);


Why is this call here?
return GetLastError();
}
int ReceiveComm(HAN DLE hCom, LPBYTE Buffer, unsigned int ByteCount)
{
DWORD dwWritten = 0;
OVERLAPPED OL={0};
OL.hEvent=Creat eEvent(NULL, TRUE, FALSE, NULL);

ReadFile(hCom, Buffer, ByteCount, &dwWritten, &OL);
CloseHandle(OL. hEvent);

PurgeComm(hCom, PURGE_RXABORT);

return GetLastError();
}


All the same comments apply to the above routine.
Below are the sending and receiving process that vb.net program will call to this dll above. This is a communication between PC and a hardware that made by my engineer.
PC Send: 0x01
PC Recv: 0x01
PC Send: {0xBA|0x00|BCC| 0x00}
PC Recv: {0x00|0x03|0x34 |LSB|HSB|BCC|0x 00}

For example, I will keep on calling the above process every few seconds. But after sometimes, I can't send command through the comm port (I don't know why?). So I close the port and reopen it, it will return to normal again. Why?!!


When you open the port this way:
CreateFile(szCo m,GENERIC_READ| GENERIC_WRITE,0 ,NULL,
OPEN_EXISTING,F ILE_FLAG_OVERLA PPED,NULL);
then you are preparing to do your I/O using what is known as
"Overlapped I/O". This means that read and write operations do
not block. If they cannot complete immediately, the work is done
asynchronously relative to the thread that initiates the read or write,
and a notification of completion is signaled via the event in the that
OVERLAPPED object passed in upon read or write initiation.
This notification can happen awhile after the initiation call returns.

You need to rethink your decision to use overlapped I/O. Either
you do not need it, which is sort of suggested by how you have
coded your send and receive, or you need to use it the way it
was designed to be used. You may want to look at the MTTTY
sample to see some code that uses overlapped I/O.

--
--Larry Brasfield
email: do************* **********@hotm ail.com
Above views may belong only to me.

Nov 17 '05 #7
"Michael Chong" <mi*****@cyob.c om.my> wrote in message
news:eq******** *****@tk2msftng p13.phx.gbl...
Do you have any website or sample that can refer me to serial
port examples in vc++.net


Start here:
http://www.microsoft.com/
Search for "MTTTY" using the site search utility.
Follow the link(s) in the result set. The sample
near the top of the article "Serial Communications
in Win32" especially deserves your attention.

[Brasfield previously wrote:]
You may want to look at the MTTTY sample to
see some code that uses overlapped I/O.

--
--Larry Brasfield
email: do************* **********@hotm ail.com
Above views may belong only to me.
Nov 17 '05 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
9094
by: ^CeFoS^ | last post by:
Hello to everybody, I've done an application that draws in a frame the trajectory of a robot. The robot position is readed through the serial port, and several commands are wrote through the same port to change the direction of the robot. The trajectory frame is managed by an applet, and the project works good when the applet is called by a html document allocated in the same local machine under W98 where the classes and the serial port...
2
4564
by: Mike C. | last post by:
I am trying to get Java v1.4.2 to use my PCI add-on serial port. So far, everything I try gives me javax.comm.NoSuchPortException at javax.comm.CommPortIdentifier.getPortIdentifier(CommPortIdentifier.java:105) at org.sf.javaemu.Serial.SerialCommunications.openConnection(UnknownSource) at javaemu.main.init(Unknown Source)
2
2302
by: bray_stenovations | last post by:
Hello, I am experiencing some strange problems while using a usb to serial adapter vs. a real comm port. The problems started with getting a blue screen at random times. Changing usb to serial drivers seemed to fix that problem. Now I am experiencing a problem where sometimes I am getting a crash while using the usb adapter but everything works perfectly while using a natural comm port. Has anyone else experienced this problem. ...
6
6983
by: Peter Krikelis | last post by:
Hi All, I am having a problem setting up input mode for serial communications. (Sorry about the long code post). The following code is what I use to set up my comm port.
0
7919
by: coolsilver.net | last post by:
I am not sure if I am in the right group. My problem is this: My VB.NET application prints to the Epson printer using Epson OPOS drivers. I have downloaded the Epson ADK for .NET from the EpsonExpert site (www.epsonexpert.com) I have also downloaded the Epson Advanced Printer Driver from the Epson site. I have installed Microsot POS for .NET on a windows 2000 machine. The installation completes but it throws an error "Error 5008....
12
2128
by: ken | last post by:
Hello everyone, I'm new to visual VB and I am trying to setup communications to the outside world. I found the example listed below in the help section of Microsoft Visual Basic 2005 Express Edition. Using the Hyper Terminal should I be able to see the string "Hello" or am I completely off base here? Thank you in advance for all and any help. Best regards, Ken Sub SendSerialData(ByVal data As String) ' Send strings to a serial port.
3
3687
by: ... | last post by:
Hi I need to send a chr(255) to a serial port. When I send it, through comm.write (chr(255)) it sends a chr(63) ... in Hex, I write chr(&FF) and it actually sends chr(&3F) ... why does this happen, and how can I send it right ? I'm using vb.net 2005 express with framework 2.0 Thanks for an answear ...
0
1316
by: alnsaisrinivas | last post by:
Hi I've a problem with I/O blocking on my serial port at this particular scenario... 1.I've developed a driver to communicate with some device using Serial Comm (overlapped I/O). 2.I'm able to send and receive messages perfectly. 3.As part of integration few more drivers also exist inorder to communicate with different devices. 4.I'm getting I/O blocking and application hangs up for my driver, when a particular driver is invoked before...
8
12316
by: glaskan | last post by:
This code is meant to take an input from the serial port and then save the input from the serial port as the name and as the data to a text file but all i am getting is an empty text file or a text file with only "," in it. It would be much appreciated if anyone could help with this problem. Thanks Private Sub Form_Unload(Cancel As Integer) MSComm1.PortOpen = False ' Close the comm port End Sub Private Sub Timer1_Timer() If...
0
9487
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10069
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9904
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9884
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8736
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7285
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6556
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5168
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
3
2697
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.