* LSEEK_CIRC_TORP | set file pointer to global (shared) read pointer
* LSEEK_CIRC_TOWP | set file pointer to FPGA write pointer (next frame to be acquired)
* LSEEK_CIRC_PREV | move pointer to the previous frame, return @e -EOVERFLOW if there are none
* LSEEK_CIRC_NEXT | advance pointer to the next frame, return @e -EOVERFLOW if it was at the last frame
* LSEEK_CIRC_LAST | move pointer to the last acquired frame (default after open), this is a combination of LSEEK_CIRC_TOWP and LSEEK_CIRC_PREV
* LSEEK_CIRC_FIRST | move pointer to the first acquired frame. It s not safe to rely on this pointer if more frames are expected - next incoming frame can overwrite this one
* LSEEK_CIRC_SCND | move pointer to the second oldest acquired frame. A slightly safer to use instead of LSEEK_CIRC_FIRST when constant acquisition is on and sensor provides new frames - this frame will likely survive longer
* LSEEK_CIRC_SETP | save current pointer to global read pointer
* LSEEK_CIRC_VALID | verify that the frame at current location is valid (not overrun in the buffer). Returns file pointer if it is valid and -1 otherwise
* LSEEK_CIRC_READY | verify frame at current location is available (valid and acquired). Returns file pointer if it is ready or -1 otherwise
* LSEEK_CIRC_WAIT | sleep until next frame is acquired
* All commands but (LSEEK_CIRC_TOWP, LSEEK_CIRC_LAST, LSEEK_CIRC_FIRST) will return -EINVAL if read
* pointer is not valid (i.e buffer was overrun and data pointed is lost). In case of success, they return
* current (byte *) to the start of the frame data (parameters are at offset - 32 from it).
* (0, SEEK_CUR) also verifies that the header is not overwritten. It can be used after buffering frame data to
* verify you got it all correctly.
*
* SEEK_CUR also supports the circular nature of the buffer and rolls over if needed.
*
* Additional commands for SEEK_END (they _DO_ modify the current file pointer):
* LSEEK_CIRC_FREE | returns remaining memory in circbuf from the current file pointer, or -EINVAL if the pointer is invalid. As this command uses the buffer write pointer that is updated only when the complete frame is in the buffer, the actual free memory may be less by a whole frame if compressor is running
* LSEEK_CIRC_USED | returns memory used in the in circbuf from the current file pointer, or -EINVAL if the pointer is invalid
* The following command is used for profiling from user space applications. It does not change file pointer:
* LSEEK_CIRC_UTIME return current value of microsecond counter.
* @param[in] file pointer to @e file structure
* @param[in] offset offset inside buffer in bytes
* @param[in] orig where the @e offset should start
* @return Current file pointer position if operation was successful and error code otherwise