I am using the .net SerialPort component for handling a 9 bit transfer (NRI S1).
The MSB=1 means at the sending side the address/command byte, the following bytes are MSB=0 datas.
I handle it with the Parity=mark and space. It works...
At the receiving side I handle the DataReceived and ErrorReceived events (ParatyReplace = 0). It also works, I can get all the characters.
The MSB=1 designates the last data byte, otherwise it is 0.
How can I locate it?
I have not found anything about the Parity error state if it is mark or space. I guess, it generates error if I set space and received mark or set to mark and received space. Is it true?
I tried it, I got parity error, but I cannot locate its position. I read, that if it is the last byte of the buffer, the component appends a byte to the buffer with value of 126. But if there is not exists this byte at the end, where is the parity error position?
Please, help me!
Thanks for advance...