Dawn Framework 1.0
Universal data acquisition framework for embedded systems
Public Types | Public Member Functions | Public Attributes | List of all members
dawn::CProtoNimblePrphImds Class Reference

Industrial Measurement Device Service (IMDS) for BLE Peripheral. More...

#include <prph_imds.hxx>

Inheritance diagram for dawn::CProtoNimblePrphImds:
[legend]
Collaboration diagram for dawn::CProtoNimblePrphImds:
[legend]

Public Types

enum  { IMDS_EXT_USER_DESCRIPTION = 1 }
 
enum  {
  PRPH_IMDS_TYPE_TEMP , PRPH_IMDS_TYPE_HUM , PRPH_IMDS_TYPE_PRESS , PRPH_IMDS_TYPE_UVIDX ,
  PRPH_IMDS_TYPE_GAS , PRPH_IMDS_TYPE_LIGHT
}
 

Public Member Functions

int deinit ()
 Deinitialize service.
 
int init ()
 Initialize service.
 
int start ()
 Start service.
 
int stop ()
 Stop service.
 

Public Attributes

IProtoNimblePrphCbcb
 Callback interface to peripheral.
 
const SObjectCfg::SObjectCfgItemdesc
 Configuration descriptor for this service.
 
std::vector< SObjectId::ObjectIdvio
 Vector of I/O objects exposed by this service.
 

Detailed Description

Industrial Measurement Device Service (IMDS) for BLE Peripheral.

This class implements the Bluetooth SIG Industrial Measurement Device Service (0x185A).

Definition at line 27 of file prph_imds.hxx.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
IMDS_EXT_USER_DESCRIPTION 

Characteristic User Description descriptor.

Definition at line 43 of file prph_imds.hxx.

◆ anonymous enum

anonymous enum
Enumerator
PRPH_IMDS_TYPE_TEMP 

Industrial temperature sensor.

PRPH_IMDS_TYPE_HUM 

Industrial humidity sensor.

PRPH_IMDS_TYPE_PRESS 

Industrial pressure sensor.

PRPH_IMDS_TYPE_UVIDX 

Industrial UV index sensor.

PRPH_IMDS_TYPE_GAS 

Industrial gas resistance sensor (non-standard UUID).

PRPH_IMDS_TYPE_LIGHT 

Industrial illuminance / light sensor.

Definition at line 48 of file prph_imds.hxx.

Member Function Documentation

◆ deinit()

int CProtoNimblePrphImds::deinit ( )
virtual

Deinitialize service.

Releases all allocated resources for this service.

Returns
int 0 on success, negative error code on failure.

Implements dawn::IProtoNimblePrphService.

Definition at line 609 of file prph_imds.cxx.

◆ init()

int CProtoNimblePrphImds::init ( )
virtual

Initialize service.

Allocates service resources and prepares characteristics.

Returns
int 0 on success, negative error code on failure.

Implements dawn::IProtoNimblePrphService.

Definition at line 581 of file prph_imds.cxx.

References dawn::IProtoNimblePrphService::cb, dawn::IProtoNimblePrphService::desc, and dawn::IProtoNimblePrphCb::serviceRegister().

Here is the call graph for this function:

◆ start()

int CProtoNimblePrphImds::start ( )
virtual

Start service.

Registers the service with the GATT database.

Returns
int 0 on success, negative error code on failure.

Implements dawn::IProtoNimblePrphService.

Definition at line 615 of file prph_imds.cxx.

References dawn::IProtoNimblePrphService::cb, and dawn::IProtoNimblePrphCb::startService().

Here is the call graph for this function:

◆ stop()

int CProtoNimblePrphImds::stop ( )
virtual

Stop service.

Removes the service from the GATT database.

Returns
int 0 on success, negative error code on failure.

Implements dawn::IProtoNimblePrphService.

Definition at line 641 of file prph_imds.cxx.

References dawn::IProtoNimblePrphService::cb, and dawn::IProtoNimblePrphCb::stopService().

Here is the call graph for this function:

Member Data Documentation

◆ cb

IProtoNimblePrphCb* dawn::IProtoNimblePrphService::cb
inherited

Callback interface to peripheral.

Services use this to register GATT services, start/stop services, and access I/O objects.

Definition at line 566 of file iprph.hxx.

◆ desc

const SObjectCfg::SObjectCfgItem* dawn::IProtoNimblePrphService::desc
inherited

Configuration descriptor for this service.

Points to the configuration item that specified this service's setup.

Definition at line 574 of file iprph.hxx.

◆ vio

std::vector<SObjectId::ObjectId> dawn::IProtoNimblePrphService::vio
inherited

Vector of I/O objects exposed by this service.

Each entry is an I/O object ID that this service manages.

Definition at line 557 of file iprph.hxx.


The documentation for this class was generated from the following files: