sbgECom Library
5.2.590-stable
Interface SBG Systems IMU/AHRS/INS
|
Session information management. More...
#include <sbgCommon.h>
Go to the source code of this file.
Data Structures | |
struct | _SbgEComSessionInfoCtx |
Macros | |
#define | SBG_ECOM_SESSION_INFO_BUFFER_SIZE (32768) |
Typedefs | |
typedef struct _SbgEComSessionInfoCtx | SbgEComSessionInfoCtx |
Functions | |
void | sbgEComSessionInfoCtxConstruct (SbgEComSessionInfoCtx *pCtx) |
SbgErrorCode | sbgEComSessionInfoCtxProcess (SbgEComSessionInfoCtx *pCtx, uint16_t pageIndex, uint16_t nrPages, const void *pBuffer, size_t size) |
const char * | sbgEComSessionInfoCtxGetString (const SbgEComSessionInfoCtx *pCtx) |
Session information management.
Session information, including device information and current settings, may be sent regularly by a device. This module handles the reassembly of that information for the convenience of the user.
The MIT license
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#define SBG_ECOM_SESSION_INFO_BUFFER_SIZE (32768) |
Session information buffer size, in bytes.
typedef struct _SbgEComSessionInfoCtx SbgEComSessionInfoCtx |
Session information context.
String lengths do not include the null-terminating byte.
void sbgEComSessionInfoCtxConstruct | ( | SbgEComSessionInfoCtx * | pCtx | ) |
Session information context constructor.
On return, the session information string of the context is empty.
[in] | pCtx | Session information context. |
SbgErrorCode sbgEComSessionInfoCtxProcess | ( | SbgEComSessionInfoCtx * | pCtx, |
uint16_t | pageIndex, | ||
uint16_t | nrPages, | ||
const void * | pBuffer, | ||
size_t | size ) |
Process the content of a session information log.
If successful, the session information string remains valid until the next process operation.
[in] | pCtx | Session information context. |
[in] | pageIndex | Page index. |
[in] | nrPages | Total number of pages. |
[in] | pBuffer | Buffer. |
[in] | size | Buffer size, in bytes. |
const char * sbgEComSessionInfoCtxGetString | ( | const SbgEComSessionInfoCtx * | pCtx | ) |
Get the string of a session information context.
If valid, the session information string remains so until the next process operation.
[in] | pCtx | Session information context. |