sbgECom Library  4.0.1987-stable
C library to interface SBG Systems IMU/AHRS/INS
sbgEComCmdOdo.h File Reference

Odometer / DMI aiding module configuration commands. More...

#include <sbgCommon.h>
#include <sbgECom.h>
#include "sbgEComCmdCommon.h"

Go to the source code of this file.

Data Structures

struct  _SbgEComOdoConf
 
struct  _SbgEComOdoRejectionConf
 
struct  _SbgEComCmdOdoCanConf
 

Macros

#define SBG_ECOM_CMD_ODO_CAN_ENABLE   (uint16_t)(0x0001 << 0)
 
#define SBG_ECOM_CMD_ODO_CAN_ID_EXTENDED   (uint16_t)(0x0001 << 1)
 
#define SBG_ECOM_CMD_ODO_CAN_BIG_ENDIAN   (uint16_t)(0x0001 << 2)
 
#define SBG_ECOM_CMD_ODO_CAN_SIGNED   (uint16_t)(0x0001 << 3)
 

Typedefs

typedef struct _SbgEComOdoConf SbgEComOdoConf
 
typedef struct _SbgEComOdoRejectionConf SbgEComOdoRejectionConf
 
typedef enum _SbgEComCmdOdoCanChannel SbgEComCmdOdoCanChannel
 
typedef struct _SbgEComCmdOdoCanConf SbgEComCmdOdoCanConf
 

Enumerations

enum  _SbgEComCmdOdoCanChannel {
  SBG_ECOM_CMD_ODO_CAN_CH_VELOCITY = 0 ,
  SBG_ECOM_CMD_ODO_CAN_CH_REVERSE = 1
}
 

Functions

SbgErrorCode sbgEComCmdOdoGetConf (SbgEComHandle *pHandle, SbgEComOdoConf *pOdometerConf)
 
SbgErrorCode sbgEComCmdOdoSetConf (SbgEComHandle *pHandle, const SbgEComOdoConf *pOdometerConf)
 
SbgErrorCode sbgEComCmdOdoGetLeverArm (SbgEComHandle *pHandle, float *pLeverArm)
 
SbgErrorCode sbgEComCmdOdoSetLeverArm (SbgEComHandle *pHandle, const float *pLeverArm)
 
SbgErrorCode sbgEComCmdOdoGetRejection (SbgEComHandle *pHandle, SbgEComOdoRejectionConf *pRejectConf)
 
SbgErrorCode sbgEComCmdOdoSetRejection (SbgEComHandle *pHandle, const SbgEComOdoRejectionConf *pRejectConf)
 
SbgErrorCode sbgEComCmdOdoCanGetConf (SbgEComHandle *pHandle, SbgEComCmdOdoCanChannel canChannel, SbgEComCmdOdoCanConf *pOdoCanConf)
 
SbgErrorCode sbgEComCmdOdoCanSetConf (SbgEComHandle *pHandle, SbgEComCmdOdoCanChannel canChannel, const SbgEComCmdOdoCanConf *pOdoCanConf)
 

Detailed Description

Odometer / DMI aiding module configuration commands.

Author
SBG Systems
Date
11 June 2014
License

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.

Macro Definition Documentation

◆ SBG_ECOM_CMD_ODO_CAN_ENABLE

#define SBG_ECOM_CMD_ODO_CAN_ENABLE   (uint16_t)(0x0001 << 0)

Set to enable CAN odometer information decoding.

◆ SBG_ECOM_CMD_ODO_CAN_ID_EXTENDED

#define SBG_ECOM_CMD_ODO_CAN_ID_EXTENDED   (uint16_t)(0x0001 << 1)

Set for a 29 bit extended CAN message, otherwise standard 11 bit

◆ SBG_ECOM_CMD_ODO_CAN_BIG_ENDIAN

#define SBG_ECOM_CMD_ODO_CAN_BIG_ENDIAN   (uint16_t)(0x0001 << 2)

Set if the velocity is encoded in big endian, otherwise little endian

◆ SBG_ECOM_CMD_ODO_CAN_SIGNED

#define SBG_ECOM_CMD_ODO_CAN_SIGNED   (uint16_t)(0x0001 << 3)

Set to interpret the parsed value as signed, otherwise unsigned.

Typedef Documentation

◆ SbgEComOdoConf

Holds all necessary information for Odometer module parameter configuration.

◆ SbgEComOdoRejectionConf

Holds all necessary information for Odometer module data rejection.

◆ SbgEComCmdOdoCanChannel

CAN odometer channels definition A channel is an information that can be decoded / used by the device.

◆ SbgEComCmdOdoCanConf

Holds all necessary information for CAN Odometer parameter configuration. This format is very similar to info contained in a DBC file.

Enumeration Type Documentation

◆ _SbgEComCmdOdoCanChannel

CAN odometer channels definition A channel is an information that can be decoded / used by the device.

Enumerator
SBG_ECOM_CMD_ODO_CAN_CH_VELOCITY 

Channel used to decode the vehicle velocity information

SBG_ECOM_CMD_ODO_CAN_CH_REVERSE 

Channel used to decode the vehicle velocity reverse info (if available).

Function Documentation

◆ sbgEComCmdOdoGetConf()

SbgErrorCode sbgEComCmdOdoGetConf ( SbgEComHandle pHandle,
SbgEComOdoConf pOdometerConf 
)

For quadrature and/or pulse based odometer, retrieve the configuration.

Parameters
[in]pHandleA valid sbgECom handle.
[out]pOdometerConfPointer to a SbgEComOdoConf struct to hold configuration of the odometer module.
Returns
SBG_NO_ERROR if the command has been executed successfully.

◆ sbgEComCmdOdoSetConf()

SbgErrorCode sbgEComCmdOdoSetConf ( SbgEComHandle pHandle,
const SbgEComOdoConf pOdometerConf 
)

For quadrature and/or pulse base odometer, define the configuration.

Parameters
[in]pHandleA valid sbgECom handle.
[in]pOdometerConfPointer to a SbgEComOdoConf struct holding configuration for the odometer module.
Returns
SBG_NO_ERROR if the command has been executed successfully.

◆ sbgEComCmdOdoGetLeverArm()

SbgErrorCode sbgEComCmdOdoGetLeverArm ( SbgEComHandle pHandle,
float *  pLeverArm 
)

Retrieve the lever arm applicable for both quadrature or CAN based odometer.

Parameters
[in]pHandleA valid sbgECom handle.
[out]pLeverArmArray of three values, one for each axis.
Returns
SBG_NO_ERROR if the command has been executed successfully.

◆ sbgEComCmdOdoSetLeverArm()

SbgErrorCode sbgEComCmdOdoSetLeverArm ( SbgEComHandle pHandle,
const float *  pLeverArm 
)

Set the lever arm applicable for both quadrature or CAN based odometer.

Parameters
[in]pHandleA valid sbgECom handle.
[in]pLeverArmArray of three values, one for each axis.
Returns
SBG_NO_ERROR if the command has been executed successfully.

◆ sbgEComCmdOdoGetRejection()

SbgErrorCode sbgEComCmdOdoGetRejection ( SbgEComHandle pHandle,
SbgEComOdoRejectionConf pRejectConf 
)

Retrieve the velocity rejection configuration for both quadrature or CAN based odometer.

Parameters
[in]pHandleA valid sbgECom handle.
[out]pRejectConfPointer to a SbgEComOdoRejectionConf struct to hold rejection configuration of the odometer module.
Returns
SBG_NO_ERROR if the command has been executed successfully.

◆ sbgEComCmdOdoSetRejection()

SbgErrorCode sbgEComCmdOdoSetRejection ( SbgEComHandle pHandle,
const SbgEComOdoRejectionConf pRejectConf 
)

Set the velocity rejection configuration for both quadrature or CAN based odometer.

Parameters
[in]pHandleA valid sbgECom handle.
[in]pRejectConfPointer to a SbgEComOdoRejectionConf struct holding rejection configuration for the odometer module.
Returns
SBG_NO_ERROR if the command has been executed successfully.

◆ sbgEComCmdOdoCanGetConf()

SbgErrorCode sbgEComCmdOdoCanGetConf ( SbgEComHandle pHandle,
SbgEComCmdOdoCanChannel  canChannel,
SbgEComCmdOdoCanConf pOdoCanConf 
)

Retrieve the CAN odometer configuration for a specific CAN information channel

Parameters
[in]pHandleA valid sbgECom handle.
[in]canChannelThe CAN channel to retrieve associated DBC configuration.
[out]pOdoCanConfStruct to hold configuration of the CAN odometer.
Returns
SBG_NO_ERROR if the command has been executed successfully.

◆ sbgEComCmdOdoCanSetConf()

SbgErrorCode sbgEComCmdOdoCanSetConf ( SbgEComHandle pHandle,
SbgEComCmdOdoCanChannel  canChannel,
const SbgEComCmdOdoCanConf pOdoCanConf 
)

Set the CAN odometer configuration for a specific CAN information channel

Parameters
[in]pHandleA valid sbgECom handle.
[in]canChannelThe CAN channel to define associated DBC configuration.
[in]pOdoCanConfStruct holding configuration for the CAN odometer.
Returns
SBG_NO_ERROR if the command has been executed successfully.