Hello All,
I am having an issue with erratic reading and logging of COM port data.
The connection is as follows My computer -> USB cable -> FT232R board -> Device under test.
The device is set to output a message containing ADC values every 14 ms. A standard message looks like:
{"type": "log", "msg": "83948 -467237 -1891949 -3490623 1435677 1 0", "level": 20, "time_ms": 83948, "path": "REL_main.cc", "line": 82}
However, every once awhile I get a message that looks like
{"type": "log", "msg": "84746 -467120 -1892005 -3490712 1435640 1 020, "time_ms": 91508, "path": "REL_main.cc", "line": 82}
or even
{"type": "log", }
As you can see from the VI I have attached. I have tried to eliminate these "bad" messages by limiting the storing of the data to only messages that fit in the range of the expected byte count. The range is large because the message contains a timestamp that grows over time.
Can someone help me understand why this is happening? and please let me know what the fix is? my guess is that my computer doesn't produce a stable enough clock signal but of course I'm a rookie and I could be wrong. Please help. Thank you in advance