Hello,
The parity bit of a serial frame is usually used as a rudimentary error checking bit. In general, you have the ability to set it to Mark, Space, Odd, or Even, where the setting defines either sending the bit high, low, or computing and sending it high or low in order to make the serial frame contain either an odd or even number of high bits. A parity error means one of two things:
1. You have the parity configured to different settings (Mark, Space, Odd, or Even) on the two sides of your communication, and you simply receive the frame with unexpected parity. NOTE that this can go undetected for some frames because the parity bit will either be set high or low, where this is done deterministically with Mark and Space settings, and contingent upon the data sent with Odd or Even settings. For example, suppose that the sending side uses Mark parity (parity bit = 1) and the receiving side uses Odd parity. Then, for half of the possible data frames sent, the Odd parity will compute the parity bit to be high, while for the other half of the possible data frames it will be computed to be low. Thus, the parity error will be seen half the time! You may be seeing a case like this, which of course can happen anytime one side is using Mark or Space and the other is using Odd or Even. In general, you want both sides to use the same parity setting and you should simply check that the parity used on your CPU side matches that of your instrument.
2. You are indeed seeing the evidence of corrupted data, where the parity bit is being flipped during transmission; if the error only occurs (and does so deterministically) on a specific transmission, you are likely not seeing this case.
Check this setting on both sides to make sure they match (you may be able to change it on the instrument side as well; matching this is what matters), and repost if you continue to have trouble!
Thank you,
Best Regards,
JLS