libRBR  v1.2.3
RBR instrument communication API
Data Structures | Macros | Typedefs | Enumerations | Functions
RBRInstrumentOther.h File Reference

Instrument commands and structures for miscellaneous commands. More...

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  RBRInstrumentHardwareRevision
 Instrument hwrev command parameters. More...
 
struct  RBRInstrumentPower
 Instrument power command parameters. More...
 
struct  RBRInstrumentPowerInternal
 Instrument powerinternal command parameters. More...
 
struct  RBRInstrumentPowerExternal
 Instrument powerexternal command parameters. More...
 
struct  RBRInstrumentInfo
 Instrument info command parameters. More...
 

Macros

#define RBRINSTRUMENT_HWREV_CPU_MAX   5
 The maximum number of characters in the type and revision of the CPU. More...
 
#define RBRINSTRUMENT_PART_NUMBER_MAX   255
 The maximum number of characters in an instrument part number. More...
 

Typedefs

typedef struct RBRInstrumentHardwareRevision RBRInstrumentHardwareRevision
 Instrument hwrev command parameters. More...
 
typedef enum RBRInstrumentPowerSource RBRInstrumentPowerSource
 
typedef struct RBRInstrumentPower RBRInstrumentPower
 Instrument power command parameters. More...
 
typedef enum RBRInstrumentInternalBatteryType RBRInstrumentInternalBatteryType
 
typedef struct RBRInstrumentPowerInternal RBRInstrumentPowerInternal
 Instrument powerinternal command parameters. More...
 
typedef enum RBRInstrumentExternalBatteryType RBRInstrumentExternalBatteryType
 
typedef struct RBRInstrumentPowerExternal RBRInstrumentPowerExternal
 Instrument powerexternal command parameters. More...
 
typedef struct RBRInstrumentInfo RBRInstrumentInfo
 Instrument info command parameters. More...
 

Enumerations

enum  RBRInstrumentPowerSource {
  RBRINSTRUMENT_POWER_SOURCE_USB, RBRINSTRUMENT_POWER_SOURCE_INTERNAL, RBRINSTRUMENT_POWER_SOURCE_EXTERNAL, RBRINSTRUMENT_POWER_SOURCE_COUNT,
  RBRINSTRUMENT_UNKNOWN_POWER_SOURCE
}
 
enum  RBRInstrumentInternalBatteryType {
  RBRINSTRUMENT_INTERNAL_BATTERY_NONE, RBRINSTRUMENT_INTERNAL_BATTERY_LISOCL2, RBRINSTRUMENT_INTERNAL_BATTERY_LIFES2, RBRINSTRUMENT_INTERNAL_BATTERY_ZNMNO2,
  RBRINSTRUMENT_INTERNAL_BATTERY_LINIMNCO, RBRINSTRUMENT_INTERNAL_BATTERY_NIMH, RBRINSTRUMENT_INTERNAL_BATTERY_COUNT, RBRINSTRUMENT_UNKNOWN_INTERNAL_BATTERY
}
 
enum  RBRInstrumentExternalBatteryType {
  RBRINSTRUMENT_EXTERNAL_BATTERY_OTHER, RBRINSTRUMENT_EXTERNAL_BATTERY_FERMATA_LISOCL2, RBRINSTRUMENT_EXTERNAL_BATTERY_FERMATA_ZNMNO2, RBRINSTRUMENT_EXTERNAL_BATTERY_FERMETTE_LIMNO2,
  RBRINSTRUMENT_EXTERNAL_BATTERY_FERMETTE3_LISOCL2, RBRINSTRUMENT_EXTERNAL_BATTERY_FERMETTE3_LIFES2, RBRINSTRUMENT_EXTERNAL_BATTERY_FERMETTE3_ZNMNO2, RBRINSTRUMENT_EXTERNAL_BATTERY_FERMETTE3_LINIMNCO,
  RBRINSTRUMENT_EXTERNAL_BATTERY_FERMETTE3_NIMH, RBRINSTRUMENT_EXTERNAL_BATTERY_COUNT, RBRINSTRUMENT_UNKNOWN_EXTERNAL_BATTERY
}
 

Functions

int RBRInstrumentVersion_compare (const char *a, const char *b)
 Compare two firmware version strings. More...
 
RBRInstrumentError RBRInstrument_getId (RBRInstrument *instrument, RBRInstrumentId *id)
 Get identification information from the instrument. More...
 
RBRInstrumentError RBRInstrument_getHardwareRevision (RBRInstrument *instrument, RBRInstrumentHardwareRevision *hwrev)
 Get instrument hardware revision information. More...
 
const char * RBRInstrumentPowerSource_name (RBRInstrumentPowerSource source)
 Get a human-readable string name for a power source. More...
 
RBRInstrumentError RBRInstrument_getPower (RBRInstrument *instrument, RBRInstrumentPower *power)
 Get instrument power information. More...
 
const char * RBRInstrumentInternalBatteryType_name (RBRInstrumentInternalBatteryType type)
 Get a human-readable string name for an internal battery type. More...
 
const char * RBRInstrumentInternalBatteryType_displayName (RBRInstrumentInternalBatteryType type)
 Get a human-readable display name for an internal battery type. More...
 
RBRInstrumentError RBRInstrument_getPowerInternal (RBRInstrument *instrument, RBRInstrumentPowerInternal *power)
 Get instrument internal power information. More...
 
RBRInstrumentError RBRInstrument_setInternalBatteryType (RBRInstrument *instrument, RBRInstrumentInternalBatteryType type)
 Set the internal power battery type. More...
 
RBRInstrumentError RBRInstrument_resetPowerInternalUsed (RBRInstrument *instrument)
 Reset the counter of energy used from the internal battery. More...
 
const char * RBRInstrumentExternalBatteryType_name (RBRInstrumentExternalBatteryType type)
 Get a human-readable string name for an external battery type. More...
 
const char * RBRInstrumentExternalBatteryType_displayName (RBRInstrumentExternalBatteryType type)
 Get a human-readable display name for an external battery type. More...
 
RBRInstrumentError RBRInstrument_getPowerExternal (RBRInstrument *instrument, RBRInstrumentPowerExternal *power)
 Get instrument external power information. More...
 
RBRInstrumentError RBRInstrument_setPowerExternalBatteryType (RBRInstrument *instrument, RBRInstrumentExternalBatteryType type)
 Set the external power battery type. More...
 
RBRInstrumentError RBRInstrument_resetPowerExternalUsed (RBRInstrument *instrument)
 Reset the counter of energy used from the external battery. More...
 
RBRInstrumentError RBRInstrument_getInfo (RBRInstrument *instrument, RBRInstrumentInfo *info)
 Get more information about the instrument. More...
 

Detailed Description

Instrument commands and structures for miscellaneous commands.

See also
https://docs.rbr-global.com/L3commandreference/commands/other-information

Macro Definition Documentation

◆ RBRINSTRUMENT_HWREV_CPU_MAX

#define RBRINSTRUMENT_HWREV_CPU_MAX   5

The maximum number of characters in the type and revision of the CPU.

Does not include any null terminator.

◆ RBRINSTRUMENT_PART_NUMBER_MAX

#define RBRINSTRUMENT_PART_NUMBER_MAX   255

The maximum number of characters in an instrument part number.

Does not include any null terminator.

Typedef Documentation

◆ RBRInstrumentExternalBatteryType

External battery types.

See also
RBRInstrumentPowerExternal

◆ RBRInstrumentHardwareRevision

◆ RBRInstrumentInfo

◆ RBRInstrumentInternalBatteryType

Internal battery types.

See also
RBRInstrumentPowerInternal

◆ RBRInstrumentPower

◆ RBRInstrumentPowerExternal

◆ RBRInstrumentPowerInternal

◆ RBRInstrumentPowerSource

brief Possible instrument power sources.

See also
RBRInstrumentPower

Enumeration Type Documentation

◆ RBRInstrumentExternalBatteryType

External battery types.

See also
RBRInstrumentPowerExternal
Enumerator
RBRINSTRUMENT_EXTERNAL_BATTERY_OTHER 

Other/unknown external battery type

RBRINSTRUMENT_EXTERNAL_BATTERY_FERMATA_LISOCL2 

RBRfermata Li-SOCl₂

RBRINSTRUMENT_EXTERNAL_BATTERY_FERMATA_ZNMNO2 

RBRfermata Zn-MnO₂

RBRINSTRUMENT_EXTERNAL_BATTERY_FERMETTE_LIMNO2 

RBRfermette Li-MnO₂

RBRINSTRUMENT_EXTERNAL_BATTERY_FERMETTE3_LISOCL2 

RBRfermette³ Li-SOCl₂

RBRINSTRUMENT_EXTERNAL_BATTERY_FERMETTE3_LIFES2 

RBRfermette³ Li-FeS₂

RBRINSTRUMENT_EXTERNAL_BATTERY_FERMETTE3_ZNMNO2 

RBRfermette³ Zn-MnO₂

RBRINSTRUMENT_EXTERNAL_BATTERY_FERMETTE3_LINIMNCO 

RBRfermette³ Li-NiMnCo

RBRINSTRUMENT_EXTERNAL_BATTERY_FERMETTE3_NIMH 

RBRfermette³ NiMH

RBRINSTRUMENT_EXTERNAL_BATTERY_COUNT 

The number of specific external battery types.

RBRINSTRUMENT_UNKNOWN_EXTERNAL_BATTERY 

An unknown or unrecognized external battery type.

◆ RBRInstrumentInternalBatteryType

Internal battery types.

See also
RBRInstrumentPowerInternal
Enumerator
RBRINSTRUMENT_INTERNAL_BATTERY_NONE 

No internal battery

RBRINSTRUMENT_INTERNAL_BATTERY_LISOCL2 

Li-SOCl₂

RBRINSTRUMENT_INTERNAL_BATTERY_LIFES2 

Li-FeS₂

RBRINSTRUMENT_INTERNAL_BATTERY_ZNMNO2 

Zn-MnO₂

RBRINSTRUMENT_INTERNAL_BATTERY_LINIMNCO 

Li-NiMnCo

RBRINSTRUMENT_INTERNAL_BATTERY_NIMH 

NiMH

RBRINSTRUMENT_INTERNAL_BATTERY_COUNT 

The number of specific internal battery types.

RBRINSTRUMENT_UNKNOWN_INTERNAL_BATTERY 

An unknown or unrecognized internal battery type.

◆ RBRInstrumentPowerSource

brief Possible instrument power sources.

See also
RBRInstrumentPower
Enumerator
RBRINSTRUMENT_POWER_SOURCE_USB 

USB power.

RBRINSTRUMENT_POWER_SOURCE_INTERNAL 

Internal (battery) power.

RBRINSTRUMENT_POWER_SOURCE_EXTERNAL 

External power.

RBRINSTRUMENT_POWER_SOURCE_COUNT 

The number of specific power sources.

RBRINSTRUMENT_UNKNOWN_POWER_SOURCE 

An unknown or unrecognized power source.

Function Documentation

◆ RBRInstrument_getHardwareRevision()

RBRInstrumentError RBRInstrument_getHardwareRevision ( RBRInstrument instrument,
RBRInstrumentHardwareRevision hwrev 
)

Get instrument hardware revision information.

Parameters
[in]instrumentthe instrument connection
[out]hwrevthe hardware revision information
Returns
RBRINSTRUMENT_SUCCESS when the information is successfully read
RBRINSTRUMENT_TIMEOUT when a timeout occurs
RBRINSTRUMENT_CALLBACK_ERROR returned by a callback
See also
https://docs.rbr-global.com/L3commandreference/commands/other-information/hwrev

◆ RBRInstrument_getId()

RBRInstrumentError RBRInstrument_getId ( RBRInstrument instrument,
RBRInstrumentId id 
)

Get identification information from the instrument.

Parameters
[in]instrumentthe instrument connection
[out]idthe instrument information
Returns
RBRINSTRUMENT_SUCCESS when the information is successfully read
RBRINSTRUMENT_TIMEOUT when a timeout occurs
RBRINSTRUMENT_CALLBACK_ERROR returned by a callback
See also
https://docs.rbr-global.com/L3commandreference/commands/other-information/id

◆ RBRInstrument_getInfo()

RBRInstrumentError RBRInstrument_getInfo ( RBRInstrument instrument,
RBRInstrumentInfo info 
)

Get more information about the instrument.

This parameter is unavailable for Logger2 instruments.

Parameters
[in]instrumentthe instrument connection
[out]infothe extended instrument information
Returns
RBRINSTRUMENT_UNSUPPORTED for Logger2 instruments
RBRINSTRUMENT_SUCCESS when the information is successfully read
RBRINSTRUMENT_TIMEOUT when a timeout occurs
RBRINSTRUMENT_CALLBACK_ERROR returned by a callback
See also
https://docs.rbr-global.com/L3commandreference/commands/other-information/info

◆ RBRInstrument_getPower()

RBRInstrumentError RBRInstrument_getPower ( RBRInstrument instrument,
RBRInstrumentPower power 
)

Get instrument power information.

Parameters
[in]instrumentthe instrument connection
[out]powerthe power information
Returns
RBRINSTRUMENT_SUCCESS when the information is successfully read
RBRINSTRUMENT_TIMEOUT when a timeout occurs
RBRINSTRUMENT_CALLBACK_ERROR returned by a callback
RBRINSTRUMENT_HARDWARE_ERROR if an error occurs reading voltages
See also
https://docs.rbr-global.com/L3commandreference/commands/other-information/power

◆ RBRInstrument_getPowerExternal()

RBRInstrumentError RBRInstrument_getPowerExternal ( RBRInstrument instrument,
RBRInstrumentPowerExternal power 
)

Get instrument external power information.

This parameter is unavailable for Logger2 instruments. Always returns RBRINSTRUMENT_UNSUPPORTED.

Parameters
[in]instrumentthe instrument connection
[out]powerthe power information
Returns
RBRINSTRUMENT_SUCCESS when the information is successfully read
RBRINSTRUMENT_TIMEOUT when a timeout occurs
RBRINSTRUMENT_CALLBACK_ERROR returned by a callback
See also
RBRInstrument_setPowerExternalBatteryType()
RBRInstrument_resetPowerExternalUsed()
https://docs.rbr-global.com/L3commandreference/commands/other-information/powerexternal

◆ RBRInstrument_getPowerInternal()

RBRInstrumentError RBRInstrument_getPowerInternal ( RBRInstrument instrument,
RBRInstrumentPowerInternal power 
)

Get instrument internal power information.

This parameter is unavailable for Logger2 instruments. Always returns RBRINSTRUMENT_UNSUPPORTED.

Parameters
[in]instrumentthe instrument connection
[out]powerthe power information
Returns
RBRINSTRUMENT_SUCCESS when the information is successfully read
RBRINSTRUMENT_TIMEOUT when a timeout occurs
RBRINSTRUMENT_CALLBACK_ERROR returned by a callback
See also
RBRInstrument_setPowerInternalBatteryType()
RBRInstrument_resetPowerInternalUsed()
https://docs.rbr-global.com/L3commandreference/commands/other-information/powerinternal

◆ RBRInstrument_resetPowerExternalUsed()

RBRInstrumentError RBRInstrument_resetPowerExternalUsed ( RBRInstrument instrument)

Reset the counter of energy used from the external battery.

This parameter is unavailable for Logger2 instruments. Always returns RBRINSTRUMENT_UNSUPPORTED.

Parameters
[in]instrumentthe instrument connection
Returns
RBRINSTRUMENT_SUCCESS when the setting is successfully written
RBRINSTRUMENT_TIMEOUT when a timeout occurs
RBRINSTRUMENT_CALLBACK_ERROR returned by a callback
See also
RBRInstrument_getPowerExternal()
https://docs.rbr-global.com/L3commandreference/commands/other-information/powerexternal

◆ RBRInstrument_resetPowerInternalUsed()

RBRInstrumentError RBRInstrument_resetPowerInternalUsed ( RBRInstrument instrument)

Reset the counter of energy used from the internal battery.

This parameter is unavailable for Logger2 instruments. Always returns RBRINSTRUMENT_UNSUPPORTED.

Parameters
[in]instrumentthe instrument connection
Returns
RBRINSTRUMENT_SUCCESS when the setting is successfully written
RBRINSTRUMENT_TIMEOUT when a timeout occurs
RBRINSTRUMENT_CALLBACK_ERROR returned by a callback
RBRINSTRUMENT_HARDWARE_ERROR when the instrument is logging
See also
RBRInstrument_getPowerInternal()
https://docs.rbr-global.com/L3commandreference/commands/other-information/powerinternal

◆ RBRInstrument_setInternalBatteryType()

RBRInstrumentError RBRInstrument_setInternalBatteryType ( RBRInstrument instrument,
RBRInstrumentInternalBatteryType  type 
)

Set the internal power battery type.

This parameter is unavailable for Logger2 instruments. Always returns RBRINSTRUMENT_UNSUPPORTED.

Parameters
[in]instrumentthe instrument connection
[in]typethe battery type
Returns
RBRINSTRUMENT_SUCCESS when the setting is successfully written
RBRINSTRUMENT_TIMEOUT when a timeout occurs
RBRINSTRUMENT_CALLBACK_ERROR returned by a callback
RBRINSTRUMENT_HARDWARE_ERROR when the instrument is logging
See also
RBRInstrument_getPowerInternal()
https://docs.rbr-global.com/L3commandreference/commands/other-information/powerinternal

◆ RBRInstrument_setPowerExternalBatteryType()

RBRInstrumentError RBRInstrument_setPowerExternalBatteryType ( RBRInstrument instrument,
RBRInstrumentExternalBatteryType  type 
)

Set the external power battery type.

This parameter is unavailable for Logger2 instruments. Always returns RBRINSTRUMENT_UNSUPPORTED.

Parameters
[in]instrumentthe instrument connection
[in]typethe battery type
Returns
RBRINSTRUMENT_SUCCESS when the setting is successfully written
RBRINSTRUMENT_TIMEOUT when a timeout occurs
RBRINSTRUMENT_CALLBACK_ERROR returned by a callback
See also
RBRInstrument_getPowerExternal()
https://docs.rbr-global.com/L3commandreference/commands/other-information/powerexternal

◆ RBRInstrumentExternalBatteryType_displayName()

const char* RBRInstrumentExternalBatteryType_displayName ( RBRInstrumentExternalBatteryType  type)

Get a human-readable display name for an external battery type.

Unlike the values returned by RBRInstrumentExternalBatteryType_name(), RBRfermata/RBRfermette product names will be correctly capitalized, and the names of battery types will be formatted appropriately for the cell chemistry; e.g., “RBRfermette³ Li-SOCl₂”, not “rbrfermette3 lisocl2”. Values will be UTF-8-encoded.

Parameters
[in]typethe battery type
Returns
a string name for the battery type
See also
RBRInstrumentExternalBatteryType_name() for instrument-equivalent names

◆ RBRInstrumentExternalBatteryType_name()

const char* RBRInstrumentExternalBatteryType_name ( RBRInstrumentExternalBatteryType  type)

Get a human-readable string name for an external battery type.

Parameters
[in]typethe battery type
Returns
a string name for the battery type
See also
RBRInstrumentError_name() for a description of the format of names
RBRInstrumentExternalBatteryType_displayName() for display names

◆ RBRInstrumentInternalBatteryType_displayName()

const char* RBRInstrumentInternalBatteryType_displayName ( RBRInstrumentInternalBatteryType  type)

Get a human-readable display name for an internal battery type.

Unlike the values returned by RBRInstrumentInternalBatteryType_name(), the names of battery types will be formatted appropriately for the cell chemistry; e.g., “Li-SOCl₂”, not “lisocl2”. Values will be UTF-8-encoded.

Parameters
[in]typethe battery type
Returns
a string name for the battery type
See also
RBRInstrumentInternalBatteryType_name() for instrument-equivalent names

◆ RBRInstrumentInternalBatteryType_name()

const char* RBRInstrumentInternalBatteryType_name ( RBRInstrumentInternalBatteryType  type)

Get a human-readable string name for an internal battery type.

Parameters
[in]typethe battery type
Returns
a string name for the battery type
See also
RBRInstrumentError_name() for a description of the format of names
RBRInstrumentInternalBatteryType_displayName() for display names

◆ RBRInstrumentPowerSource_name()

const char* RBRInstrumentPowerSource_name ( RBRInstrumentPowerSource  source)

Get a human-readable string name for a power source.

Parameters
[in]sourcethe power source
Returns
a string name for the power source
See also
RBRInstrumentError_name() for a description of the format of names

◆ RBRInstrumentVersion_compare()

int RBRInstrumentVersion_compare ( const char *  a,
const char *  b 
)

Compare two firmware version strings.

If either string is not a version string (format XXSYYY) then the result will indicate that it is the lesser version. If neither is valid, then the result will indicate equality.

Parameters
athe first firmware version as a null-terminated C string
bthe second firmware version as a null-terminated C string
Returns
<0 if a is a lower version than b
0 a and b are the same version
>0 if b is a lower version than b