mDS demo using cc3000 WiFi Shields from Sparkfun or Adafruit
Dependencies: cc3000_hostdriver_mbedsocket mbed nsdl_lib
nsdl_support.h@3:ddf404b5ed21, 2014-10-18 (annotated)
- Committer:
- michaeljkoster
- Date:
- Sat Oct 18 22:38:21 2014 +0000
- Revision:
- 3:ddf404b5ed21
- Parent:
- 0:b1ec2d7dc8d1
Update WiFi for default SSID SCUGuest
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
michaeljkoster | 0:b1ec2d7dc8d1 | 1 | // Support functions for the NSDL library |
michaeljkoster | 0:b1ec2d7dc8d1 | 2 | |
michaeljkoster | 0:b1ec2d7dc8d1 | 3 | #ifndef NSDL_SUPPORT_H |
michaeljkoster | 0:b1ec2d7dc8d1 | 4 | #define NSDL_SUPPORT_H |
michaeljkoster | 0:b1ec2d7dc8d1 | 5 | |
michaeljkoster | 0:b1ec2d7dc8d1 | 6 | #include "mbed.h" |
michaeljkoster | 0:b1ec2d7dc8d1 | 7 | #include <stdint.h> |
michaeljkoster | 0:b1ec2d7dc8d1 | 8 | #include "sn_nsdl.h" |
michaeljkoster | 0:b1ec2d7dc8d1 | 9 | #include "sn_coap_header.h" |
michaeljkoster | 0:b1ec2d7dc8d1 | 10 | #include "sn_coap_protocol.h" |
michaeljkoster | 0:b1ec2d7dc8d1 | 11 | #include "sn_nsdl_lib.h" |
michaeljkoster | 0:b1ec2d7dc8d1 | 12 | |
michaeljkoster | 0:b1ec2d7dc8d1 | 13 | typedef uint8_t (*sn_grs_dyn_res_callback_t)(sn_coap_hdr_s *, sn_nsdl_addr_s *, sn_proto_info_s *); |
michaeljkoster | 0:b1ec2d7dc8d1 | 14 | |
michaeljkoster | 0:b1ec2d7dc8d1 | 15 | extern "C" void *nsdl_alloc(uint16_t size); |
michaeljkoster | 0:b1ec2d7dc8d1 | 16 | extern "C" void nsdl_free(void* ptr_to_free); |
michaeljkoster | 0:b1ec2d7dc8d1 | 17 | void nsdl_create_static_resource(sn_nsdl_resource_info_s *resource_structure, uint16_t pt_len, uint8_t *pt, uint16_t rpp_len, uint8_t *rpp_ptr, uint8_t *rsc, uint16_t rsc_len); |
michaeljkoster | 0:b1ec2d7dc8d1 | 18 | void nsdl_create_dynamic_resource(sn_nsdl_resource_info_s *resource_structure, uint16_t pt_len, uint8_t *pt, uint16_t rpp_len, uint8_t *rpp_ptr, uint8_t is_observable, sn_grs_dyn_res_callback_t callback_ptr, int access_right); |
michaeljkoster | 0:b1ec2d7dc8d1 | 19 | sn_nsdl_ep_parameters_s* nsdl_init_register_endpoint(sn_nsdl_ep_parameters_s *endpoint_structure, uint8_t* name, uint8_t* ypename_ptr, uint8_t *lifetime_ptr); |
michaeljkoster | 0:b1ec2d7dc8d1 | 20 | void nsdl_clean_register_endpoint(sn_nsdl_ep_parameters_s **endpoint_structure); |
michaeljkoster | 0:b1ec2d7dc8d1 | 21 | void nsdl_init(); |
michaeljkoster | 0:b1ec2d7dc8d1 | 22 | void nsdl_event_loop(); |
michaeljkoster | 0:b1ec2d7dc8d1 | 23 | |
michaeljkoster | 0:b1ec2d7dc8d1 | 24 | #endif // NSDL_SUPPORT_H |