Bluetooth Low Energy Host Stack  Rev. 4
API Reference Manual
gap_types.h File Reference
#include "ble_general.h"

Data Structures

struct  gapSmpKeys_t
 
struct  gapSecurityRequirements_t
 
struct  gapServiceSecurityRequirements_t
 
struct  gapDeviceSecurityRequirements_t
 
struct  gapHandleList_t
 
struct  gapConnectionSecurityInformation_t
 
struct  gapPairingParameters_t
 
struct  gapSlaveSecurityRequestParameters_t
 
struct  gapAdvertisingParameters_t
 
struct  gapScanningParameters_t
 
struct  gapConnectionRequestParameters_t
 
struct  gapConnectionParameters_t
 
struct  gapAdStructure_t
 
struct  gapAdvertisingData_t
 
struct  gapAdvertisingEvent_t
 
struct  gapScannedDevice_t
 
struct  gapScanningEvent_t
 
struct  gapConnectedEvent_t
 
struct  gapKeyExchangeRequestEvent_t
 
struct  gapKeysReceivedEvent_t
 
struct  gapAuthenticationRejectedEvent_t
 
struct  gapPairingCompleteEvent_t
 
struct  gapLongTermKeyRequestEvent_t
 
struct  gapEncryptionChangedEvent_t
 
struct  gapDisconnectedEvent_t
 
struct  gapConnParamsUpdateReq_t
 
struct  gapConnParamsUpdateComplete_t
 
struct  gapConnLeDataLengthChanged_t
 
struct  gapConnectionEvent_t
 
struct  gapIdentityInformation_t
 
struct  gapAutoConnectParams_t
 
union  gapAdvertisingEvent_t.eventData
 
union  gapScanningEvent_t.eventData
 
union  gapPairingCompleteEvent_t.pairingCompleteData
 
union  gapConnectionEvent_t.eventData
 

Macros

#define gCancelOngoingInitiatingConnection_d
 
#define gMode_2_Mask_d
 
#define getSecurityLevel(modeLevel)
 
#define getSecurityMode(modeLevel)
 
#define isMode_2(modeLevel)
 
#define isMode_1(modeLevel)
 
#define isSameMode(modeLevelA, modeLevelB)
 
#define addSameSecurityModes(modeLevelA, modeLevelB)
 
#define addMode1AndMode2(mode1, mode2)
 
#define addDifferentSecurityModes(modeLevelA, modeLevelB)
 
#define gDefaultEncryptionKeySize_d
 
#define gGapDefaultDeviceSecurity_d
 
#define gGapDefaultSecurityRequirements_d
 
#define gGapAdvertisingIntervalRangeMinimum_c
 
#define gGapAdvertisingIntervalDefault_c
 
#define gGapAdvertisingIntervalRangeMaximum_c
 
#define gGapAdvertisingChannelMapDefault_c
 
#define gGapDefaultAdvertisingParameters_d
 
#define gGapScanIntervalMin_d
 
#define gGapScanIntervalDefault_d
 
#define gGapScanIntervalMax_d
 
#define gGapScanWindowMin_d
 
#define gGapScanWindowDefault_d
 
#define gGapScanWindowMax_d
 
#define gGapRssiMin_d
 
#define gGapRssiMax_d
 
#define gGapRssiNotAvailable_d
 
#define gGapDefaultScanningParameters_d
 
#define gGapConnIntervalMin_d
 
#define gGapConnIntervalMax_d
 
#define gGapConnLatencyMin_d
 
#define gGapConnLatencyMax_d
 
#define gGapConnSuperTimeoutMin_d
 
#define gGapConnSuperTimeoutMax_d
 
#define gGapConnEventLengthMin_d
 
#define gGapConnEventLengthMax_d
 
#define gGapDefaultConnectionLatency_d
 
#define gGapDefaultSupervisionTimeout_d
 
#define gGapDefaultMinConnectionInterval_d
 
#define gGapDefaultMaxConnectionInterval_d
 
#define gGapDefaultConnectionRequestParameters_d
 

Typedefs

typedef gapAdvertisingData_t gapScanResponseData_t
 
typedef bleResult_t gapDisconnectionReason_t
 
typedef void(* gapAdvertisingCallback_t) (gapAdvertisingEvent_t *pAdvertisingEvent)
 
typedef void(* gapScanningCallback_t) (gapScanningEvent_t *pScanningEvent)
 
typedef void(* gapConnectionCallback_t) (deviceId_t deviceId, gapConnectionEvent_t *pConnectionEvent)
 

Enumerations

enum  gapRole_t { gGapCentral_c, gGapPeripheral_c, gGapObserver_c, gGapBroadcaster_c }
 
enum  gapIoCapabilities_t {
  gIoDisplayOnly_c, gIoDisplayYesNo_c, gIoKeyboardOnly_c, gIoNone_c,
  gIoKeyboardDisplay_c
}
 
enum  gapSmpKeyFlags_t { gNoKeys_c, gLtk_c, gIrk_c, gCsrk_c }
 
enum  gapSecurityMode_t { gSecurityMode_1_c, gSecurityMode_2_c }
 
enum  gapSecurityLevel_t { gSecurityLevel_NoSecurity_c, gSecurityLevel_NoMitmProtection_c, gSecurityLevel_WithMitmProtection_c, gSecurityLevel_LeSecureConnections_c }
 
enum  gapSecurityModeAndLevel_t {
  gSecurityMode_1_Level_1_c, gSecurityMode_1_Level_2_c, gSecurityMode_1_Level_3_c, gSecurityMode_1_Level_4_c,
  gSecurityMode_2_Level_1_c, gSecurityMode_2_Level_2_c
}
 
enum  gapKeypressNotification_t {
  gKnPasskeyEntryStarted_c, gKnPasskeyDigitStarted_c, gKnPasskeyDigitErased_c, gKnPasskeyCleared_c,
  gKnPasskeyEntryCompleted_c
}
 
enum  gapAuthenticationRejectReason_t {
  gLinkEncryptionFailed_c, gOobNotAvailable_c, gIncompatibleIoCapabilities_c, gPairingNotSupported_c,
  gLowEncryptionKeySize_c, gRepeatedAttempts_c, gUnspecifiedReason_c
}
 
enum  gapScanMode_t { gDefaultScan_c, gLimitedDiscovery_c, gGeneralDiscovery_c, gAutoConnect_c }
 
enum  gapAdvertisingChannelMapFlags_t { gAdvChanMapFlag37_c, gAdvChanMapFlag38_c, gAdvChanMapFlag39_c }
 
enum  gapAdvertisingFilterPolicy_t { gProcessAll_c, gProcessConnAllScanWL_c, gProcessScanAllConnWL_c, gProcessWhiteListOnly_c }
 
enum  gapAdType_t {
  gAdFlags_c, gAdIncomplete16bitServiceList_c, gAdComplete16bitServiceList_c, gAdIncomplete32bitServiceList_c,
  gAdComplete32bitServiceList_c, gAdIncomplete128bitServiceList_c, gAdComplete128bitServiceList_c, gAdShortenedLocalName_c,
  gAdCompleteLocalName_c, gAdTxPowerLevel_c, gAdClassOfDevice_c, gAdSimplePairingHashC192_c,
  gAdSimplePairingRandomizerR192_c, gAdSecurityManagerTkValue_c, gAdSecurityManagerOobFlags_c, gAdSlaveConnectionIntervalRange_c,
  gAdServiceSolicitationList16bit_c, gAdServiceSolicitationList32bit_c, gAdServiceSolicitationList128bit_c, gAdServiceData16bit_c,
  gAdServiceData32bit_c, gAdServiceData128bit_c, gAdPublicTargetAddress_c, gAdRandomTargetAddress_c,
  gAdAppearance_c, gAdAdvertisingInterval_c, gAdLeDeviceAddress_c, gAdLeRole_c,
  gAdSimplePairingHashC256_c, gAdSimplePairingRandomizerR256_c, gAd3dInformationData_c, gAdManufacturerSpecificData_c
}
 
enum  gapAdTypeFlags_t {
  gNone_c, gLeLimitedDiscoverableMode_c, gLeGeneralDiscoverableMode_c, gBrEdrNotSupported_c,
  gSimultaneousLeBrEdrCapableController_c, gSimultaneousLeBrEdrCapableHost_c
}
 
enum  gapRadioPowerLevelReadType_t { gTxPowerCurrentLevelInConnection_c, gTxPowerMaximumLevelInConnection_c, gTxPowerLevelForAdvertising_c, gRssi_c }
 
enum  gapControllerTestCmd_t { gControllerTestCmdStartRx_c, gControllerTestCmdStartTx_c, gControllerTestCmdEnd_c }
 
enum  gapControllerTestTxType_t {
  gControllerTestTxPrbs9_c, gControllerTestTxF0_c, gControllerTestTxAA_c, gControllerTestTxPrbs15_c,
  gControllerTestTxFF_c, gControllerTestTx00_c, gControllerTestTx0F_c, gControllerTestTx55_c
}
 
enum  gapAdvertisingEventType_t { gAdvertisingStateChanged_c, gAdvertisingCommandFailed_c }
 
enum  gapScanningEventType_t { gScanStateChanged_c, gScanCommandFailed_c, gDeviceScanned_c }
 
enum  gapConnectionEventType_t {
  gConnEvtConnected_c, gConnEvtPairingRequest_c, gConnEvtSlaveSecurityRequest_c, gConnEvtPairingResponse_c,
  gConnEvtAuthenticationRejected_c, gConnEvtPasskeyRequest_c, gConnEvtOobRequest_c, gConnEvtPasskeyDisplay_c,
  gConnEvtKeyExchangeRequest_c, gConnEvtKeysReceived_c, gConnEvtLongTermKeyRequest_c, gConnEvtEncryptionChanged_c,
  gConnEvtPairingComplete_c, gConnEvtDisconnected_c, gConnEvtRssiRead_c, gConnEvtTxPowerLevelRead_c,
  gConnEvtPowerReadFailure_c, gConnEvtParameterUpdateRequest_c, gConnEvtParameterUpdateComplete_c, gConnEvtLeDataLengthChanged_c,
  gConnEvtLeScOobDataRequest_c, gConnEvtLeScDisplayNumericValue_c, gConnEvtLeScKeypressNotification_c
}
 
enum  gapAppearance_t {
  gUnknown_c, gGenericPhone_c, gGenericComputer_c, gGenericWatch_c,
  gSportsWatch_c, gGenericClock_c, gGenericDisplay_c, gGenericRemoteControl_c,
  gGenericEyeglasses_c, gGenericTag_c, gGenericKeyring_c, gGenericMediaPlayer_c,
  gGenericBarcodeScanner_c, gGenericThermometer_c, gThermometerEar_c, gGenericHeartrateSensor_c,
  gHeartRateSensorHeartRateBelt_c, gGenericBloodPressure_c, gBloodPressureArm_c, gBloodPressureWrist_c,
  gHumanInterfaceDevice_c, gKeyboard_c, gMouse_c, gJoystick_c,
  gGamepad_c, gDigitizerTablet_c, gCardReader_c, gDigitalPen_c,
  gBarcodeScanner_c, gGenericGlucoseMeter_c, gGenericRunningWalkingSensor_c, gRunningWalkingSensorInShoe_c,
  gRunningWalkingSensorOnShoe_c, gRunningWalkingSensorOnHip_c, gGenericCycling_c, gCyclingComputer_c,
  gCyclingSpeedSensor_c, gCyclingCadenceSensor_c, gCyclingPowerSensor_c, gCyclingSpeedandCadenceSensor_c,
  gGenericPulseOximeter_c, gFingertip_c, gWristWorn_c, gGenericWeightScale_c,
  gGenericOutdoorSportsActivity_c, gLocationDisplayDevice_c, gLocationandNavigationDisplayDevice_c, gLocationPod_c,
  gLocationAndNavigationPod_c
}
 

Detailed Description

Copyright (c) 2014, Freescale Semiconductor, Inc.

All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

o Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.

o Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

o Neither the name of Freescale Semiconductor, Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.