fe0caa9bb35762e58af8b438bd69d2ba117c33f0
[platform/upstream/connectedhomeip.git] / examples / lock-app / lock-common / gen / callback.h
1 /*
2  *
3  *    Copyright (c) 2021 Project CHIP Authors
4  *
5  *    Licensed under the Apache License, Version 2.0 (the "License");
6  *    you may not use this file except in compliance with the License.
7  *    You may obtain a copy of the License at
8  *
9  *        http://www.apache.org/licenses/LICENSE-2.0
10  *
11  *    Unless required by applicable law or agreed to in writing, software
12  *    distributed under the License is distributed on an "AS IS" BASIS,
13  *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  *    See the License for the specific language governing permissions and
15  *    limitations under the License.
16  */
17
18 // THIS FILE IS GENERATED BY ZAP
19
20 // Prevent multiple inclusion
21 #pragma once
22
23 #include "af-structs.h"
24 #include "af-types.h"
25 #include "basic-types.h"
26
27 /** @brief Cluster Init
28  *
29  * This function is called when a specific cluster is initialized. It gives the
30  * application an opportunity to take care of cluster initialization procedures.
31  * It is called exactly once for each endpoint where cluster is present.
32  *
33  * @param endpoint   Ver.: always
34  * @param clusterId   Ver.: always
35  */
36 void emberAfClusterInitCallback(chip::EndpointId endpoint, chip::ClusterId clusterId);
37
38 // Cluster Init Functions
39
40 /** @brief On/off Cluster Init
41  *
42  * Cluster Init
43  *
44  * @param endpoint    Endpoint that is being initialized
45  */
46 void emberAfOnOffClusterInitCallback(chip::EndpointId endpoint);
47
48 // Cluster Server/Client Init Functions
49
50 //
51 // On/off Cluster server
52 //
53
54 /** @brief On/off Cluster Server Init
55  *
56  * Server Init
57  *
58  * @param endpoint    Endpoint that is being initialized
59  */
60 void emberAfOnOffClusterServerInitCallback(chip::EndpointId endpoint);
61
62 /** @brief On/off Cluster Server Attribute Changed
63  *
64  * Server Attribute Changed
65  *
66  * @param endpoint    Endpoint that is being initialized
67  * @param attributeId Attribute that changed
68  */
69 void emberAfOnOffClusterServerAttributeChangedCallback(chip::EndpointId endpoint, chip::AttributeId attributeId);
70
71 /** @brief On/off Cluster Server Manufacturer Specific Attribute Changed
72  *
73  * Server Manufacturer Specific Attribute Changed
74  *
75  * @param endpoint          Endpoint that is being initialized
76  * @param attributeId       Attribute that changed
77  * @param manufacturerCode  Manufacturer Code of the attribute that changed
78  */
79 void emberAfOnOffClusterServerManufacturerSpecificAttributeChangedCallback(chip::EndpointId endpoint, chip::AttributeId attributeId,
80                                                                            uint16_t manufacturerCode);
81
82 /** @brief On/off Cluster Server Message Sent
83  *
84  * Server Message Sent
85  *
86  * @param type               The type of message sent
87  * @param indexOrDestination The destination or address to which the message was sent
88  * @param apsFrame           The APS frame for the message
89  * @param msgLen             The length of the message
90  * @param message            The message that was sent
91  * @param status             The status of the sent message
92  */
93 void emberAfOnOffClusterServerMessageSentCallback(EmberOutgoingMessageType type, uint64_t indexOrDestination,
94                                                   EmberApsFrame * apsFrame, uint16_t msgLen, uint8_t * message, EmberStatus status);
95
96 /** @brief On/off Cluster Server Pre Attribute Changed
97  *
98  * server Pre Attribute Changed
99  *
100  * @param endpoint      Endpoint that is being initialized
101  * @param attributeId   Attribute to be changed
102  * @param attributeType Attribute type
103  * @param size          Attribute size
104  * @param value         Attribute value
105  */
106 EmberAfStatus emberAfOnOffClusterServerPreAttributeChangedCallback(chip::EndpointId endpoint, chip::AttributeId attributeId,
107                                                                    EmberAfAttributeType attributeType, uint8_t size,
108                                                                    uint8_t * value);
109
110 /** @brief On/off Cluster Server Tick
111  *
112  * server Tick
113  *
114  * @param endpoint  Endpoint that is being served
115  */
116 void emberAfOnOffClusterServerTickCallback(chip::EndpointId endpoint);
117
118 // Cluster Commands Callback
119
120 /**
121  * @brief On/off Cluster Off Command callback
122  */
123
124 bool emberAfOnOffClusterOffCallback();
125
126 /**
127  * @brief On/off Cluster On Command callback
128  */
129
130 bool emberAfOnOffClusterOnCallback();
131
132 /**
133  * @brief On/off Cluster Toggle Command callback
134  */
135
136 bool emberAfOnOffClusterToggleCallback();
137
138 //
139 // Non-Cluster Related Callbacks
140 //
141
142 /** @brief Add To Current App Tasks
143  *
144  * This function is only useful to sleepy end devices.  This function will note
145  * the passed item as part of a set of tasks the application has outstanding
146  * (e.g. message sent requiring APS acknwoledgement).  This will affect how the
147  * application behaves with regard to sleeping and polling.  Until the
148  * outstanding task is completed, the device may poll more frequently and sleep
149  * less often.
150  *
151  * @param tasks   Ver.: always
152  */
153 void emberAfAddToCurrentAppTasksCallback(EmberAfApplicationTask tasks);
154
155 /** @brief Remove From Current App Tasks
156  *
157  * This function is only useful to sleepy end devices.  This function will
158  * remove the passed item from the set of tasks the application has outstanding
159  * (e.g. message sent requiring APS acknwoledgement).  This will affect how the
160  * application behaves with regard to sleeping and polling.  Removing the item
161  * from the list of outstanding tasks may allow the device to sleep longer and
162  * poll less frequently.  If there are other outstanding tasks the system may
163  * still have to stay away and poll more often.
164  *
165  * @param tasks   Ver.: always
166  */
167 void emberAfRemoveFromCurrentAppTasksCallback(EmberAfApplicationTask tasks);
168
169 /** @brief Allow Network Write Attribute
170  *
171  * This function is called by the application framework before it writes an
172  * attribute in response to a write attribute request from an external device.
173  * The value passed into this callback is the value to which the attribute is to
174  * be set by the framework.
175         Example:        In mirroring simple metering data
176  * on an Energy Services Interface (ESI) (formerly called Energy Service Portal
177  * (ESP) in SE 1.0).), a mirrored simple meter needs to write read-only
178  * attributes on its mirror. The-meter-mirror sample application, located in
179  * app/framework/sample-apps, uses this callback to allow the mirrored device to
180  * write simple metering attributes on the mirror regardless of the fact that
181  * most simple metering attributes are defined as read-only by the ZigBee
182  * specification.
183         Note:   The ZCL specification does not (as of this
184  * writing) specify any permission-level security for writing writeable
185  * attributes. As far as the ZCL specification is concerned, if an attribute is
186  * writeable, any device that has a link key for the device should be able to
187  * write that attribute. Furthermore if an attribute is read only, it should not
188  * be written over the air. Thus, if you implement permissions for writing
189  * attributes as a feature, you MAY be operating outside the specification. This
190  * is unlikely to be a problem for writing read-only attributes, but it may be a
191  * problem for attributes that are writeable according to the specification but
192  * restricted by the application implementing this callback.
193  *
194  * @param endpoint   Ver.: always
195  * @param clusterId   Ver.: always
196  * @param attributeId   Ver.: always
197  * @param mask   Ver.: always
198  * @param manufacturerCode   Ver.: always
199  * @param value   Ver.: always
200  * @param type   Ver.: always
201  */
202 EmberAfAttributeWritePermission emberAfAllowNetworkWriteAttributeCallback(chip::EndpointId endpoint, chip::ClusterId clusterId,
203                                                                           chip::AttributeId attributeId, uint8_t mask,
204                                                                           uint16_t manufacturerCode, uint8_t * value, uint8_t type);
205
206 /** @brief Attribute Read Access
207  *
208  * This function is called whenever the Application Framework needs to check
209  * access permission for an attribute read.
210  *
211  * @param endpoint   Ver.: always
212  * @param clusterId   Ver.: always
213  * @param manufacturerCode   Ver.: always
214  * @param attributeId   Ver.: always
215  */
216 bool emberAfAttributeReadAccessCallback(chip::EndpointId endpoint, chip::ClusterId clusterId, uint16_t manufacturerCode,
217                                         chip::AttributeId attributeId);
218
219 /** @brief Attribute Write Access
220  *
221  * This function is called whenever the Application Framework needs to check
222  * access permission for an attribute write.
223  *
224  * @param endpoint   Ver.: always
225  * @param clusterId   Ver.: always
226  * @param manufacturerCode   Ver.: always
227  * @param attributeId   Ver.: always
228  */
229 bool emberAfAttributeWriteAccessCallback(chip::EndpointId endpoint, chip::ClusterId clusterId, uint16_t manufacturerCode,
230                                          chip::AttributeId attributeId);
231
232 /** @brief Default Response
233  *
234  * This function is called by the application framework when a Default Response
235  * command is received from an external device.  The application should return
236  * true if the message was processed or false if it was not.
237  *
238  * @param clusterId The cluster identifier of this response.  Ver.: always
239  * @param commandId The command identifier to which this is a response.  Ver.:
240  * always
241  * @param status Specifies either SUCCESS or the nature of the error that was
242  * detected in the received command.  Ver.: always
243  */
244 bool emberAfDefaultResponseCallback(chip::ClusterId clusterId, chip::CommandId commandId, EmberAfStatus status);
245
246 /** @brief Configure Reporting Response
247  *
248  * This function is called by the application framework when a Configure
249  * Reporting Response command is received from an external device.  The
250  * application should return true if the message was processed or false if it
251  * was not.
252  *
253  * @param clusterId The cluster identifier of this response.  Ver.: always
254  * @param buffer Buffer containing the list of attribute status records.  Ver.:
255  * always
256  * @param bufLen The length in bytes of the list.  Ver.: always
257  */
258 bool emberAfConfigureReportingResponseCallback(chip::ClusterId clusterId, uint8_t * buffer, uint16_t bufLen);
259
260 /** @brief Read Reporting Configuration Response
261  *
262  * This function is called by the application framework when a Read Reporting
263  * Configuration Response command is received from an external device.  The
264  * application should return true if the message was processed or false if it
265  * was not.
266  *
267  * @param clusterId The cluster identifier of this response.  Ver.: always
268  * @param buffer Buffer containing the list of attribute reporting configuration
269  * records.  Ver.: always
270  * @param bufLen The length in bytes of the list.  Ver.: always
271  */
272 bool emberAfReadReportingConfigurationResponseCallback(chip::ClusterId clusterId, uint8_t * buffer, uint16_t bufLen);
273
274 /** @brief Discover Attributes Response
275  *
276  * This function is called by the application framework when a Discover
277  * Attributes Response or Discover Attributes Extended Response command is
278  * received from an external device.  The Discover Attributes Response command
279  * contains a bool indicating if discovery is complete and a list of zero or
280  * more attribute identifier/type records. The final argument indicates whether
281  * the response is in the extended format or not.  The application should return
282  * true if the message was processed or false if it was not.
283  *
284  * @param clusterId The cluster identifier of this response.  Ver.: always
285  * @param discoveryComplete Indicates whether there are more attributes to be
286  * discovered.  true if there are no more attributes to be discovered.  Ver.:
287  * always
288  * @param buffer Buffer containing the list of attribute identifier/type
289  * records.  Ver.: always
290  * @param bufLen The length in bytes of the list.  Ver.: always
291  * @param extended Indicates whether the response is in the extended format or
292  * not.  Ver.: always
293  */
294 bool emberAfDiscoverAttributesResponseCallback(chip::ClusterId clusterId, bool discoveryComplete, uint8_t * buffer, uint16_t bufLen,
295                                                bool extended);
296
297 /** @brief Discover Commands Generated Response
298  *
299  * This function is called by the framework when Discover Commands Generated
300  * Response is received.
301  *
302  * @param clusterId The cluster identifier of this response.  Ver.: always
303  * @param manufacturerCode Manufacturer code  Ver.: always
304  * @param discoveryComplete Indicates whether there are more commands to be
305  * discovered.  Ver.: always
306  * @param commandIds Buffer containing the list of command identifiers.  Ver.:
307  * always
308  * @param commandIdCount The length of bytes of the list, whish is the same as
309  * the number of identifiers.  Ver.: always
310  */
311 bool emberAfDiscoverCommandsGeneratedResponseCallback(chip::ClusterId clusterId, uint16_t manufacturerCode, bool discoveryComplete,
312                                                       chip::CommandId * commandIds, uint16_t commandIdCount);
313
314 /** @brief Discover Commands Received Response
315  *
316  * This function is called by the framework when Discover Commands Received
317  * Response is received.
318  *
319  * @param clusterId The cluster identifier of this response.  Ver.: always
320  * @param manufacturerCode Manufacturer code  Ver.: always
321  * @param discoveryComplete Indicates whether there are more commands to be
322  * discovered.  Ver.: always
323  * @param commandIds Buffer containing the list of command identifiers.  Ver.:
324  * always
325  * @param commandIdCount The length of bytes of the list, whish is the same as
326  * the number of identifiers.  Ver.: always
327  */
328 bool emberAfDiscoverCommandsReceivedResponseCallback(chip::ClusterId clusterId, uint16_t manufacturerCode, bool discoveryComplete,
329                                                      chip::CommandId * commandIds, uint16_t commandIdCount);
330
331 /** @brief Pre Command Received
332  *
333  * This callback is the second in the Application Framework's message processing
334  * chain. At this point in the processing of incoming over-the-air messages, the
335  * application has determined that the incoming message is a ZCL command. It
336  * parses enough of the message to populate an EmberAfClusterCommand struct. The
337  * Application Framework defines this struct value in a local scope to the
338  * command processing but also makes it available through a global pointer
339  * called emberAfCurrentCommand, in app/framework/util/util.c. When command
340  * processing is complete, this pointer is cleared.
341  *
342  * @param cmd   Ver.: always
343  */
344 bool emberAfPreCommandReceivedCallback(EmberAfClusterCommand * cmd);
345
346 /** @brief Pre Message Send
347  *
348  * This function is called by the framework when it is about to pass a message
349  * to the stack primitives for sending.   This message may or may not be ZCL,
350  * ZDO, or some other protocol.  This is called prior to
351         any ZigBee
352  * fragmentation that may be done.  If the function returns true it is assumed
353  * the callback has consumed and processed the message.  The callback must also
354  * set the EmberStatus status code to be passed back to the caller.  The
355  * framework will do no further processing on the message.
356         If the
357  * function returns false then it is assumed that the callback has not processed
358  * the mesasge and the framework will continue to process accordingly.
359  *
360  * @param messageStruct The structure containing the parameters of the APS
361  * message to be sent.  Ver.: always
362  * @param status A pointer to the status code value that will be returned to the
363  * caller.  Ver.: always
364  */
365 bool emberAfPreMessageSendCallback(EmberAfMessageStruct * messageStruct, EmberStatus * status);
366
367 /** @brief Message Sent
368  *
369  * This function is called by the application framework from the message sent
370  * handler, when it is informed by the stack regarding the message sent status.
371  * All of the values passed to the emberMessageSentHandler are passed on to this
372  * callback. This provides an opportunity for the application to verify that its
373  * message has been sent successfully and take the appropriate action. This
374  * callback should return a bool value of true or false. A value of true
375  * indicates that the message sent notification has been handled and should not
376  * be handled by the application framework.
377  *
378  * @param type   Ver.: always
379  * @param indexOrDestination   Ver.: always
380  * @param apsFrame   Ver.: always
381  * @param msgLen   Ver.: always
382  * @param message   Ver.: always
383  * @param status   Ver.: always
384  */
385 bool emberAfMessageSentCallback(EmberOutgoingMessageType type, uint64_t indexOrDestination, EmberApsFrame * apsFrame,
386                                 uint16_t msgLen, uint8_t * message, EmberStatus status);
387
388 /** @brief Pre Attribute Change
389  *
390  * This function is called by the application framework before it changes an
391  * attribute value.  The value passed into this callback is the value to which
392  * the attribute is to be set by the framework.  The application should return
393  * ::EMBER_ZCL_STATUS_SUCCESS to permit the change or any other ::EmberAfStatus
394  * to reject it.
395  *
396  * @param endpoint   Ver.: always
397  * @param clusterId   Ver.: always
398  * @param attributeId   Ver.: always
399  * @param mask   Ver.: always
400  * @param manufacturerCode   Ver.: always
401  * @param type   Ver.: always
402  * @param size   Ver.: always
403  * @param value   Ver.: always
404  */
405 EmberAfStatus emberAfPreAttributeChangeCallback(chip::EndpointId endpoint, chip::ClusterId clusterId, chip::AttributeId attributeId,
406                                                 uint8_t mask, uint16_t manufacturerCode, uint8_t type, uint8_t size,
407                                                 uint8_t * value);
408
409 /** @brief Post Attribute Change
410  *
411  * This function is called by the application framework after it changes an
412  * attribute value. The value passed into this callback is the value to which
413  * the attribute was set by the framework.
414  *
415  * @param endpoint   Ver.: always
416  * @param clusterId   Ver.: always
417  * @param attributeId   Ver.: always
418  * @param mask   Ver.: always
419  * @param manufacturerCode   Ver.: always
420  * @param type   Ver.: always
421  * @param size   Ver.: always
422  * @param value   Ver.: always
423  */
424 void emberAfPostAttributeChangeCallback(chip::EndpointId endpoint, chip::ClusterId clusterId, chip::AttributeId attributeId,
425                                         uint8_t mask, uint16_t manufacturerCode, uint8_t type, uint8_t size, uint8_t * value);
426
427 /** @brief Read Attributes Response
428  *
429  * This function is called by the application framework when a Read Attributes
430  * Response command is received from an external device.  The application should
431  * return true if the message was processed or false if it was not.
432  *
433  * @param clusterId The cluster identifier of this response.  Ver.: always
434  * @param buffer Buffer containing the list of read attribute status records.
435  * Ver.: always
436  * @param bufLen The length in bytes of the list.  Ver.: always
437  */
438 bool emberAfReadAttributesResponseCallback(chip::ClusterId clusterId, uint8_t * buffer, uint16_t bufLen);
439
440 /** @brief External Attribute Read
441  *
442  * Like emberAfExternalAttributeWriteCallback above, this function is called
443  * when the framework needs to read an attribute that is not stored within the
444  * Application Framework's data structures.
445         All of the important
446  * information about the attribute itself is passed as a pointer to an
447  * EmberAfAttributeMetadata struct, which is stored within the application and
448  * used to manage the attribute. A complete description of the
449  * EmberAfAttributeMetadata struct is provided in
450  * app/framework/include/af-types.h
451         This function assumes that the
452  * application is able to read the attribute, write it into the passed buffer,
453  * and return immediately. Any attributes that require a state machine for
454  * reading and writing are not really candidates for externalization at the
455  * present time. The Application Framework does not currently include a state
456  * machine for reading or writing attributes that must take place across a
457  * series of application ticks. Attributes that cannot be read in a timely
458  * manner should be stored within the Application Framework and updated
459  * occasionally by the application code from within the
460  * emberAfMainTickCallback.
461         If the application was successfully able to
462  * read the attribute and write it into the passed buffer, it should return a
463  * value of EMBER_ZCL_STATUS_SUCCESS. Ensure that the size of the externally
464  * managed attribute value is smaller than what the buffer can hold. In the case
465  * of a buffer overflow throw an appropriate error such as
466  * EMBER_ZCL_STATUS_INSUFFICIENT_SPACE. Any other return value indicates the
467  * application was not able to read the attribute.
468  *
469  * @param endpoint   Ver.: always
470  * @param clusterId   Ver.: always
471  * @param attributeMetadata   Ver.: always
472  * @param manufacturerCode   Ver.: always
473  * @param buffer   Ver.: always
474  * @param maxReadLength   Ver.: always
475  */
476 EmberAfStatus emberAfExternalAttributeReadCallback(chip::EndpointId endpoint, chip::ClusterId clusterId,
477                                                    EmberAfAttributeMetadata * attributeMetadata, uint16_t manufacturerCode,
478                                                    uint8_t * buffer, uint16_t maxReadLength);
479
480 /** @brief Write Attributes Response
481  *
482  * This function is called by the application framework when a Write Attributes
483  * Response command is received from an external device.  The application should
484  * return true if the message was processed or false if it was not.
485  *
486  * @param clusterId The cluster identifier of this response.  Ver.: always
487  * @param buffer Buffer containing the list of write attribute status records.
488  * Ver.: always
489  * @param bufLen The length in bytes of the list.  Ver.: always
490  */
491 bool emberAfWriteAttributesResponseCallback(chip::ClusterId clusterId, uint8_t * buffer, uint16_t bufLen);
492
493 /** @brief External Attribute Write
494  *
495  * This function is called whenever the Application Framework needs to write an
496  * attribute which is not stored within the data structures of the Application
497  * Framework itself. One of the new features in Version 2 is the ability to
498  * store attributes outside the Framework. This is particularly useful for
499  * attributes that do not need to be stored because they can be read off the
500  * hardware when they are needed, or are stored in some central location used by
501  * many modules within the system. In this case, you can indicate that the
502  * attribute is stored externally. When the framework needs to write an external
503  * attribute, it makes a call to this callback.
504         This callback is very
505  * useful for host micros which need to store attributes in persistent memory.
506  * Because each host micro (used with an Ember NCP) has its own type of
507  * persistent memory storage, the Application Framework does not include the
508  * ability to mark attributes as stored in flash the way that it does for Ember
509  * SoCs like the EM35x. On a host micro, any attributes that need to be stored
510  * in persistent memory should be marked as external and accessed through the
511  * external read and write callbacks. Any host code associated with the
512  * persistent storage should be implemented within this callback.
513         All of
514  * the important information about the attribute itself is passed as a pointer
515  * to an EmberAfAttributeMetadata struct, which is stored within the application
516  * and used to manage the attribute. A complete description of the
517  * EmberAfAttributeMetadata struct is provided in
518  * app/framework/include/af-types.h.
519         This function assumes that the
520  * application is able to write the attribute and return immediately. Any
521  * attributes that require a state machine for reading and writing are not
522  * candidates for externalization at the present time. The Application Framework
523  * does not currently include a state machine for reading or writing attributes
524  * that must take place across a series of application ticks. Attributes that
525  * cannot be written immediately should be stored within the Application
526  * Framework and updated occasionally by the application code from within the
527  * emberAfMainTickCallback.
528         If the application was successfully able to
529  * write the attribute, it returns a value of EMBER_ZCL_STATUS_SUCCESS. Any
530  * other return value indicates the application was not able to write the
531  * attribute.
532  *
533  * @param endpoint   Ver.: always
534  * @param clusterId   Ver.: always
535  * @param attributeMetadata   Ver.: always
536  * @param manufacturerCode   Ver.: always
537  * @param buffer   Ver.: always
538  */
539 EmberAfStatus emberAfExternalAttributeWriteCallback(chip::EndpointId endpoint, chip::ClusterId clusterId,
540                                                     EmberAfAttributeMetadata * attributeMetadata, uint16_t manufacturerCode,
541                                                     uint8_t * buffer);
542
543 /** @brief Report Attributes
544  *
545  * This function is called by the application framework when a Report Attributes
546  * command is received from an external device.  The application should return
547  * true if the message was processed or false if it was not.
548  *
549  * @param clusterId The cluster identifier of this command.  Ver.: always
550  * @param buffer Buffer containing the list of attribute report records.  Ver.:
551  * always
552  * @param bufLen The length in bytes of the list.  Ver.: always
553  */
554 bool emberAfReportAttributesCallback(chip::ClusterId clusterId, uint8_t * buffer, uint16_t bufLen);
555
556 /** @brief Get Current Time
557  *
558  * This callback is called when device attempts to get current time from the
559  * hardware. If this device has means to retrieve exact time, then this method
560  * should implement it. If the callback can't provide the exact time it should
561  * return 0 to indicate failure. Default action is to return 0, which indicates
562  * that device does not have access to real time.
563  *
564  */
565 uint32_t emberAfGetCurrentTimeCallback();
566
567 /** @brief Get Endpoint Info
568  *
569  * This function is a callback to an application implemented endpoint that
570  * operates outside the normal application framework.  When the framework wishes
571  * to perform operations with that endpoint it uses this callback to retrieve
572  * the endpoint's information.  If the endpoint exists and the application can
573  * provide data then true shall be returned.  Otherwise the callback must return
574  * false.
575  *
576  * @param endpoint The endpoint to retrieve data for.  Ver.: always
577  * @param returnNetworkIndex The index corresponding to the ZigBee network the
578  * endpoint belongs to.  If not using a multi-network device, 0 must be
579  * returned.  Otherwise on a multi-network device the stack will switch to this
580  * network before sending the message.  Ver.: always
581  * @param returnEndpointInfo A pointer to a data struct that will be written
582  * with information about the endpoint.  Ver.: always
583  */
584 bool emberAfGetEndpointInfoCallback(chip::EndpointId endpoint, uint8_t * returnNetworkIndex,
585                                     EmberAfEndpointInfoStruct * returnEndpointInfo);
586
587 /** @brief Get Source Route Overhead
588  *
589  * This function is called by the framework to determine the overhead required
590  * in the network frame for source routing to a particular destination.
591  *
592  * @param destination The node id of the destination  Ver.: always
593  */
594 uint8_t emberAfGetSourceRouteOverheadCallback(chip::NodeId destination);
595
596 /** @brief Registration Abort
597  *
598  * This callback is called when the device should abort the registration
599  * process.
600  *
601  */
602 void emberAfRegistrationAbortCallback();
603
604 /** @brief Interpan Send Message
605  *
606  * This function will send a raw MAC message with interpan frame format using
607  * the passed parameters.
608  *
609  * @param header Interpan header info  Ver.: always
610  * @param messageLength The length of the message received or to send  Ver.:
611  * always
612  * @param message The message data received or to send.  Ver.: always
613  */
614 EmberStatus emberAfInterpanSendMessageCallback(EmberAfInterpanHeader * header, uint16_t messageLength, uint8_t * message);
615
616 /** @brief Start Move
617  *
618  * This function is called to initiate the process for a device to move (rejoin)
619  * to a new parent.
620  *
621  */
622 bool emberAfStartMoveCallback();