920c07969c08d59c51eb612efe64ab168e84c722
[platform/upstream/iotivity.git] / plugins / zigbee_wrapper / include / zigbee_wrapper.h
1 //******************************************************************
2 //
3 // Copyright 2015 Intel Mobile Communications GmbH All Rights Reserved.
4 //
5 //-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
6 //
7 // Licensed under the Apache License, Version 2.0 (the "License");
8 // you may not use this file except in compliance with the License.
9 // You may obtain a copy of the License at
10 //
11 //      http://www.apache.org/licenses/LICENSE-2.0
12 //
13 // Unless required by applicable law or agreed to in writing, software
14 // distributed under the License is distributed on an "AS IS" BASIS,
15 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 // See the License for the specific language governing permissions and
17 // limitations under the License.
18 //
19 //-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
20
21 #include "plugintranslatortypes.h"
22
23 /**
24  * @file
25  *
26  * This file contains the interface for the ZigBee Radio.
27  */
28
29 /**
30  * Initializes the specified ZigBee radio at location comPort.
31  *
32  * @param[in] comPort The location the ZigBee radio is located at.
33  *
34  * @param[out] plugin A pointer to the plugin that has been started.
35  *
36  * @param[in] newResourceCB A function pointer to the callback that will be
37  *                          invoked when a ZigBee cluster is found that matches
38  *                          a valid OIC resource.
39  */
40 OCStackResult ZigbeeInit(const char * comPort, PIPlugin_Zigbee ** plugin,
41                          PINewResourceFound newResourceCB);
42
43 /**
44  * Initiates the discovery operation associated with this ZigBee radio.
45  *
46  * @param[in] plugin A pointer to the current ZigBee radio context.
47  */
48 OCStackResult ZigbeeDiscover(PIPlugin_Zigbee * plugin);
49
50 /**
51  * De-Initializes the specified ZigBee radio.
52  *
53  * @param[in] plugin A pointer to the current ZigBee radio context.
54  */
55 OCStackResult ZigbeeStop(PIPlugin_Zigbee * plugin);
56
57 /**
58  * Called from upper layer. Gives cycles for internal operation.
59  *
60  * @param[in] plugin A pointer to the current ZigBee radio context.
61  */
62 OCStackResult ZigbeeProcess(PIPlugin_Zigbee * plugin);