- receiving all packets until the moment as the flag PACKET_READY will have zero
value.
- the device buffer can contain a fragmentary acquisition packet (not the whole
PACKET_LEN), the amount of remaining frames should be read from the register
FRAME_CNT;
- if FRAME_CNT = 0 it means, that all frames was received and the reading was
correctly finished.
- if FRAME_CNT is not equal zero (i.e N) the setting PACKET_LEN should be changed to
exactly the amount of frames, that is remaining in the buffer of the device (N should be
written to the register PACKET_LEN). Only in this situation the change of PACKET_LEN
register to the smaller one do not reset the frame buffer in the device. After changing
the PACKET_LEN setting the device will allow to read N frames, changing the flag
PACKET_READY to '1';
- to confirm it, it is possible to check the flag PACKET_READY and if it is equal '1' it is
possible to read the new acquisition packet (N frames);
- after reading the packet with new length, the acquisition sequence was finished with
correct reading of all data. To prepare the next acquisition the PACKET_LEN should be
changed to the previous value or new one.