05-08-2023 02:13 AM
This seems like I obscured something in the calculation or that at reading at lower speed needs another parsing of the read values from USB.
Would it be acceptable to check for FF at the beginning and end, because I have the feeling from what you send that I now only see zeroes and 1 FF at the end.
Attached is a better version with a nicer stop condition and filling in a file name before starting.
05-08-2023 03:49 AM
OK.Let me test again.
Thank you for your help.
05-09-2023 04:22 AM
Hi.
I tested.The problem is solved.But I don't understand some parts.Could you please help me clarify it?
I don't understand how the program makes the decision here.Can you please help me understand the parts that I don't know?
I am grateful for Albert.Geven.
05-09-2023 04:43 AM
Hi
That small loop decides to store each 100 lines, or stop in case of an error.
That error occurs after you stop the main loop that destroys the queue and each run of the small loop the queue is questioned on how many lines are available. This generates an error when the queue is destroyed. Meaning that possibly the last 100 lines are not stored. But if you wait 0.1 sec before pressing stop you are OK.
This is a simple trick to avoid all those locals that are clumsy and were wrong.
05-10-2023 12:22 AM
OK
Thanks for answering.