Cordio Stack and Cordio Profiles  r2p3-02rel0
svc_gyro.h File Reference

Example gyroscope sensor service implementation. More...

Go to the source code of this file.

Macros

#define GYRO_SIZE_CONFIG_ATT   1u
 Sizes of attributes. More...
 
#define GYRO_SIZE_PERIOD_ATT   1u
 Period attribute size.
 
#define GYRO_SIZE_DATA_ATT   6u
 Data attribute size.
 
#define GYRO_SIZE_TEMPDATA_ATT   2u
 Temp data attribute size.
 
Values for Config Attributes
#define GYRO_ATT_CONFIG_DISABLE   0x00u
 Disable.
 
#define GYRO_ATT_CONFIG_ENABLE   0x01u
 Enable.
 
Values for Period Attributes.
#define GYRO_ATT_PERIOD_MAX   250u
 Maximum period.
 
#define GYRO_ATT_PERIOD_DEFAULT   100u
 Default period.
 
#define GYRO_ATT_PERIOD_MIN   10u
 Minimum period.
 

Functions

void SvcGyroAddGroup (void)
 Add the services to the attribute server. More...
 
void SvcGyroRemoveGroup (void)
 Remove the services from the attribute server. More...
 
void SvcGyroCbackRegister (attsWriteCback_t writeCback)
 Register callbacks for the service. More...
 

Gyroscope Sensor Service Handles

#define GYRO_HANDLE_START   0x50
 Start handle.
 
#define GYRO_HANDLE_END   (GYRO_HANDLE_END_PLUS_ONE - 1)
 End handle.
 
enum  {
  GYRO_HANDLE_SVC = GYRO_HANDLE_START,
  GYRO_HANDLE_DATA_CHR,
  GYRO_HANDLE_DATA,
  GYRO_HANDLE_DATA_CLIENT_CHR_CONFIG,
  GYRO_HANDLE_DATA_CHR_USR_DESCR,
  GYRO_HANDLE_TEMPDATA_CHR,
  GYRO_HANDLE_TEMPDATA,
  GYRO_HANDLE_TEMPDATA_CLIENT_CHR_CONFIG,
  GYRO_HANDLE_TEMPDATA_CHR_USR_DESCR,
  GYRO_HANDLE_CONFIG_CHR,
  GYRO_HANDLE_CONFIG,
  GYRO_HANDLE_CONFIG_CHR_USR_DESCR,
  GYRO_HANDLE_PERIOD_CHR,
  GYRO_HANDLE_PERIOD,
  GYRO_HANDLE_PERIOD_CHR_USR_DESCR,
  GYRO_HANDLE_END_PLUS_ONE
}
 Gyroscope service handles. More...
 

Description

Example gyroscope sensor service implementation.

Copyright (c) 2015-2018 Arm Ltd. All Rights Reserved. Arm Ltd. confidential and proprietary.

IMPORTANT. Your use of this file is governed by a Software License Agreement ("Agreement") that must be accepted in order to download or otherwise receive a copy of this file. You may not use or copy this file for any purpose other than as described in the Agreement. If you do not agree to all of the terms of the Agreement do not use this file and delete all copies in your possession or control; if you do not have a copy of the Agreement, you must contact Arm Ltd. prior to any use, copying or further distribution of this software.

Definition in file svc_gyro.h.

Function Documentation

void SvcGyroAddGroup ( void  )

Add the services to the attribute server.

Returns
None.
void SvcGyroRemoveGroup ( void  )

Remove the services from the attribute server.

Returns
None.
void SvcGyroCbackRegister ( attsWriteCback_t  writeCback)

Register callbacks for the service.

Parameters
writeCbackWrite callback function.
Returns
None.