Learn more about our scanners at: https://joescan.com
Page History
Excerpt |
---|
Frequently asked questions. |
How many profiles should I request in each call to jsSendMultipleProfileRequest() / BeginGetQueuedProfiles()?
In any of sync modes, the scan heads buffer acquired profiles until they're read out by the controlling computer. In high-speed scanning applications, the readout is typically done in a loop that calls the above functions repeatedly and processes the resulting profiles. Depending on the scanning applications load, that loop can potentially be slower than the acquisition speed, leading to profiles being accumulated in the scan head. The goal is to keep the amount of buffered profiles low, so that there is not a long time difference between when a profile was measured and the time it is processed. As a rule of thumb, a number between 1 and 20 is a good starting point. Keep in mind that if the readout loop is faster than the acquisition speed, requesting more profiles from the head than are buffered is perfectly fine - the head just will return an empty list.
The opposite situation is more difficult - if you read out profiles slower than they are measured, the buffer an fill up and eventually overflow, leading to dropped profiles and sequence errors. Reading larger numbers of profiles is also somewhat inefficient from a networking perspective.
As a simple check, you can compare the fields SendLocation and Location in the resulting profiles. The difference of these fields should remain constant over time. If (SendLocation-Location) grows steadily over time, that is a sign that your readout loop is not keeping up with the measurement process and eventually you will overflow the buffer. In this case you must speed up the readout loop (to get fewer profiles more frequently) or request more profiles at a time (to get more profiles less frequently).
In practice is has been shown that a well designed threading model on the readout loop is reliably able to keep up even at high scan speeds if the processing of profiles is offloaded from the readout loop itself. The developers kit documentation has examples of how to de-couple acquisition and processing.