Example

Dependencies:   FXAS21002 FXOS8700Q

Committer:
maygup01
Date:
Tue Nov 19 09:49:38 2019 +0000
Revision:
0:11cc2b7889af
Example

Who changed what in which revision?

UserRevisionLine numberNew contents of line
maygup01 0:11cc2b7889af 1 /*
maygup01 0:11cc2b7889af 2 * Copyright (c) 2015 ARM Limited. All rights reserved.
maygup01 0:11cc2b7889af 3 * SPDX-License-Identifier: Apache-2.0
maygup01 0:11cc2b7889af 4 * Licensed under the Apache License, Version 2.0 (the License); you may
maygup01 0:11cc2b7889af 5 * not use this file except in compliance with the License.
maygup01 0:11cc2b7889af 6 * You may obtain a copy of the License at
maygup01 0:11cc2b7889af 7 *
maygup01 0:11cc2b7889af 8 * http://www.apache.org/licenses/LICENSE-2.0
maygup01 0:11cc2b7889af 9 *
maygup01 0:11cc2b7889af 10 * Unless required by applicable law or agreed to in writing, software
maygup01 0:11cc2b7889af 11 * distributed under the License is distributed on an AS IS BASIS, WITHOUT
maygup01 0:11cc2b7889af 12 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
maygup01 0:11cc2b7889af 13 * See the License for the specific language governing permissions and
maygup01 0:11cc2b7889af 14 * limitations under the License.
maygup01 0:11cc2b7889af 15 */
maygup01 0:11cc2b7889af 16 #ifndef NSDL_ACCESS_HELPER_H
maygup01 0:11cc2b7889af 17 #define NSDL_ACCESS_HELPER_H
maygup01 0:11cc2b7889af 18 #include "mbed-client/m2mconnectionhandler.h"
maygup01 0:11cc2b7889af 19 #include "include/m2mnsdlinterface.h"
maygup01 0:11cc2b7889af 20
maygup01 0:11cc2b7889af 21 typedef Vector<M2MNsdlInterface *> M2MNsdlInterfaceList;
maygup01 0:11cc2b7889af 22
maygup01 0:11cc2b7889af 23 #ifdef __cplusplus
maygup01 0:11cc2b7889af 24 extern "C" {
maygup01 0:11cc2b7889af 25 #endif
maygup01 0:11cc2b7889af 26
maygup01 0:11cc2b7889af 27 uint8_t __nsdl_c_callback(struct nsdl_s * nsdl_handle,
maygup01 0:11cc2b7889af 28 sn_coap_hdr_s *received_coap_ptr,
maygup01 0:11cc2b7889af 29 sn_nsdl_addr_s *address,
maygup01 0:11cc2b7889af 30 sn_nsdl_capab_e nsdl_capab);
maygup01 0:11cc2b7889af 31
maygup01 0:11cc2b7889af 32 void *__nsdl_c_memory_alloc(uint16_t size);
maygup01 0:11cc2b7889af 33
maygup01 0:11cc2b7889af 34 void __nsdl_c_memory_free(void *ptr);
maygup01 0:11cc2b7889af 35
maygup01 0:11cc2b7889af 36 uint8_t __nsdl_c_send_to_server(struct nsdl_s * nsdl_handle,
maygup01 0:11cc2b7889af 37 sn_nsdl_capab_e protocol,
maygup01 0:11cc2b7889af 38 uint8_t *data_ptr,
maygup01 0:11cc2b7889af 39 uint16_t data_len,
maygup01 0:11cc2b7889af 40 sn_nsdl_addr_s *address_ptr);
maygup01 0:11cc2b7889af 41
maygup01 0:11cc2b7889af 42 uint8_t __nsdl_c_received_from_server(struct nsdl_s * nsdl_handle,
maygup01 0:11cc2b7889af 43 sn_coap_hdr_s *coap_header,
maygup01 0:11cc2b7889af 44 sn_nsdl_addr_s *address_ptr);
maygup01 0:11cc2b7889af 45
maygup01 0:11cc2b7889af 46 uint8_t __nsdl_c_auto_obs_token(struct nsdl_s *nsdl_handle, const char *path, uint8_t *token);
maygup01 0:11cc2b7889af 47
maygup01 0:11cc2b7889af 48 void *__socket_malloc( void * context, size_t size);
maygup01 0:11cc2b7889af 49
maygup01 0:11cc2b7889af 50 void __socket_free(void * context, void * ptr);
maygup01 0:11cc2b7889af 51
maygup01 0:11cc2b7889af 52 M2MNsdlInterface* get_interface(struct nsdl_s* nsdl_handle);
maygup01 0:11cc2b7889af 53
maygup01 0:11cc2b7889af 54 #ifdef __cplusplus
maygup01 0:11cc2b7889af 55 }
maygup01 0:11cc2b7889af 56 #endif
maygup01 0:11cc2b7889af 57
maygup01 0:11cc2b7889af 58 #endif // NSDL_ACCESS_HELPER_H