Modules#

EmberAfGreenPowerServerCommissioningState

GpDeviceIdAndCommandMap

GpDeviceIdAndClusterMap

ZigbeeCluster

GpCommDataSaved

Green Power Server

Green Power Server#

API and Callbacks for the Green Power Cluster Server Component.

A component implementing the server-side functionality of the Green Power cluster.

API#

Get a GPD commissioning instance in a multiple GPD commissioning session.

void

Delete a GPD commissioning instance in a multiple GPD commissioning session.

void

Extend the commissioning window of a commissioning session.

Get the commissioning state of the green power server.

emberAfGreenPowerServerDeriveSharedKeyFromSinkAttribute(uint8_t *gpsSecurityKeyTypeAtrribute, EmberKeyData *gpSharedKeyAttribute, EmberGpAddress *gpdAddr)

Derive the shared key from the sink attributes.

Enumerations#

enum
GREEN_POWER_SERVER_GPS_NODE_STATE_NOT_IN_NETWORK
GREEN_POWER_SERVER_GPS_NODE_STATE_IN_NETWORK
}
enum
GREEN_POWER_SERVER_SINK_TABLE_ACCESS_TYPE_REMOVE_GPD
GREEN_POWER_SERVER_SINK_TABLE_ACCESS_TYPE_ADD_GPD
GREEN_POWER_SERVER_SINK_TABLE_ACCESS_TYPE_UNKNOWN
}
enum
GP_SINK_COMM_STATE_IDLE
GP_SINK_COMM_STATE_COLLECT_REPORTS
GP_SINK_COMM_STATE_SEND_COMM_REPLY
GP_SINK_COMM_STATE_WAIT_FOR_SUCCESS
GP_SINK_COMM_STATE_FINALISE_PAIRING
GP_SINK_COMM_STATE_PAIRING_DONE
}
enum
COMMISSIONING_TIMEOUT_TYPE_GENERIC_SWITCH = 0
COMMISSIONING_TIMEOUT_TYPE_MULTI_SENSOR = 1
COMMISSIONING_TIMEOUT_TYPE_COMMISSIONING_WINDOW_TIMEOUT = 2
}

Macros#

#define
EMBER_AF_GREEN_POWER_GP_SHARED_KEY 0
#define
EMBER_AF_GREEN_POWER_GP_INDIVIDUAL_KEY 1
#define
GREEN_POWER_SERVER_NO_PAIRED_ENDPOINTS 0x00
#define
GREEN_POWER_SERVER_RESERVED_ENDPOINTS 0xFD
#define
GREEN_POWER_SERVER_SINK_DERIVES_ENDPOINTS 0xFE
#define
GREEN_POWER_SERVER_ALL_SINK_ENDPOINTS 0xFF
#define
GREEN_POWER_SERVER_MIN_VALID_APP_ENDPOINT 1
#define
GREEN_POWER_SERVER_MAX_VALID_APP_ENDPOINT 240
#define
GREEN_POWER_SERVER_GPS_SECURITY_LEVEL_ATTRIBUTE_FIELD_INVOLVE_TC 0x08
#define
GP_DEVICE_ANNOUNCE_SIZE 12
#define
SIZE_OF_REPORT_STORAGE 82
#define
COMM_REPLY_PAYLOAD_SIZE 30
#define
GP_SINK_TABLE_RESPONSE_ENTRIES_OFFSET (3)
#define
EMBER_AF_ZCL_CLUSTER_GP_GPS_COMMISSIONING_WINDOWS_DEFAULT_TIME_S (180)
#define
GP_ADDR_SRC_ID_WILDCARD (0xFFFFFFFF)
#define
GPS_ATTRIBUTE_KEY_TYPE_MASK (0x07)
#define
GP_PAIRING_CONFIGURATION_FIXED_FLAG (0x230)
#define
GREEN_POWER_SERVER_MIN_REPORT_LENGTH (10)
#define
FIX_SHIFT_REPORTING_DATA_POSITION_CONVERT_TO_PAYLOAD_INDEX (3)
#define
CAR_DATA_POINT_OFFSET 1
#define
GP_DEFAULT_LINK_KEY { 0x5A, 0x69, 0x67, 0x42, 0x65, 0x65, 0x41, 0x6C, 0x6C, 0x69, 0x61, 0x6E, 0x63, 0x65, 0x30, 0x39 }
#define
genericSwitchCommissioningTimeout (&emberAfPluginGreenPowerServerGenericSwitchCommissioningTimeoutEvent)
#define
multiSensorCommissioningTimeout (&emberAfPluginGreenPowerServerMultiSensorCommissioningTimeoutEvent)
#define
commissioningWindowTimeout (&emberAfPluginGreenPowerServerCommissioningWindowTimeoutEvent)

API Documentation#

emberAfGreenPowerServerFindCommissioningGpdInstance#

GpCommDataSaved* emberAfGreenPowerServerFindCommissioningGpdInstance (EmberGpAddress * gpdAddr)

Get a GPD commissioning instance in a multiple GPD commissioning session.

Parameters
TypeDirectionArgument NameDescription
EmberGpAddress *N/AgpdAddr

GPD address Ver.: always

The green power server can be configured to allow multiple GPDs to commission within a commissioning session. Given a GPD instance address, this function will find the currently-commissioning GPD instance. This is a helpful indicator of the commissioning progress of a given GPD when multi GPDS are commissioning in a commissioning window.

Returns

  • Information on the commissioning pointed by a structure GpCommDataSaved type about the GPD.


emberAfGreenPowerServerDeleteCommissioningGpdInstance#

void emberAfGreenPowerServerDeleteCommissioningGpdInstance (EmberGpAddress * gpdAddr)

Delete a GPD commissioning instance in a multiple GPD commissioning session.

Parameters
TypeDirectionArgument NameDescription
EmberGpAddress *N/AgpdAddr

GPD address Ver.: always

The green power server can be configured to allow multiple GPDs to commission within a commissioning session. Given a GPD instance address, this function will find and delete the currently-commissioning GPD instance. This is a helpful way to remove unwanted GPD instances in a multiple GPD commissioning session.


emberAfGreenPowerClusterGpSinkCommissioningWindowExtend#

void emberAfGreenPowerClusterGpSinkCommissioningWindowExtend (uint16_t commissioningWindow)

Extend the commissioning window of a commissioning session.

Parameters
TypeDirectionArgument NameDescription
uint16_tN/AcommissioningWindow

Commissioning window to be extended from this point in time in seconds Ver.: always

This is a helper function that sends out a proxy commissioning mode from the server side to all proxies in the network. It internally uses the same parameters used previously in the proxy commissioning mode with action = enter.


emberAfGreenPowerClusterGetServerCommissioningSate#

EmberAfGreenPowerServerCommissioningState* emberAfGreenPowerClusterGetServerCommissioningSate (void )

Get the commissioning state of the green power server.

Parameters
TypeDirectionArgument NameDescription
voidN/A

This function gets the commissioning state of the green power server.

Returns


emberAfGreenPowerServerDeriveSharedKeyFromSinkAttribute#

EmberAfStatus emberAfGreenPowerServerDeriveSharedKeyFromSinkAttribute (uint8_t * gpsSecurityKeyTypeAtrribute, EmberKeyData * gpSharedKeyAttribute, EmberGpAddress * gpdAddr)

Derive the shared key from the sink attributes.

Parameters
TypeDirectionArgument NameDescription
uint8_t *N/AgpsSecurityKeyTypeAtrribute

Security key type attribute as input

EmberKeyData *N/AgpSharedKeyAttribute

Security key attribute as output

EmberGpAddress *N/AgpdAddr

GPD address

This function derives the shared key used in green power server side using the respective security attribute values.

Returns

  • Status of the key derivation Ver.: always


Enumeration Documentation#

GreenPowerServerGPSNodeState#

GreenPowerServerGPSNodeState
Enumerator
GREEN_POWER_SERVER_GPS_NODE_STATE_NOT_IN_NETWORK
GREEN_POWER_SERVER_GPS_NODE_STATE_IN_NETWORK

GreenPowerServerSinkTableAccessType#

GreenPowerServerSinkTableAccessType
Enumerator
GREEN_POWER_SERVER_SINK_TABLE_ACCESS_TYPE_REMOVE_GPD
GREEN_POWER_SERVER_SINK_TABLE_ACCESS_TYPE_ADD_GPD
GREEN_POWER_SERVER_SINK_TABLE_ACCESS_TYPE_UNKNOWN

GPSinkCommState#

GPSinkCommState
Enumerator
GP_SINK_COMM_STATE_IDLE
GP_SINK_COMM_STATE_COLLECT_REPORTS
GP_SINK_COMM_STATE_SEND_COMM_REPLY
GP_SINK_COMM_STATE_WAIT_FOR_SUCCESS
GP_SINK_COMM_STATE_FINALISE_PAIRING
GP_SINK_COMM_STATE_PAIRING_DONE

CommissioningTimeoutType#

CommissioningTimeoutType
Enumerator
COMMISSIONING_TIMEOUT_TYPE_GENERIC_SWITCH
COMMISSIONING_TIMEOUT_TYPE_MULTI_SENSOR
COMMISSIONING_TIMEOUT_TYPE_COMMISSIONING_WINDOW_TIMEOUT

Typedef Documentation#

GpsNetworkState#

typedef uint8_t GpsNetworkState

EmberAfGpServerSinkTableAccessType#

typedef uint8_t EmberAfGpServerSinkTableAccessType

EmberSinkCommissionState#

typedef uint8_t EmberSinkCommissionState

EmberSinkCommissioningTimeoutType#

typedef uint8_t EmberSinkCommissioningTimeoutType

Variable Documentation#

emberAfPluginGreenPowerServerGenericSwitchCommissioningTimeoutEvent#

sl_zigbee_event_t emberAfPluginGreenPowerServerGenericSwitchCommissioningTimeoutEvent

emberAfPluginGreenPowerServerMultiSensorCommissioningTimeoutEvent#

sl_zigbee_event_t emberAfPluginGreenPowerServerMultiSensorCommissioningTimeoutEvent

emberAfPluginGreenPowerServerCommissioningWindowTimeoutEvent#

sl_zigbee_event_t emberAfPluginGreenPowerServerCommissioningWindowTimeoutEvent

Function Documentation#

emberAfPluginGreenPowerServerGenericSwitchCommissioningTimeoutEventHandler#

void emberAfPluginGreenPowerServerGenericSwitchCommissioningTimeoutEventHandler (SLXU_UC_EVENT )
Parameters
TypeDirectionArgument NameDescription
SLXU_UC_EVENTN/A

emberAfPluginGreenPowerServerMultiSensorCommissioningTimeoutEventHandler#

void emberAfPluginGreenPowerServerMultiSensorCommissioningTimeoutEventHandler (SLXU_UC_EVENT )
Parameters
TypeDirectionArgument NameDescription
SLXU_UC_EVENTN/A

emberAfPluginGreenPowerServerCommissioningWindowTimeoutEventHandler#

void emberAfPluginGreenPowerServerCommissioningWindowTimeoutEventHandler (SLXU_UC_EVENT )
Parameters
TypeDirectionArgument NameDescription
SLXU_UC_EVENTN/A