I wrote app based on MPI/DP communication in VB.NET. It's working, but I need high reliability. When I disconnect cable and connect again communication return, but not always. Sometimes I have error:
"The runtime has encountered a fatal error. The address of the error was at 0x6961a3da, on thread 0x18f4.
The error code is 0xc0000005. This error may be a bug in the CLR or in the unsafe or non-verifiable portions of user code.
Common sources of this bug include user marshaling errors for COM-interop or PInvoke, which may corrupt the stack."
"0x6961a3da" and "0x18f4" are usually different. It's always error "0xc0000005".
This error is showing in different moment. Sometime for 10 disconnect, and sometime for 100 disconnect.
I notice that I don't have this error when I read only one data block. For example:
RetVal = dc.readBytes(132, 205, 400, 210, ReceivedDataBytes)
But when I read two or more data block then error is appear (When I disconnect of course).
What can be the reason?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I wrote app based on MPI/DP communication in VB.NET. It's working, but I need high reliability. When I disconnect cable and connect again communication return, but not always. Sometimes I have error:
"The runtime has encountered a fatal error. The address of the error was at 0x6961a3da, on thread 0x18f4.
The error code is 0xc0000005. This error may be a bug in the CLR or in the unsafe or non-verifiable portions of user code.
Common sources of this bug include user marshaling errors for COM-interop or PInvoke, which may corrupt the stack."
"0x6961a3da" and "0x18f4" are usually different. It's always error "0xc0000005".
This error is showing in different moment. Sometime for 10 disconnect, and sometime for 100 disconnect.
I notice that I don't have this error when I read only one data block. For example:
RetVal = dc.readBytes(132, 205, 400, 210, ReceivedDataBytes)
But when I read two or more data block then error is appear (When I disconnect of course).
What can be the reason?